1. Kevin Barton
  2. PowerBuilder
  3. Friday, 06 July 2018

I need to test to see if a database is running through a PowerBuilder application. Every time that I test the connection, and the database is down, the ODBC dialog box appears and the application just sits and waits for someone to respond to the window.  Is there a way to suppress the window and just have SQLCA return the error code?

This is my DBParm setting SQLCA.DBParm = "ConnectString='DSN=DATASOURCE_TEST;UID=dba;PWD=sql;ConnectOption='SQL_DRIVER_CONNECT,SQL_DRIVER_NOPROMPT'"

PowerBuilder 2017 and SQL Anywhere 16.

Any Ideas?

Brad Mettee Accepted Answer Pending Moderation
0
Votes
Undo

Your quotes seem to be a bit off.

You have this:

"ConnectString='DSN=DATASOURCE_TEST;UID=dba;PWD=sql;ConnectOption='SQL_DRIVER_CONNECT,SQL_DRIVER_NOPROMPT'"

But it should look like this:

"ConnectString='DSN=DATASOURCE_TEST;UID=dba;PWD=sql',ConnectOption='SQL_DRIVER_CONNECT,SQL_DRIVER_NOPROMPT'"


There's a semi-colon separating the two parts of the string, but it should be an end single quote and a comma

Comment
There are no comments made yet.
  1. Saturday, 7 July 2018
  2. PowerBuilder
  3. # 1
  • Page :
  • 1


There are no replies made for this question yet.
However, you are not allowed to reply to this question.