我正在从sqlserver迁移到postgresql。并在sqlserver中有一个表,该表创建一个表列,该表列从其他两列中减去值。可以在sqlserver中完成,但不能在PostgreSQL中完成。
CREATE TABLE "AUDIT_LOG"
("Id" integer NOT NULL DEFAULT ,
"DateTime" timestamp without time zone,
"Source_Database" character varying(100),
"Target_Database" character varying(100),
"Source_Table" character varying(100),
"Target_Table" character varying(100),
"Source_Record_Count" integer,
"Target_Record_Count" integer,
"Variance" AS (Source_Record_Count-Target_Record_Count)
)
如何在postgresql中具有等效的创建脚本?