Use OLD.donor_id, as NEW.donor_id will actually be NULL probably.

This commit is contained in:
Bradley M. Kuhn 2022-11-21 11:39:05 -08:00
parent d505f69f00
commit deb31e9c18

View file

@ -410,7 +410,7 @@ SELECT CASE
END; END;
INSERT OR IGNORE INTO request(donor_id, request_type_id, request_configuration_id, date_requested, notes) INSERT OR IGNORE INTO request(donor_id, request_type_id, request_configuration_id, date_requested, notes)
VALUES(NEW.donor_id, 12, VALUES(OLD.donor_id, 12,
(SELECT new_request_configuration_id from zz__temp_request_configuration_change), (SELECT new_request_configuration_id from zz__temp_request_configuration_change),
date("now"), NEW.note); date("now"), NEW.note);