Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Error correlating fields
Message
From
06/10/2011 15:43:42
 
 
To
06/10/2011 15:13:18
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
01525783
Message ID:
01525793
Views:
38
>>To All,
>>
>>I have a piece of code that runs perfectly in Oracle environment and now want to bring it to VFP,
>>but getting error correlating fields:
>>
>>SELECT Table1.*,;
>> Table2.*;
>> FROM Table1 LEFT OUTER JOIN Table2 A;
>> ON Table1.setid = A.setid AND Table1.deptid = A.deptid;
>> WHERE A.effdt = (SELECT MAX(effdt) FROM Table2 B;
>> WHERE B.setid=A.setid AND B.deptid=A.deptid ;
>> AND B.effdt less then Table1.effdt)
>>
>>
>>I am trying to connect Table 1 to Table2 and select only 1 record from Table2 (effective dated) that is prior to effective date in Table1.
>>
>>Tried to change ENGINEBEHAVIOUR, but the error exist in all.
>>What I am doing wrong?
>>
>>Thanks
>
>You've aliased Table 2 so I think that you need
>SELECT table1.*,A.*
Yes, to show that I will be using the same table (A & B)
Previous
Reply
Map
View

Click here to load this message in the networking platform