clkao / plv8js-migrated

Automatically exported from code.google.com/p/plv8js
Other
0 stars 0 forks source link

date conversion regression failure #4

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

Make installcheck 

What is the expected output? What do you see instead?

instead of success, this failure:

*** /home/andrew/plv8js/expected/plv8.out   2011-09-10 15:35:14.000000000 -0400
--- /home/andrew/plv8js/results/plv8.out    2011-09-22 18:33:18.088773716 -0400
***************
*** 153,159 ****
  SELECT text_to_date('23 Dec 2010 GMT');
   text_to_date 
  --------------
!  12-23-2010
  (1 row)

  CREATE FUNCTION oidfn(id oid) RETURNS oid AS $$ return id $$ LANGUAGE plv8;
--- 153,159 ----
  SELECT text_to_date('23 Dec 2010 GMT');
   text_to_date 
  --------------
!  05-02-474040
  (1 row)

  CREATE FUNCTION oidfn(id oid) RETURNS oid AS $$ return id $$ LANGUAGE plv8;

Looks like it's probably an issue in EpochToDate()

Original issue reported on code.google.com by AMDuns...@gmail.com on 22 Sep 2011 at 11:04

GoogleCodeExporter commented 9 years ago
I have pushed a fix for this. I'm leaving this open because we need to look at 
all the functions that return a Datum and use the appropriate macros.

Original comment by AMDuns...@gmail.com on 23 Sep 2011 at 9:03

GoogleCodeExporter commented 9 years ago
Fixed for non-integer timestamp case. Everything else seems kosher, so closing.

Original comment by AMDuns...@gmail.com on 5 Jul 2012 at 12:55