Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Can someone look at this sql code for a view def'n
Message
From
08/01/2007 15:08:52
Alexandre Palma
Harms Software, Inc.
Alverca, Portugal
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP
Network:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01183548
Message ID:
01183552
Views:
18
Hi Michael you can't use ?THISFORM.CustomerCombo.VALUE
instead use ?somevarname and then in code u so somevarname = THISFORM.CustomerCombo.VALUE.

>The error generated by the cpode below is
>Command contains unrecognized phrase/keyword
>
>CREATE SQL VIEW "ORDERID" AS ;
> SELECT Ordhead.orderid, Ordhead.customerid, Ordhead.location, ; Ordhead.entered, Ordsize.PRODUCT, Ordsize.ordered, Sizetype.DESCRIPTION, ;
> Ordsize.sizetypeid,PRODUCT.CODE ;
> FROM frantisi!Sizetype, frantisi!Ordprod, frantisi!Ordsize, frantisi!Ordhead, frantisi!PRODUCT ;
> WHERE Ordsize.PRODUCT = PRODUCT.productid ;
> AND Ordhead.orderid = Ordprod.orderid ;
> AND Ordprod.orderprodid = Ordsize.orderprodid ;
> AND Ordsize.sizetypeid = Sizetype.sizetypeid ;
> AND (Ordsize.location = ?THISFORM.LocationCombo.VALUE OR EMPTY(?THISFORM.LocationCombo.VALUE)) ;
> AND (PRODUCT.supplier = ?THISFORM.SupplierCombo.VALUE OR EMPTY(?THISFORM.SupplierCombo.VALUE)) ;
> AND (Ordhead.customerid = ?THISFORM.CustomerCombo.VALUE ;
> OR EMPTY(?THISFORM.CustomerCombo.VALUE)) ;
> AND Ordsize.ordered > 0))
>
>
>This usually means a typo... and I am not seeing it.
>
>Maybe fresh eyes can help?
>
>TIA,
>Mike
Alexandre Palma
Senior Application Architect
Previous
Reply
Map
View

Click here to load this message in the networking platform