Problem inserting/updating table from a calculating field
Posted: Thu 09 Jun 2011 08:14
when I post dataset the changed calculated field is not updated
see my example:
dataset = GetDataSet('SELECT ISNULL(ALT1, '') ALT1, ALT2 FROM STOCK WHERE PARTNUMBER = 'TABLE')
dataset.Edit();
dataset.FieldByName(ALT1).AsString = 'new alt1';
dataset.FieldByName(ALT2).AsString = 'new alt2';
dataset.Post();
only field ALT2 is updated
also the ALT1 field is not allowed to get value. I get error "field 'ALT1' cannot be modified" after changing readonly property of this field Im allowed to set new value but as I said previosly this field is not posted
there is no restriction with dbExpress driver
see my example:
dataset = GetDataSet('SELECT ISNULL(ALT1, '') ALT1, ALT2 FROM STOCK WHERE PARTNUMBER = 'TABLE')
dataset.Edit();
dataset.FieldByName(ALT1).AsString = 'new alt1';
dataset.FieldByName(ALT2).AsString = 'new alt2';
dataset.Post();
only field ALT2 is updated
also the ALT1 field is not allowed to get value. I get error "field 'ALT1' cannot be modified" after changing readonly property of this field Im allowed to set new value but as I said previosly this field is not posted
there is no restriction with dbExpress driver