Why am I getting a -1328 on this select???

Why am I getting a -1328 on this select???

 

  





All,
One of our programmers sent me a note questioning why he is getting
the following -1328. He is using the paragraph for date validation.
This is the first SQL statement in the program, He also claims (I haven't
verified yet) that subsequent executions of SYSIBM.SYSDUMMY1 work fine.
The Value of WS-CHECK-DATE is '2005-04-30'.
I can step the program through an interactive command processor, and see
that the values are as expected.
When I execute the SQL statement via command processor, it works fine.
Any ideas???

We are running on Windows 2003 V7.2 fixpack 10a.

11100-VALIDATE-DATES SECTION.
EXEC SQL
SELECT DATE(:WS-CHECK-DATE)
INTO :WS-CHECK-DATE-RESULT
FROM SYSIBM.SYSDUMMY1
END-EXEC.


SQL132 An implicit connection attempt failed. The database alias name or
8N database name "<name>" was not found in the local database
directory.





Explanation: An attempt to perform an implicit connection failed. The
database name specified by the DB2DBDFT environment variable does not name
an existing database. The database could not be found in the database
directory.


The command cannot be processed.


Note that a CONNECT RESET request issued within a distributed unit of work
will attempt an implicit connect to the default database. This may be the
reason for this error.


User Response:
Correct the database alias name specified by the DB2DBDFT environment
variable and resubmit the command.
If the intended action is to remove a connection while operating in a
distributed unit of work environment, consider replacing the CONNECT
RESET statement with a DISCONNECT or RELEASE statement.
If using the command line processor, then a "db2 terminate" should be
issued prior to resubmitting the command.
If you do not want an implicit connection to be performed, remove the
DB2DBDFT environment variable.


sqlcode: -1328


Troy



DB2 & UDB email list listserv db2-l LazyDBA home page