SUPPORT / SAMPLES & SAS NOTES
 

Support

Problem Note 46787: Using ANSI INNER JOIN syntax might result in the query being processed in SAS®

DetailsHotfixAboutRate It

Using an SQL procedure to join two database management system (DBMS) tables via the LIBNAME engine might result in a performance issue or a discrepancy in the results. The problem arises if the query contains ANSI INNER JOIN syntax and a correlated subquery.

This problem occurs when the query is incorrectly converted from SAS syntax to the DBMS syntax. The incorrect syntax causes DBMS to return an error. As a result of the error, SAS retrieves the rows in the DBMS tables and processes the query within SAS. Processing the query in SAS might take longer than if the query had been processed by the DBMS. Processing the query in SAS might also result in a difference in results if the key variable contains nulls, because SAS and DBMS treat nulls and missing data differently.

To work around this issue, do one of the following:

  • Use explicit pass-through.
  • Or switch to using a comma between the tables and moving the ON condition(s) to the existing WHERE clause.

Click the Hot Fix tab in this note to access the hot fix for this issue.



Operating System and Release Information

Product FamilyProductSystemSAS Release
ReportedFixed*
SAS SystemBase SASz/OS9.1 TS1M3 SP49.4 TS1M0
Microsoft® Windows® for 64-Bit Itanium-based Systems9.1 TS1M3 SP4
Microsoft Windows Server 2003 Datacenter 64-bit Edition9.1 TS1M3 SP4
Microsoft Windows Server 2003 Enterprise 64-bit Edition9.1 TS1M3 SP4
Microsoft Windows XP 64-bit Edition9.1 TS1M3 SP4
Microsoft Windows 2000 Advanced Server9.1 TS1M3 SP4
Microsoft Windows 2000 Datacenter Server9.1 TS1M3 SP4
Microsoft Windows 2000 Server9.1 TS1M3 SP4
Microsoft Windows 2000 Professional9.1 TS1M3 SP4
Microsoft Windows NT Workstation9.1 TS1M3 SP4
Microsoft Windows Server 2003 Datacenter Edition9.1 TS1M3 SP4
Microsoft Windows Server 2003 Enterprise Edition9.1 TS1M3 SP4
Microsoft Windows Server 2003 Standard Edition9.1 TS1M3 SP4
Microsoft Windows XP Professional9.1 TS1M3 SP4
Windows Vista9.1 TS1M3 SP4
Windows Vista for x649.1 TS1M3 SP4
64-bit Enabled AIX9.1 TS1M3 SP49.4 TS1M0
64-bit Enabled HP-UX9.1 TS1M3 SP49.4 TS1M0
64-bit Enabled Solaris9.1 TS1M3 SP49.4 TS1M0
HP-UX IPF9.1 TS1M3 SP4
Linux9.1 TS1M3 SP4
Linux on Itanium9.1 TS1M3 SP49.4 TS1M0
OpenVMS Alpha9.1 TS1M3 SP4
Solaris for x649.1 TS1M3 SP49.4 TS1M0
Tru64 UNIX9.1 TS1M3 SP49.4 TS1M0
* For software releases that are not yet generally available, the Fixed Release is the software release in which the problem is planned to be fixed.