Re: SQL beginner help



On Feb 8, 6:32 pm, "Jon Slaughter" <Jon_Slaugh...@xxxxxxxxxxx> wrote:
I have SQL Express installed and I can access it using C# and SQL connection
manager but I'm confused on how to use this for my application.

What I want to do is host a database on a web server(which uses mysql) that
stores information for users.

I have no idea how SQL works except for a very basic understanding of
databases. What I was going to do was write a C# application that accessed
the database and let the usuer query the database that way. But now I'm
concerned about security and stuff.

A friend of mine told me that essentially I have to write an intermediate
server that sits between the SQL database server and the client so that the
client cannot ever get any direct access to the database. Is this true? If
so then how do I create such a program as it would require the isp to run
the program(which is highly doubful that they will?). It also seems like
twice the work as essentially it would just be a front end on the SQL
database.

Basically the database will just store information(obviously) and the user
will use some interface to access the information(which is about books). I
was thinking about using a web interface instead of an application since it
would be easier but I do need to access the clients computer and I don't
want to use java to do this.

Basically the database is for books sorta like CDDB but different than the
book information databases around now.

What I'm asking is how does one programmatically interface with an SQL
database? Obviously not through scripts and its usually done transparently
but I don't know if they are dynamically creating the scripts and sending it
directly to the server or if there is some other means?

Like when I access a webpage that displays information that obviously comes
from a database, is there a php or javascript that gets the information from
the sql database and displays it or does it go through some intermediate
server for security reasons?

The whole reason is simply that I don't want to have some users having full
access to the database and ruining it by adding wrong information or
deleting it. I want to keep track of which user did what so they can modify
what they have added but not change what someone else has done. I have no
idea if this is handled by SQL directly or if I have to write a front end to
do it? (and the front end is the only thing the clients see)

Thanks,
Jon

OK Jon, that was a lot of info, so I'll try to cover it all. I'm
coming from a very similar background, C# developer who had to learn
SQL databases to do some projects.

SQL Express will be good practice for you, but your final product will
not use it if the server you're connecting to has MySQL. I haven't
used MySQL before, but it shouldn't be a huge change to your code. You
will just use a different DataAdapter.

Now, as for how to create your product. It seems like a web interface
will be the easiest thing for you. It might not be as familiar as a C#
application, but it's better suited to your goals. The biggest thing I
got from your post is you need to balance the effort you're putting
into this and the functionality you need. You mention very specific
security needs. To have a user have control over things they add, but
not have control over items other people add is possible, but it is
significantly more security work.

In SQL Server you have security "groups" and users can join one or
more groups. So a certain group may have read + write access over one
table while another group only has read access. I do not know if this
is how it works in MySQL or not. To accomplish your goal of users
having access to only certain rows in a table is going to require some
server-side code outside of the group security to determine if the
user should be able to access a certain row.

If you decide to do a C# application instead of a web interface, you
do not HAVE to create code to run on the server, but in the end it
will be much more useful. If you don't, then each user who is running
your app will have to have security access to the instance of SQL
Server (again, could be different in MySQL). So you would either have
to have an account in the database for each user, or set up general
user accounts that the many users share (this can be done in code so
they wouldn't know their account details). Then in code you would make
a connection over the net to your database. If instead you're just
connecting to another app, and that app is handling all the
connections to the database then the security model is much simpler.

ok, I hope that helps. If it doesn't please post some response
questions. Sorry that I don't know anymore about MySQL, there might be
some better groups to post MySQL specific questions. Good luck!

.



Relevant Pages

  • RE: Backups have Shadow Copy Problems
    ... and restarted the server. ... suggested and changed the recovery model to simple on the one database called ... I understand the issue to be: the backup task failed ... You back up data from a volume that contains a Microsoft SQL Server ...
    (microsoft.public.windows.server.sbs)
  • Re: upsizing to sql 2005
    ... the word SERVER in it, ... You can access to the database by multiple means (Access, ... and how does it update the SQL database with the new records in Access? ... Query Name: Arcadia - ARC ...
    (microsoft.public.access.queries)
  • Re: Its probably stupid.... but......
    ... MySQL in a commercial environment you need to purchase a commercial ... For a server environment this is pretty cheap. ... needs a database for their distributed applications I would advise them ... We purchased Sybase SQL Anywhere for our standalone engine. ...
    (RedHat)
  • Re: Linked Tables in Access
    ... any use of SQL Passthru, Linked Tables or any other use of MDB / MDE ... server, or would I also need to convert *those* queries to passthrough ... I've been trying to understand why Access database files become corrupt. ...
    (microsoft.public.access.adp.sqlserver)
  • Re: Trouble Getting VS.Net 2003 WalkThroughs MSDE Connection
    ... Config Tool of SQL Server? ... > link to download the PUBs database. ... >>> Setup and they directed me to install MSDE and they attached a ...
    (microsoft.public.sqlserver.msde)

Loading