hi
how to create a job just to check whether the connection with datbase is established or failed.........?
is there any routine or macro available if yes hoew to use it.........?
datbase connection status..........
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 88
- Joined: Wed Apr 05, 2006 1:04 am
How about a simple job to read one record from a table (you could do something like a select from dual in Oracle) and writing that to /dev/null. If the job fails then you don't have a database connection.
<a href=http://www.worldcommunitygrid.org/team/ ... TZ9H4CGVP1 target="WCGWin">
</a>
</a>
ODBC or OCI? If the command line for the database is available, consider a system command call to run a silly SQL statement and just check if it works. SELECT SYSDATE FROM DUAL is sufficient for Oracle using sqlplus. ISQL/OSQL are options for SQL-Server and SYBASE, dbaccess for Informix, and the DB2/UDB command line name escapes me right now.
Kenneth Bland
Rank: Sempai
Belt: First degree black
Fight name: Captain Hook
Signature knockout: right upper cut followed by left hook
Signature submission: Crucifix combined with leg triangle
Rank: Sempai
Belt: First degree black
Fight name: Captain Hook
Signature knockout: right upper cut followed by left hook
Signature submission: Crucifix combined with leg triangle