Advertisement
QuangDepTrai

Create Auditlog Table

Aug 18th, 2019
126
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. -- ----------------------------
  2. -- Table structure for auditlog_log
  3. -- ----------------------------
  4. DROP TABLE IF EXISTS "public"."auditlog_log";
  5. CREATE TABLE "public"."auditlog_log" (
  6.   "id" int4 NOT NULL,
  7.   "name" varchar(64) COLLATE "pg_catalog"."default",
  8.   "model_id" int4,
  9.   "res_id" int4,
  10.   "user_id" int4,
  11.   "method" varchar(64) COLLATE "pg_catalog"."default",
  12.   "http_session_id" int4,
  13.   "http_request_id" int4,
  14.   "log_type" varchar COLLATE "pg_catalog"."default",
  15.   "create_uid" int4,
  16.   "create_date" timestamp(6),
  17.   "write_uid" int4,
  18.   "write_date" timestamp(6)
  19. )
  20. ;
  21. COMMENT ON COLUMN "public"."auditlog_log"."name" IS 'Resource Name';
  22. COMMENT ON COLUMN "public"."auditlog_log"."model_id" IS 'Model';
  23. COMMENT ON COLUMN "public"."auditlog_log"."res_id" IS 'Resource ID';
  24. COMMENT ON COLUMN "public"."auditlog_log"."user_id" IS 'User';
  25. COMMENT ON COLUMN "public"."auditlog_log"."method" IS 'Method';
  26. COMMENT ON COLUMN "public"."auditlog_log"."http_session_id" IS 'Session';
  27. COMMENT ON COLUMN "public"."auditlog_log"."http_request_id" IS 'HTTP Request';
  28. COMMENT ON COLUMN "public"."auditlog_log"."log_type" IS 'Type';
  29. COMMENT ON COLUMN "public"."auditlog_log"."create_uid" IS 'Created by';
  30. COMMENT ON COLUMN "public"."auditlog_log"."create_date" IS 'Created on';
  31. COMMENT ON COLUMN "public"."auditlog_log"."write_uid" IS 'Last Updated by';
  32. COMMENT ON COLUMN "public"."auditlog_log"."write_date" IS 'Last Updated on';
  33. COMMENT ON TABLE "public"."auditlog_log" IS 'Auditlog - Log';
  34.  
  35. -- ----------------------------
  36. -- Primary Key structure for table auditlog_log
  37. -- ----------------------------
  38. ALTER TABLE "public"."auditlog_log" ADD CONSTRAINT "auditlog_log_pkey" PRIMARY KEY ("id");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement