![]() | ![]() | ![]() | ![]() | ![]() |
Previously, the SAS® System allowed the use of the INDEX function without a comparison when you access the DB2 database with a LIBNAME statement. For the z/OS environment only, SAS automatically adds a comparison to the query before submitting it to DB2 because DB2 does not permit queries that do not have a comparison. However, it is possible that SAS might add an incorrect comparison, potentially leading to incorrect results. To avoid this possibility, a required fix has been created so that SAS no longer adds a comparison automatically under z/OS.
Click the Hot Fix tab in this note to access the hot fix for this issue.
Note: After you apply this hot fix, if you do not include a comparison in your query, you will receive the following error:
ERROR: DB2 prepare error: DSNT408I SQLCODE = -199, ERROR: ILLEGAL USE OF KEYWORD FOR. TOKEN MICROSECONDS MICROSECOND SECONDS SECOND MINUTES MINUTE HOURS WAS EXPECTED DSNT418I SQLSTATE = 42601 SQLSTATE RETURN CODE.
This occurs because, as mentioned previously, DB2 does not permit queries that do not have a comparison operation. For example, you will receive the error if you use a WHERE clause similar to the following:
To avoid the error, you must include a comparison, as shown in this example:
Product Family | Product | System | SAS Release | |
Reported | Fixed* | |||
SAS System | SAS/ACCESS Interface to DB2 | z/OS | 9.1 TS1M3 SP4 | 9.2 TS2M3 |