Cannot access a database in SQL Server...

Results 1 to 2 of 2

Thread: Cannot access a database in SQL Server...

  1. #1
    Join Date
    Dec 1969

    Default Cannot access a database in SQL Server...

    Hi,<BR><BR>I have this situation.<BR>When I&#039;m using OLE DB connections to SQL Server I only can access the "master" database (so I have to import my "books" Access database in this database in order to work).<BR>The connections string looks like:<BR>~~~~~~<BR>&#039;Database connection for SQL Server - local - OLEDB<BR>Set db = server.createobject("adodb.connection")<BR> strConn="Provider=SQLOLEDB;DataSource=mircea;Initi alCatalog=books;uid=sa;pwd=;"<BR>db.Open strConn<BR>~~~~~~~<BR><BR>When I&#039;m using ODBC DSN connections I can access a separate new database named "books" (the data were imported from the same Access database).<BR>The connection string is:<BR>~~~~~~<BR>Set db = server.createobject("adodb.connection")<BR>strConn ="dsn=mircea;uid=sa;pwd=;DATABASE=books;"<BR> db.Open strConn<BR>~~~~~~<BR><BR> Why this happens? I want to access via OLE DB another new created database not only the "master" database.<BR> And which is the best connection for SQL Server? OLE DB? ODBC DSN?<BR><BR>Thanks,<BR>Mircea

  2. #2
    Join Date
    Dec 1969

    Default RE: Cannot access a database in SQL Server...

    It looks like permissions problem. Although I&#039;m definitely not a DBA, so I could be wrong

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts