Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Ugly SQL
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Miscellaneous
Thread ID:
00563216
Message ID:
00563234
Views:
20
>>This baby seems to fail:
>>
>>SELECT CONFIGFILES.*, ;
>>		PARAMETERS.CNAME, ;
>>		PARAMETERS_A.CNAME, ;
>>		PARAMETERS_B.CNAME, ;
>>		PARAMETERS_C.CNAME ;
>>	FROM GULFSTREAM!CONFIGFILES ;
>>		LEFT JOIN GULFSTREAM!PARAMETERS ;
>>		LEFT JOIN GULFSTREAM!PARAMETERS PARAMETERS_A ;
>>		LEFT JOIN GULFSTREAM!PARAMETERS PARAMETERS_B ;
>>		LEFT JOIN GULFSTREAM!PARAMETERS PARAMETERS_C ;
>>				ON CONFIGFILES.IREMOTEPARAM4 = PARAMETERS_C.IPARAMID ;
>>				ON CONFIGFILES.IREMOTEPARAM3 = PARAMETERS_B.IPARAMID ;
>>				ON CONFIGFILES.IREMOTEPARAM2 = PARAMETERS_A.IPARAMID ;
>>				ON CONFIGFILES.IREMOTEPARAM1 = PARAMETERS.IPARAMID ;
>>	WHERE CARTICLEID = ?VP_CARTICLEID
>>
>>This is a remote view that I coded with viewedit. It can't seem to find iremoteparam4, even though the field is in the database. Any clues as to what's going on?
>
>Hi James,
>
>Try this way (define the view in code) and see if it helps:
>
>SELECT CONFIGFILES.*, ;
>	PARAMETERS.CNAME, ;
>	PARAMETERS_A.CNAME, ;
>	PARAMETERS_B.CNAME, ;
>	PARAMETERS_C.CNAME ;
>	FROM GULFSTREAM!CONFIGFILES ;
>	LEFT JOIN GULFSTREAM!PARAMETERS ;
>	ON CONFIGFILES.IREMOTEPARAM1 = PARAMETERS.IPARAMID ;
>	LEFT JOIN GULFSTREAM!PARAMETERS PARAMETERS_A ;
>	ON CONFIGFILES.IREMOTEPARAM2 = PARAMETERS_A.IPARAMID ;
>	LEFT JOIN GULFSTREAM!PARAMETERS PARAMETERS_B ;
>	ON CONFIGFILES.IREMOTEPARAM3 = PARAMETERS_B.IPARAMID ;
>	LEFT JOIN GULFSTREAM!PARAMETERS PARAMETERS_C ;
>	ON CONFIGFILES.IREMOTEPARAM4 = PARAMETERS_C.IPARAMID ;
>	WHERE CARTICLEID = ?VP_CARTICLEID
>
>Also you might need to specify the alias for CARTICLEID field.

That was the it! Thanks guys.
Previous
Reply
Map
View

Click here to load this message in the networking platform