Hi all
I have a view lv_tInquiry. All fields updatable.
Add Table mAccounts, Inner Join tInquiry.iPartyID = mAccounts.iID
This in itself will work. Now...
Again Add Table mAccounts, Inner Join tInquiry.iAgentID = mAccounts_a.iID
This view though when modifying does not have any problem. But if you save it and want to reopen this view it wont open giving an error SQL: Column 'iAgentID' is not found.
I tried opening this view in ViewEditor I get the same messge with error no. 1806. The following is the SQL generate for this view:
SELECT TINQUIRY.*, ;
MACCOUNTS.CNAME, ;
MACCOUNTS.CCITY, ;
MACCOUNTS_A.CNAME, ;
MACCOUNTS_A.CCITY ;
FROM VSO3!TINQUIRY INNER ;
JOIN VSO3!MACCOUNTS INNER ;
JOIN VSO3!MACCOUNTS MACCOUNTS_A ;
ON TINQUIRY.IAGENTID = MACCOUNTS_A.IID ;
ON TINQUIRY.IPARTYID = MACCOUNTS.IID ;
ORDER BY TINQUIRY.DDT, TINQUIRY.CBK, TINQUIRY.INO
I have tried Left Outer Join and same results. Right Outer Join and Full Join wont work in my case atleast.
Please help. This is just the tip of the ice-burg where I want to call the same master table twice. I may also have to call, if not the same master, other master(s) in the view also.