Skip to content

Commit

Permalink
Postgres: added derived_tstamp column (closes #1559)
Browse files Browse the repository at this point in the history
  • Loading branch information
fblundun committed Mar 26, 2015
1 parent f408fd2 commit 7f7aacd
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
4 changes: 3 additions & 1 deletion 4-storage/postgres-storage/sql/atomic-def.sql
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,9 @@ CREATE TABLE "atomic"."events" (
-- Derived contexts
"derived_contexts" json, -- Added in 0.4.0
-- Session ID
"session_id" char(36) -- Added in 0.4.0
"session_id" char(36), -- Added in 0.4.0
-- Derived timestamp
"derived_tstamp" timestamp -- Added in 0.4.0
-- Removed primary key constraint on event_id in 0.4.0
)
WITH (OIDS=FALSE)
Expand Down
7 changes: 5 additions & 2 deletions 4-storage/postgres-storage/sql/migrate_0.3.0_to_0.4.0.sql
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,9 @@ CREATE TABLE "atomic"."events" (
-- Derived contexts
"derived_contexts" json, -- Added in 0.4.0
-- Session ID
"session_id" char(36) -- Added in 0.4.0
"session_id" char(36), -- Added in 0.4.0
-- Derived timestamp
"derived_tstamp" timestamp -- Added in 0.4.0
-- Removed primary key constraint on event_id in 0.4.0
)
WITH (OIDS=FALSE)
Expand Down Expand Up @@ -305,6 +307,7 @@ INSERT INTO atomic.events
NULL AS "refr_domain_userid", -- Added in 0.4.0
NULL AS "refr_dvce_tstamp", -- Added in 0.4.0
NULL AS "derived_contexts", -- Added in 0.4.0
NULL AS "session_id" -- Added in 0.4.0
NULL AS "session_id", -- Added in 0.4.0
NULL AS "derived_tstamp" -- Added in 0.4.0

FROM atomic.events_030;

0 comments on commit 7f7aacd

Please sign in to comment.