Hi all,
I'm a relative beginner, usings databases on a mysql Linux server.
I have two tabels :namen and frames.
namen:
id (prim index)
naam
frames
id (prim index)
id_speler1 (foreign key references namen(id)
...
I use the following code:
frames.Insert;
frames['date']:=DateToStr(date);
frames['time']:=TimeToStr(elapsed);
frames['duur']:=TimeToStr(Elapsed);
frames['id_speler1']:=id_naam1;
frames['id_speler2']:=id_naam2;
frames.post;
And get the message:
Cannot acces field 'id_speler1' as type variant
If I don't use foreign keys, All works ok.
Must be something simple, advice would be welcome
insert record in tabel with foreign keys
I can not reproduce the problem.
Please send me a complete small sample to dmitryg*devart*com to demonstrate it, including a script to create and fill table.
Also supply me the following information:
- the exact version of MyDAC. You can see it in the About sheet of TMyConnection Editor;
- the exact version of your IDE;
- the exact version of MySQL server and client. You can see it in the Info sheet of TMyConnection Editor.
Please send me a complete small sample to dmitryg*devart*com to demonstrate it, including a script to create and fill table.
Also supply me the following information:
- the exact version of MyDAC. You can see it in the About sheet of TMyConnection Editor;
- the exact version of your IDE;
- the exact version of MySQL server and client. You can see it in the Info sheet of TMyConnection Editor.