473,394 Members | 1,699 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Everytime I open my Access database it throws up a "SQL Server Login" need help

anoble1
245 128KB
Hi,

I recently upgraded 2 of the servers on my MS Access 2007 database. A UA server and a Production server. WHen I converted over to the new severs I just changed the names in code. Also, I had to relink all the tables to the new server. I had to create a DSN. I got all the tables linked.

Well, now whenever I open the database it has the SQL Server Login screen, with a username and password. Why does that come up now?

So, I have to enter my SQL Server password to login to the DB. Any help? ANyone had this happen?

Below is the code from my code ModLink.

Expand|Select|Wrap|Line Numbers
  1. Public Function PingTRIPSDatabaseITUAServer()
  2.     Dim connectString As String
  3.     'connectString = "ODBC;Driver={SQL Server};Server=GAXGPSQ05UA;Database=TRIPS;UID=trimsuser;pwd=trimsdata"
  4.     connectString = "ODBC;Driver={SQL Server};Server=GAXGPSQ81UA;Database=TRIPS;UID=trimsuser;pwd=trimsdata"
  5.     Set db = DBEngine.OpenDatabase("", False, True, connectString)
  6. End Function
  7.  
  8. Public Function PingTRIPSDatabaseITProductionServer()
  9.     Dim connectString As String
  10.     'connectString = "ODBC;Driver={SQL Server};Server=GAXGPSQ09;Database=TRIPS;UID=trimsuser;pwd=nat10nal"
  11.     connectString = "ODBC;Driver={SQL Server};Server=GAXGPSQ82;Database=TRIPS;UID=trimsuser;pwd=nat10nal"
  12.     Set db = DBEngine.OpenDatabase("", False, True, connectString)
  13. End Function
  14.  
  15. Public Sub LinkTripsTablesUAITServer(table As String)
  16.  
  17. '    cn = "odbc;driver={SQL Server};server=GAXGPSQ05UA;database=TRIPS;uid=trimsuser;pwd=trimsdata"
  18.     cn = "odbc;driver={SQL Server};server=GAXGPSQ81UA;database=TRIPS;uid=trimsuser;pwd=trimsdata"
  19.  
  20.     Set db = CurrentDb
  21.     Set td = db.CreateTableDef()
  22.     td.Name = table
  23.     td.SourceTableName = "dbo." & table
  24.     td.Connect = cn
  25.  
  26.     Set tds = db.TableDefs
  27.     tds.Append td
  28.  
  29. End Sub
  30.  
  31. Public Sub LinkTripsTablesProductionITServer(table As String)
  32.  
  33.     'cn = "odbc;driver={SQL Server};server=GAXGPSQ09;database=TRIPS;uid=trimsuser;pwd=nat10nal"
  34.     cn = "odbc;driver={SQL Server};server=GAXGPSQ82;database=TRIPS;uid=trimsuser;pwd=nat10nal"
  35.  
  36.     Set db = CurrentDb
  37.     Set td = db.CreateTableDef()
  38.     td.Name = table
  39.     td.SourceTableName = "dbo." & table
  40.     td.Connect = cn
  41.  
  42.     Set tds = db.TableDefs
  43.     tds.Append td
  44.  
  45. End Sub

Mar 17 '12 #1
1 2082
ADezii
8,834 Expert 8TB
Can you use Trusted_Connect=True within the Connection String to use Windows Authentication?
Mar 18 '12 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

7
by: rickcheney | last post by:
I just changed my Access 2002 database to a SQL Server ADP project. I had a form where the user entered a value into a text box and when a command button on the form was clicked a Report was...
1
by: rcmail14872 | last post by:
I used the upsize wizard to change my Access 2002 database to a SQL Server ADP project. I had a form where the user entered a value into a text box and when a command button on the form was...
4
by: RSH | last post by:
Hi, I have a situation where I have created a little application that makes an Access database from a SQL Database for reporting purposes. it does the job well, but it seems a bit slow. Is...
2
by: nosipho | last post by:
Hello guys, I need to copy a database in SQL 2000 to another SQL2000 server. I tried backing up the database to a folder then restore it but it's not happening. Please help to know how to copy...
21
by: lesperancer | last post by:
I've got an access97 reporting mdb that pulls data (77,000 rows) from a sql server table into a local table to run reports if the local table is part of the reporting MDB, the insert statement...
1
by: newtechiebug | last post by:
I am trying to convert a MS Access Query to a SQL query and I need help with some IIF Statements? 2 in particular that I've encountered problems with are: Count(IIf(=0 Or...
2
Jimmy Liew
by: Jimmy Liew | last post by:
hi, I found this error message in my Ms SQL Server error log. Does anyone know what is all about? What I should diagnosis on this? The SQL Server management pack script "SQL Server 2000...
2
by: madhavi123 | last post by:
Hi... I am new to database programming. I need to create a DTS Package which should archive a database fron one sql server to another. I have no idea that which connection objects and which...
1
by: rmsterling | last post by:
All, Subject : SQL Server 2005 SSIS Script Help - XML Secure Pull in to DB table I was wondering if any of you could help me with something..... I want to design a SSIS script that will pull...
18
by: smckibbe01 | last post by:
I have Pivot Table query in MS Access that I would like to run in SQL Server 2005. Can anyone help me to convert the syntax over to SQL Server. The following is the query in MS Access: ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.