• Andrew Dunstan's avatar
    Render infinite date/timestamps as 'infinity' for json/jsonb · bda76c1c
    Andrew Dunstan authored
    Commit ab14a73a raised an error in these cases and later the
    behaviour was copied to jsonb. This is what the XML code, which we
    then adopted, does, as the XSD types don't accept infinite values.
    However, json dates and timestamps are just strings as far as json is
    concerned, so there is no reason not to render these values as
    'infinity'.
    
    The json portion of this is backpatched to 9.4 where the behaviour was
    introduced. The jsonb portion only affects the development branch.
    
    Per gripe on pgsql-general.
    bda76c1c
jsonb_1.out 62.2 KB