Last active
August 29, 2015 14:26
-
-
Save bmorton/33e572b9d5b2655d1a9e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"type": "record", | |
"name": "test", | |
"namespace": "com.martinkl.bottledwater.dbschema.public", | |
"fields": [ | |
{ | |
"name": "id", | |
"type": [ | |
{ | |
"type": "null" | |
}, | |
{ | |
"type": "int" | |
} | |
] | |
}, | |
{ | |
"name": "value", | |
"type": [ | |
{ | |
"type": "null" | |
}, | |
{ | |
"type": "string" | |
} | |
] | |
}, | |
{ | |
"name": "created_at", | |
"type": [ | |
{ | |
"type": "null" | |
}, | |
{ | |
"type": "record", | |
"name": "DateTime", | |
"namespace": "com.martinkl.bottledwater.datatypes", | |
"fields": [ | |
{ | |
"name": "year", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "month", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "day", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "hour", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "minute", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "second", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "micro", | |
"type": { | |
"type": "int" | |
} | |
} | |
] | |
}, | |
{ | |
"type": "enum", | |
"name": "SpecialTime", | |
"symbols": [ | |
"POS_INFINITY", | |
"NEG_INFINITY" | |
] | |
} | |
] | |
}, | |
{ | |
"name": "updated_at", | |
"type": [ | |
{ | |
"type": "null" | |
}, | |
{ | |
"type": "record", | |
"name": "DateTime", | |
"namespace": "com.martinkl.bottledwater.datatypes", | |
"fields": [ | |
{ | |
"name": "year", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "month", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "day", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "hour", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "minute", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "second", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "micro", | |
"type": { | |
"type": "int" | |
} | |
} | |
] | |
}, | |
{ | |
"type": "enum", | |
"name": "SpecialTime", | |
"symbols": [ | |
"POS_INFINITY", | |
"NEG_INFINITY" | |
] | |
} | |
] | |
} | |
] | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
create extension bottledwater; | |
create table test ( | |
id serial primary key, | |
value text, | |
created_at timestamp without time zone, | |
updated_at timestamp without time zone | |
); | |
insert into test (value, created_at, updated_at) values('hello world!', NOW(), NOW()); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"type": "record", | |
"name": "test", | |
"namespace": "com.martinkl.bottledwater.dbschema.public", | |
"fields": [ | |
{ | |
"name": "id", | |
"type": [ | |
{ | |
"type": "null" | |
}, | |
{ | |
"type": "int" | |
} | |
] | |
}, | |
{ | |
"name": "value", | |
"type": [ | |
{ | |
"type": "null" | |
}, | |
{ | |
"type": "string" | |
} | |
] | |
}, | |
{ | |
"name": "created_at", | |
"type": [ | |
{ | |
"type": "null" | |
}, | |
{ | |
"type": "record", | |
"name": "DateTime", | |
"namespace": "com.martinkl.bottledwater.datatypes", | |
"fields": [ | |
{ | |
"name": "year", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "month", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "day", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "hour", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "minute", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "second", | |
"type": { | |
"type": "int" | |
} | |
}, | |
{ | |
"name": "micro", | |
"type": { | |
"type": "int" | |
} | |
} | |
] | |
}, | |
{ | |
"type": "enum", | |
"name": "SpecialTime", | |
"symbols": [ | |
"POS_INFINITY", | |
"NEG_INFINITY" | |
] | |
} | |
] | |
}, | |
{ | |
"name": "updated_at", | |
"type": [ | |
{ | |
"type": "null" | |
}, | |
{ | |
"type": "com.martinkl.bottledwater.datatypes.DateTime" | |
}, | |
{ | |
"type": "SpecialTime" | |
} | |
] | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment