Mike Yearwood
Toronto, Ontario, Canada
General information
Category:
Coding, syntax & commands
TEXT TO x TEXTMERGE NOSHOW
SELECT * ;
FROM TABLE <> ;
into cursor temp
ENDTEXT
x = CHRTRAN( m.x, CHR(9)+CHR(10)+CHR(13)+";", "" )
>I am working on converting dos SQL's to VFP. In dos I built a string variable for the query.
>
>X = "select * from table "
>If Empty(somevar)
> X = X + "into cursor temp"
>Else
> X = X + "where fieldname=variablename into cursor temp”
>EndIf
>&X
>
>Something like that. It worked great, but I have been rewriting these statements using VFP. I know I can still do them the same way, but is there a better way?
>
>I could write each query out into its own statement with all the conditions, but was curious if anyone else had a different idea on this.
>
>Thanks,
>Dale
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only