Last active
February 9, 2016 17:02
-
-
Save scaint/c0dbdcaf930db67245b4 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
CREATE OR REPLACE FUNCTION public.NOW() RETURNS timestamp AS 'SELECT timestamp ''2016-01-01''' LANGUAGE SQL IMMUTABLE; | |
SELECT NOW(); | |
BEGIN; | |
SET LOCAL search_path TO public,pg_catalog; | |
SELECT NOW(); | |
COMMIT; | |
SELECT NOW(); | |
DROP FUNCTION public.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
CREATE FUNCTION | |
now | |
------------------------------- | |
2016-02-09 18:50:13.284655+02 | |
(1 row) | |
BEGIN | |
SET | |
now | |
--------------------- | |
2016-01-01 00:00:00 | |
(1 row) | |
COMMIT | |
now | |
------------------------------- | |
2016-02-09 18:50:13.285317+02 | |
(1 row) | |
DROP FUNCTION |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment