[SQL] Related table question

Ruslan Zasukhin sunshine at public.kherson.ua
Fri Jan 16 09:41:06 CST 2004


on 1/16/04 7:43 AM, Eric Forget at forgete at cafederic.com wrote:

> Hi Ruslan,
> 
> Let's restart from scratch, since more I looking at it more problems I found
> and you won't follow me...
> 
> What I'm trying to implement is a find dialog where the user specify the
> conditions. Look at the Rule editor of the Mac OS X Mail (in the preferences
> dialog) to see what I'm doing. The user can choose whether the conditions
> must all match or just one.
> 
> For almost all the conditions (except 2) everything is working fine. As an
> example I dynamically create:
> 
>   SELECT DISTINCT Table1.CalcID, Table1.Label
>   FROM Table1
>   WHERE (Table1.LowerName LIKE '\Ap') AND (Table1.Modified > '2004-01-13')
>   ORDER BY Table1.LowerName
> 
> Or
> 
>   SELECT DISTINCT Table1.CalcID, Table1.Label
>   FROM Table1
>   WHERE (Table1.LowerName LIKE '\Ap') OR (Table1.Modified > '2004-01-13')
>   ORDER BY Table1.LowerName
> 
> Calc.ID is a method equal to RecID, as you suggested me earlier today. These
> 2 examples works fine.
> 
> However for the 2 cases where I have a related table, e.g. Keywords, things
> are not working well:
> 
> 1) I'm not able to simulate "has not" with Keyword.Name. "has" works fine.
> 
> 2) I'm unable to add them to the Boolean operation for the WHERE clause.
> 
> The meaningful fields of table Keyword looks like this:
> 
>   Table1      ObjectPtr
>   Name        String
> 
> There may be 0-N Keyword record for each Table1.
> 
> Do you have any ideas on how I should proceed?

Can you send me DATABASE with 2 tables and few records?
And tell me what result you want to see using YOUR data?

Then I will play in Vstudio with your db

-- 
Best regards,
Ruslan Zasukhin      [ I feel the need...the need for speed ]
-------------------------------------------------------------
e-mail: ruslan at paradigmasoft.com
web: http://www.paradigmasoft.com

To subscribe to the Valentina mail list go to:
http://lists.macserve.net/mailman/listinfo/valentina
-------------------------------------------------------------



More information about the Valentina mailing list