Click to See Complete Forum and Search --> : Newbie question on Microsoft SQL Server 2000


dlacloche
05-09-2007, 01:36 PM
How do I add data to a table in a database that's running on a remote machine? I can see the service running, using the SQL Server Service Manager, but I don't know how to get at the data.

Using Microsoft SQL Server 2000.

russell
05-09-2007, 05:52 PM
do u have query analyzer and enterprise manager on your machine?

dlacloche
05-09-2007, 09:06 PM
Yes.

russell
05-09-2007, 09:55 PM
ok, so are you able to connect to the sql server?

is the server on your network or over the internet?

do u have a valid account to log on with?

there are lots of ways to add data...do you intend to use T-SQL scripts (insert statements) or do u need to do bulk updates?

first thing you need to do is connect to the sql server.

using query analyzer (isqlw.exe) go to connect, then type in name or ip address of server. tick authentication type -- this will depend on how your administrator set it up, type user/pwd if sql authentication, click connect

please answer the above questions and make sure u can connect, and i'll try to give more specific help :)

dlacloche
05-10-2007, 12:09 AM
I can't connect to the SQL server because I don't really know how.

The server is on our intranet

I believe I can use a log in from the guy who used to do this

Bulk updates sounds like my style

I'll try to connect on Monday [I'm taking a small vacation before I have to figure this out]. I'll reply again after I've tried your advice.

dlacloche
05-15-2007, 03:50 PM
So, I believe I'm able to see the database on our intranet. I was able to connect using Windows authentification without login and password.

I'm ready for more advice.

I'm going to play around and see what I can figure out.

dlacloche
05-15-2007, 04:45 PM
I'm doing stuff! This is cool! I INSERTed a record!

russell
05-15-2007, 05:21 PM
:)

dlacloche
05-18-2007, 03:38 PM
Okay, I can use Query Analyzer to INSERT, UPDATE and DELETE records from tables n databases. Is there a way to interact with the data using a GUI? More like Microsoft Access? I don't mind using SQL, but it takes so long.

And, how can I move a database from one SQL Server to another? I'm guessing outputting it as a .sql file then somehow importing that into the other SQL Server.

russell
05-19-2007, 03:05 AM
Enterprise Manager provides an access-like GUI. But try to get comfortable using Query Analyzer. It is far more powerful and will make you a better programmer.

Moving entire db -- 2 ez ways: (1) backup the db, copy the backup file to new server and restore it (2) detach db, copy .mdf and .ldf files to new location and re-attach it. See sp_attach_db in BOL (books online) for more info. there are other methods, but these are probably the only two u want to consider.

dlacloche
05-21-2007, 04:06 PM
I'm so close, now.
I used method #2. Detached database, moved .mdf and .ldf to other server, re-attached database. Everything looked good. Then I got a permissions issue when I tried to check it out on the web.

Microsoft OLE DB Provider for ODBC Drivers error '80040e09'
[Microsoft][ODBC SQL Server Driver][SQL Server]SELECT permission denied on object 'tblTestFood', database 'dantest', owner 'dbo'.
/test2.asp, line 13

Any thoughts? I'm googling it, trying to add users to the database in Enterprise Manager.

russell
05-21-2007, 09:20 PM
need to grant the user permission. can add to the db_datareader role, or explicitly grant object level permissions in query analyzer:

grant select on tblTestFood to dantest