Method Field Question

Ruslan Zasukhin ruslan_zasukhin at valentina-db.com
Fri Jul 11 16:03:18 CDT 2014


On 7/11/14, 11:46 AM, "Karl Grob" <kgrob at mus.ch> wrote:

Hi Karl,

> I have a hierarchical tree of 3 tables: tblBlaetter, tblSeiten, tblRahmen
> (always 1:m from left to right).
> I use ObjPtr-Fields to establish the parent-child-Structure.
> 
> In ValentinaStudio I make the SQL-statement:
> 
> 'SELECT ptrBlaetter FROM tblSeiten, tblRahmen WHERE tblSeiten.RecID =
> tblRahmen.ptrSeiten‘.
> 
> This gives me a correct result.
> 
> If I define in tblRahmen a ULong-MethodField ‚copyPtrBlaetter‘  with the above
> method, this field does not work. Of course I could make real Links, but as
> the thing is strictly hierarchical, I could not really use them. I just need
> the information of the whole hierarchy above the table in question.
> 
> Why doesnt this work or what am I blind for?

1) Method of Table can use only fields of THIS table.
    it seems you try something else

2) Method contains  EXPR rule, but not the whole SELECT.
       SELECT expr1, expr2, expr3 ... FROM T ...


3) I do not see what you want and why?
        you want to have in T3 pointer to T1 ?


You can use then METHOD
    tblRahmen.ptrBlaetter

With formula:
    ptrBlaetter.ptrBlaetter->ptrBlaetter

Here is used  operator ->



-- 
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