Problem Note 20526: Swapping inputs to a join may result in invalid syntax
In SAS® Data Integration Studio 3.4, if you swap inputs to an SQL join
transformation in a job, the generated code results in bad syntax and
the following errors are returned:
ERROR 22-322: Syntax error, expecting one of the following:
a name, (, AS, ON.
ERROR 76-322: Syntax error, statement will be ignored.
The following code example demonstrates this problem.
This is a three table join in which the first input (lib2.BOOKED)
is a left join and the second input (lib2.SITE) is a right join:
...
from
lib2.BOOKED left join
lib1.INVOICE
on
(
BOOKED.INVNUMER = INVOICE.INVNUMER
) right join
lib2.SITE
on
(
INVOICE.REF4 = SITE.REF4
and INVOICE.CORPID = SITE.CORPID
and INVOICE.CLIENT = SITE.CLIENT
)
;
...
Swappping inputs on the second join generates bad syntax. There is
no ON clause between the first two tables:
...
from
lib2.SITE right join
lib2.BOOKED left join
lib1.INVOICE
on
(
BOOKED.INVNUMER = INVOICE.INVNUMER
)
on
(
INVOICE.REF4 = SITE.REF4
and INVOICE.CORPID = SITE.CORPID
and INVOICE.CLIENT = SITE.CLIENT
)
;
...
This is only likely to occur if the option Implicit is set to "No" on a
join that is to the right of another join.
Select the Hot Fix tab in this note to access the hot fix for this issue.
Operating System and Release Information
SAS System | SAS Data Integration Studio | Microsoft Windows Server 2003 Enterprise Edition | 3.4 | 4.2 | 9.1 TS1M3 SP4 | 9.2 TS1M0 |
Microsoft Windows 2000 Advanced Server | 3.4 | 4.2 | 9.1 TS1M3 SP4 | 9.2 TS1M0 |
Microsoft Windows 2000 Datacenter Server | 3.4 | 4.2 | 9.1 TS1M3 SP4 | 9.2 TS1M0 |
Microsoft Windows 2000 Server | 3.4 | 4.2 | 9.1 TS1M3 SP4 | 9.2 TS1M0 |
Microsoft Windows 2000 Professional | 3.4 | 4.2 | 9.1 TS1M3 SP4 | 9.2 TS1M0 |
Microsoft Windows Server 2003 Datacenter Edition | 3.4 | 4.2 | 9.1 TS1M3 SP4 | 9.2 TS1M0 |
Microsoft Windows XP Professional | 3.4 | 4.2 | 9.1 TS1M3 SP4 | 9.2 TS1M0 |
Microsoft Windows Server 2003 Standard Edition | 3.4 | 4.2 | 9.1 TS1M3 SP4 | 9.2 TS1M0 |
Microsoft® Windows® for x64 | 3.4 | 4.2 | 9.1 TS1M3 SP4 | 9.2 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.
Type: | Problem Note |
Priority: | medium |
Date Modified: | 2008-03-05 13:06:40 |
Date Created: | 2007-07-06 10:28:31 |