VObjectPtr and Query question

Ruslan Zasukhin sunshine at public.kherson.ua
Wed May 4 23:50:24 CDT 2005


On 5/4/05 9:01 PM, "Gary Edge" <valentina at panamind.com> wrote:

Hi Gary.

> I knew this but can't wrap my mind around it now.
> 
> I need to perform a 'many to one' query. With a given <value> I need to
> select multiple records from Table1. Each record in Table1 has one
> corresponding record in Table2 that I want to include in the query.
> 
> Database1
>    Table1
>        |___Field1 as VObjectPtr("field1",...
>        |___Field2 as VString("field2",20)
> 
> 
>    Table2
>        |___Field1 as VObjectPtr("field1",database1.table1,kV_Cascade)
>        |___Field2 as VString("field2",20)
> 
> I want to select from table1 where each record pulls the data from
> table2.
> 
> This query doesn't produce any results:
> 
> c = Database1.sqlselect("select table1.field2,table2.field2 from
> table1, table2 where table1.field1 = <value>")
> 
> I'm I in the ballpark?

Do you use v1 or v2 ?

IT seems your query is ok:

select 
    table1.field2,table2.field2
from 
    table1, table2 
where 
    table1.field1 = <value>


-- 
Best regards,

Ruslan Zasukhin
VP Engineering and New Technology
Paradigma Software, Inc

Valentina - Joining Worlds of Information
http://www.paradigmasoft.com

[I feel the need: the need for speed]




More information about the Valentina mailing list