Skip to content
This repository has been archived by the owner on Nov 26, 2024. It is now read-only.

Commit

Permalink
Added consumercode not null condition
Browse files Browse the repository at this point in the history
  • Loading branch information
Taniya-eGov authored Jun 18, 2024
1 parent 1d8c2ae commit bd0aa85
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
ALTER TABLE egbs_bill_v1 ADD COLUMN IF NOT EXISTS consumercode CHARACTER VARYING(256);

UPDATE egbs_bill_v1 b SET consumerCode = bd.consumercode FROM egbs_billdetail_v1 bd WHERE bd.billid = b.id;
UPDATE egbs_bill_v1 b SET consumerCode = bd.consumercode FROM egbs_billdetail_v1 bd WHERE bd.billid = b.id and b.consumercode is null;

ALTER TABLE egbs_bill_v1 ALTER COLUMN consumercode SET NOT NULL;

Expand Down

0 comments on commit bd0aa85

Please sign in to comment.