db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christian d'Heureuse (JIRA)" <derby-...@db.apache.org>
Subject [jira] Commented: (DERBY-7) Bug in NULLIF Function
Date Mon, 10 Jan 2005 23:30:13 GMT
     [ http://issues.apache.org/jira/browse/DERBY-7?page=comments#action_57488 ]
Christian d'Heureuse commented on DERBY-7:

> I have a feeling we are not confirming to SQL standard

Are you referring to the syntax rule that states that all arguments "shall" be character strings,
if any argument is character string?

"9075-2 9.3 Data types of results of aggregations
Syntax Rules
3. a) If any of the data types in DTS is character string, then all data types in DTS shall
be character string, ..."

The term "shall" is defined as:

"9075-1 Terms denoting rule requirements
In the Syntax Rules, the term shall defines conditions that are required to be true of syntactically
conforming SQL language. ...
The treatment of language that does not conform to the SQL Formats and Syntax Rules is implementation-dependent.

The conclusion is that the expression
 CASE WHEN ... THEN intValue ELSE charValue END
is non-conforming SQL and may be processed in an implementation-dependent manner.

> Bug in NULLIF Function
> ----------------------
>          Key: DERBY-7
>          URL: http://issues.apache.org/jira/browse/DERBY-7
>      Project: Derby
>         Type: Bug
>   Components: SQL
>     Versions:
>     Reporter: Tulika Agrawal
>     Priority: Minor
>  Attachments: Derby-7.txt
> Reporting for Christian d'Heureuse, filed on derby-dev list.
> The NULLIF built-in function of Cloudscape beta seems to accept
> only string values.
> Examples:
>  values nullif('a','b');
>  --> OK
>  values nullif(1,2);
>  --> Error message: "ERROR 42X89: Types 'CHAR' and
>      'INTEGER' are not type compatible. (Neither type
>      is assignable to the other type.)"

This message is automatically generated by JIRA.
If you think it was sent incorrectly contact one of the administrators:
If you want more information on JIRA, or have a bug to report see:

View raw message