[ http://issues.apache.org/jira/browse/DERBY-1575?page=all ]
Kim Haase updated DERBY-1575:
-----------------------------
Attachment: DERBY-1575.diff
Here is a patch that I hope fixes the CASE syntax.
I noticed that the formatting in general was inconsistent with the formatting
for the other built-in functions. So I also changed the file to use bold,
parentheses, and capitalization similarly to the way the others do (though the
others are not totally consistent either).
I also removed the semicolon from the SQL statement in the first CASE example,
since it is not in an ij example (per the Documentation Style Issue thread on
derby-dev on 8/21 and 8/22).
Please let me know if more changes are needed. Thanks!
> document full syntax of CASE expression
> ---------------------------------------
>
> Key: DERBY-1575
> URL: http://issues.apache.org/jira/browse/DERBY-1575
> Project: Derby
> Issue Type: Improvement
> Components: Documentation
> Reporter: Christian d'Heureuse
> Assigned To: Kim Haase
> Attachments: DERBY-1575.diff
>
>
> The documentation at
> http://db.apache.org/derby/docs/dev/ref/rrefcasenullif.html describes the
> CASE expression syntax as:
> CASE WHEN BooleanExpression THEN thenExpression ELSE elseExpression END
> But the CASE expression supports more than one WHEN/THEN clauses.
> I suggest to change the syntax description to:
> CASE
> WHEN BooleanExpression THEN Expression
> [ WHEN BooleanExpression THEN Expression ]
> ...
> ELSE elseExpression
> END
> Example:
> VALUES
> CASE
> WHEN 1 = 2 THEN 3
> WHEN 4 = 5 THEN 6
> ELSE 7
> END
--
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