date field changing on record save

Please report bugs and any annoyances here. Kindly include all possible details: steps to reproduce, expected result, actual result, screenshots, ... etc.
Post Reply
mgoetze
Posts: 23
Joined: 2014-12-02 06:59

date field changing on record save

Post by mgoetze » 2014-12-02 07:05

Hi everyone,
I am experiencing a strange bug related to date fields. I have a date field which is
Data type: date
Default: <%%creationDate%%>
Read Only box is checked...
The problem is that every time we go in and edit the record and click Save, the date field changes to today's date. It seems AppGini is mixing up created date with edited date. I've check all our settings 10 times but I cant seem to fix this. Has anyone seen this or does anyone have any advice on how I might fix this? Any advice or possible solutions are greatly appreciated.

Thank you,
Mark

Bertv
Veteran Member
Posts: 65
Joined: 2013-12-11 15:59

Re: date field changing on record save

Post by Bertv » 2014-12-02 09:27

Hi,
I have the same problem a read-only date field.
Other read-only fields don't exist in the generated update sql, but read-only date fields do. but the value of the data array is empty.
So an read-only date field without a default has after an update of another field an null value.

My solution: a before update trigger with:

begin
set new.rms_xxxdate = old.xxxdate;
end;
Bert
I am using Appgini 5.75

rmloehmann
Posts: 10
Joined: 2014-03-31 22:28

Re: date field changing on record save

Post by rmloehmann » 2015-02-24 18:13

I had this issue and had to use the <%%creationDateTime%%> set as a read only field instead of just creationdate to get it to work properly.

Post Reply