
April 28th, 2004, 02:36 PM
|
|
Registered User
|
|
Join Date: Apr 2004
Posts: 1
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
|
Automate login to Oracle database
Hi,
I am facing a problem while connecting to the Oracle database automatically.
I want to setup an SQL query on the database which is scheduled to run every midnight. The SQL query then populates an Excel spreadsheet with the results. I was able to schedule the SQL qeury, however, the problem is that it requests the user to type in the password every time it runs. I want to store the username and password in the connection string/driver settings to avoid uder interaction.
The following are ths current settings :
1. In Microsoft ODBC setup for Oracle settings,
DSN = DDTS
Description = (DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP) (HOST=bee1.pcs.mot.com)(PORT=1521)))(CONNECT_DATA= (SERVICE_NAME=WSDTOOL1)))
Username = myUserName
Server = DDTS
2. In MS Excel, I created the Data Source and set the driver to MS ODBC for Oracle.
I tried to save the UID=xxx and PWD=xxx in the (a) Connection String for the ODBC Setup (b) in the tnsnames.org, but none of the options work. It still needs the user to enter the password everytime it executes.
Can someone help ?
Thanks !
|