db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Daniel John Debrunner (JIRA)" <derby-...@db.apache.org>
Subject [jira] Updated: (DERBY-729) Scalar time and date functions return 0 instead NULL when argument is NULL
Date Tue, 18 Jul 2006 20:39:14 GMT
     [ http://issues.apache.org/jira/browse/DERBY-729?page=all ]

Daniel John Debrunner updated DERBY-729:
----------------------------------------

    Summary: Scalar time and date functions return 0 instead NULL when argument is NULL  (was:
Scalar time and date functions return NULL when argument is NULL)

> Scalar time and date functions return 0 instead NULL when argument is NULL
> --------------------------------------------------------------------------
>
>                 Key: DERBY-729
>                 URL: http://issues.apache.org/jira/browse/DERBY-729
>             Project: Derby
>          Issue Type: Bug
>          Components: SQL
>            Reporter: Bernt M. Johnsen
>
> The scalar time and date functions should return NULL when argument is NULL. 
> Sample ij run that reproduces the bug
>     ij> create table dt (ts timestamp);
>     0 rows inserted/updated/deleted
>     ij> insert into dt values ({ts '2005-11-28 14:49:40'}), (NULL);
>     2 rows inserted/updated/deleted
>     ij> select * from dt;
>     TS                        
>     --------------------------
>     2005-11-28 14:49:40.0     
>     NULL                      
>     
>     2 rows selected
>     ij> select {fn hour(ts)} from dt;
>     1          
>     -----------
>     14         
>     0
> might be a problem with other scalar functions too.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message