V4RB2 vLink
Ruslan Zasukhin
sunshine at public.kherson.ua
Thu Dec 30 14:20:49 CST 2004
On 12/30/04 1:01 PM, "erne" <ernestogiannotta at tiscalinet.it> wrote:
>> When you create link you specify order of tables:
>>
>> db.CreateBinaryLink( ... T1, T2 ...)
>> So when you want link 2 records of these tables you do
>>
>> link.LinkRecords( Array( 3, 5) )
>>
>> And you and Valentina know that
>>
>> 3 -- this is RecID of T1
>> 5 -- this is RecID of T2.
>>
>> Direction is not important here. Absolutely.
>
> still... this limits linked tables to 2 and not more
No limits here. Why you think so?
> and...
> what about a 2 dimensional array to link several record pairs at once?
>
> e.g.
> dim LinksArray(2,2)
>
> LinksArray(0,1) = 3 //-- this is RecID of T1
> LinksArray(0,2) = 5 //-- this is RecID of T2
> LinksArray(1,1) = 3 //-- this is RecID of T1
> LinksArray(1,2) = 6 //-- this is RecID of T2
> LinksArray(2,1) = 4 //-- this is RecID of T1
> LinksArray(2,2) = 5 //-- this is RecID of T2
>
> link.LinkRecords( LinksArray, T1, T2 ) // specify Tables for future
> multitables links
This have sense...but it is just a cosmetic thing.
And I prefer C++ style
LinksArray[3][2] =
{
{ 3, 5 }, { 3, 6 }, { 4, 5 }
}
> imagine this:
>
> dim LinksArray(1,3)
>
> LinksArray(0,1) = 3 //-- this is RecID of T1
> LinksArray(0,2) = 5 //-- this is RecID of T2
> LinksArray(0,3) = 5 //-- this is RecID of T3
> LinksArray(1,1) = 3 //-- this is RecID of T1
> LinksArray(1,2) = 6 //-- this is RecID of T2
> LinksArray(1,3) = 4 //-- this is RecID of T3
>
> link.LinkRecords( LinksArray, T1, T2, T3 ) // specify Tables for future
> multitables links
--
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-beta
mailing list