| View previous topic :: View next topic |
| Author |
Message |
Stephen K. Miyasato Guest
|
Posted: Fri Jun 02, 2006 4:16 am Post subject: How to swich Database with MSSQL |
|
|
I'm trying to figure out how to switch to another database that is on the
same sever.
I have two database Demo and Real.
I'm using a UDL file to change the connection string. But whatever I change
it to it does not change/switch the database.
I've looked at the connection string in the Afterconnect event of
TADOconnection and it has the database Name that I specified in the UDL file
but it still connects to the previous DB.
Any help appreciated.
Stephen K. Miyasato |
|
| Back to top |
|
 |
Johan Guest
|
Posted: Fri Jun 23, 2006 8:11 am Post subject: Re: How to swich Database with MSSQL |
|
|
You can use the "Use" command in the query to cahne databases.
Ex: Use demo
sql statement
Johan
"Stephen K. Miyasato" <miyasat (AT) flex (DOT) com> wrote:
| Quote: | I'm trying to figure out how to switch to another database that is on the
same sever.
I have two database Demo and Real.
I'm using a UDL file to change the connection string. But whatever I change
it to it does not change/switch the database.
I've looked at the connection string in the Afterconnect event of
TADOconnection and it has the database Name that I specified in the UDL file
but it still connects to the previous DB.
Any help appreciated.
Stephen K. Miyasato
|
|
|
| Back to top |
|
 |
|