Searching multiple tables....

Charles Yeomans yeomans at desuetude.com
Fri Aug 29 17:49:50 CDT 2003


On Friday, August 29, 2003, at 02:41 PM, Chuck wrote:

> Hi Ruslan:
> 	I am writing these individually so as the subject line will reflect 
> the topic.	
>
> 	I read the manual and followed the instructions closely (VSQL-9 in
> ValentinaSQL.pdf - Table List)...as in...putting a coma between the 
> tables.
>
> 	I was able to get my SQLSelect statement to work only when I listed 
> the table
> names without a coma in between them.
>
> ie: rscursor = mdb.SQLSelect("select for cTable nTable where 
> incid='"+incvalue+"'")
>

The syntax is "SELECT fields FROM tables WHERE (some condition holds).  
So your SQL should read something like

select * from cTable,  nTable where incid='"+incvalue+"'"

Lists of field and table names are delimited by commas, and "*" means 
all fields (excluding recID and method fields).

Charles Yeomans



More information about the Valentina mailing list