Update when using alias fields fails
Posted: Tue 26 Jul 2011 22:24
Trying to move some projects from my ancient ZEOS components to mydac but I run into problems with Alias fields.
I have this query: select Patient.ID,Patient.pFirst AS PatientNameFirst, Patient.PLast AS PatientNameLast
FROM pattable AS Patient
when I try to make changes as follows:
myquery.edit;
myquery.fieldbyname('PatientNameFirst').asString:='something';
myquery.post;
It fails with
Unknown Column PatientNameFirst in field list.
A lot of these type of queries are created in code so I can not specify the SQLUpdate or it will be very time consuming.
As I said before the old ZEOS has no problem with this. My version is 5.90
Let me know if there is a solution to this.
Thanks
I have this query: select Patient.ID,Patient.pFirst AS PatientNameFirst, Patient.PLast AS PatientNameLast
FROM pattable AS Patient
when I try to make changes as follows:
myquery.edit;
myquery.fieldbyname('PatientNameFirst').asString:='something';
myquery.post;
It fails with
Unknown Column PatientNameFirst in field list.
A lot of these type of queries are created in code so I can not specify the SQLUpdate or it will be very time consuming.
As I said before the old ZEOS has no problem with this. My version is 5.90
Let me know if there is a solution to this.
Thanks