Hi,
I have a MyTable and have created several Lookup fields into sub-tables that work fine. Now, I've tried to created a lookup into a table that uses several fields as a key and it doesn't work.
In the main table,
KeyFields=switch;port
LookupUpdataSet=taPort (this is a MyTable)
LookupKeyFields=switch;name
LookupResultField=location
All fields are strings, in the taPort table, the columns switch and name provide the key. In the main table I want to use the combination of switch and port as the key into taPort.
Does MyTable support this or do I have an error?
I use 3.30.0.12 on D7
Another little question: I keep leaving my DB connected at design time, which gives errors when running in production (different DBs are used). Is there an event I can hang into somewhere that Sets MyConnection1.Connect:=false somewhere on startup early on?
Thanks in advance,
Sean
Mytable Lookup with Multiple KeyFields
Re: Mytable Lookup with Multiple KeyFields
> Does MyTable support this or do I have an error?
We checked MyDAC and couldn't reproduce the problem. Please contact us by email and we'll send you this sample by email.
Is it possible that some of these fields are Int64 (BIGINT)? Delphi doesn't support Lookup by such fields.
> Is there an event I can hang into somewhere that Sets
> MyConnection1.Connect:=false somewhere on startup early on?
Pay attention to MyConnection.Options.KeepDesignConnected property. But an error in this property was found in version 3.30.0.12 and you should use 3.30.1.13.
We checked MyDAC and couldn't reproduce the problem. Please contact us by email and we'll send you this sample by email.
Is it possible that some of these fields are Int64 (BIGINT)? Delphi doesn't support Lookup by such fields.
> Is there an event I can hang into somewhere that Sets
> MyConnection1.Connect:=false somewhere on startup early on?
Pay attention to MyConnection.Options.KeepDesignConnected property. But an error in this property was found in version 3.30.0.12 and you should use 3.30.1.13.