Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
SQL - command Lookcode not found?
Message
From
20/04/2000 10:08:41
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00361746
Message ID:
00361772
Views:
18
>I just tried FORCE. It gave me the same error.
>
>And I tried qualifying the table names as someone else suggested. But that didn't help either.
>
>This is something. I am so close. Yesterday I had the whole report working except for the 6 fields that I have to translate codes into words for the report. So I know I am close. Once I get the table translations to work I will be done and can take it to the office and run it today.
>
>Thanks again. I will keep trying.


Steve,
I would write it as :
IF THISFORM.cborpt.Value = "23"
	set ansi on
	SELECT a.* FROM FORCE aed_info a ;
		LEFT JOIN \data\aed\lookloc b ON a.aedloc = b.lookcode ;
		LEFT JOIN \data\aed\lookhrs c ON a.hrs = c.lookcode ;
		LEFT JOIN \data\aed\lookpage d ON a.emspager = d.lookcode ;	
		LEFT JOIN \data\aed\lookcaut e ON a.aed_cautn = e.lookcode ;
		LEFT JOIN \data\aed\looktrn f ON a.trainedby = f.lookcode ;
		LEFT JOIN \data\aed\lookwho g ON a.whowants = g.lookcode ;
		ORDER BY a.city, a.unitid ;
		INTO CURSOR rpt
	set ansi off
	IF THISFORM.cboOutputTo.Value = "S"
		REPORT FORM \arrest\reports\aedlocdt.frx PREVIEW IN SCREEN
	ELSE
		REPORT FORM \arrest\reports\aedlocdt.frx TO PRINT
	ENDIF
ENDIF
Normally you cannot have indexes with alltrim(). Fox doesn't error but doesn't trim too. I "assumed" purpose was an exact match. Then "set ansi on" does it. Either side of the expression is padded to match sizes (like == operator). Other than that if that doesn't work I'd start by only joining one table then add another till I get error.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform