ambiguous columname 'ID'

Discussion of open issues, suggestions and bugs regarding UniDAC (Universal Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
norwegen60
Posts: 19
Joined: Wed 15 Dec 2010 13:12

ambiguous columname 'ID'

Post by norwegen60 » Mon 21 Feb 2011 14:51

Hello,
with TUniQuery I have following Problem:

Code: Select all

SQL = 'select * from Ser_Nr'
DetailFiled ='ID'
MasterFields = 'ID'
MasterSource = 'dbdsTable2'
Everything is OK and I can open the SQL without problems. But then, if I change

Code: Select all

SQL = SELECT S.*, E.Name as defErstUser
FROM Ser_nr S
LEFT OUTER JOIN Who_Gru1 E on E.ID = S.ErstUserID
I get the message "Mehrdeutiger Spaltenname 'ID'" No problem again, if I set

Code: Select all

MasterFields = ''
This was no problem with ADODataset. What´s wrong?

thanks
Gerd

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Post by AlexP » Tue 22 Feb 2011 08:27

Hello,

To resolve the problem you should set the DetailFiled property like

DetailFiled := 'S.ID';

norwegen60
Posts: 19
Joined: Wed 15 Dec 2010 13:12

Post by norwegen60 » Sun 27 Feb 2011 14:57

AlexP wrote:To resolve the problem you should set the DetailFiled property like

DetailFiled := 'S.ID';
Perfect! Now it runs

Thanks, Gerd

AlexP
Devart Team
Posts: 5530
Joined: Tue 10 Aug 2010 11:35

Post by AlexP » Mon 28 Feb 2011 07:13

Hello,

It is good to see that this problem was solved. If any other questions come up, please contact us.

Post Reply