Issue Details (XML | Word | Printable)

Key: DERBY-4078
Type: Improvement Improvement
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Rick Hillegas
Reporter: Rick Hillegas
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Derby

Document the SQL Standard routine matching rules which Derby now supports

Created: 02/Mar/09 07:29 PM   Updated: 04/May/09 06:21 PM
Component/s: Documentation
Affects Version/s: 10.5.1.1
Fix Version/s: 10.5.1.1

Time Tracking:
Not Specified

File Attachments:
  Size
File Licensed for inclusion in ASF works derby-4078-01-aa-refGuide.diff 2009-03-03 08:48 PM Rick Hillegas 12 kB
File Licensed for inclusion in ASF works derby-4078-01-aa-refGuide.tar 2009-03-03 08:48 PM Rick Hillegas 50 kB
File Licensed for inclusion in ASF works derby-4078-01-ab-refGuide.diff 2009-03-04 07:54 PM Rick Hillegas 12 kB
File Licensed for inclusion in ASF works derby-4078-01-ab-refGuide.tar 2009-03-04 07:54 PM Rick Hillegas 50 kB
Issue Links:
Incorporates
 

Issue & fix info: Patch Available
Resolution Date: 10/Mar/09 03:38 PM


 Description  « Hide
The Reference Guide should explain the method resolution rules for functions and procedures. The full rules are described in the SignatureMapping.html webpage attached to DERBY-3652. At this point, Derby implements those rules for the datatypes which Derby supports, except for LOB arguments. That exception may be largely lifted as a result of the work being done on DERBY-4066.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Rick Hillegas added a comment - 03/Mar/09 08:48 PM
Attaching derby-4078-01-aa-refGuide.diff and a corresponding tarball of generated html pages: derby-4078-01-aa-refGuide.tar. This patch adds a new section to the Reference Guide, explaining how Derby matches SQL routines to Java methods.

Touches the following files:

A src/ref/rrefsqljargmatching.dita

This new section explains how Derby matches SQL signatures to Java signatures.


M src/ref/rrefcreateprocedurestatement.dita
M src/ref/rrefcreatefunctionstatement.dita

These pages now refer the reader to the signature matching section.


M src/ref/refderby.ditamap

Adds the new section to the table of contents.

Kim Haase added a comment - 04/Mar/09 04:03 PM
This is an excellent writeup, Rick. It's very clearly written. Just a few comments/questions --

In the last bullet item in second bullet list, you might wrap the occurrences of "n" in italics, since they are placeholders.

Example of argument matching: My first thought is, if the created function matches all of those methods, does that mean that such a declaration would cause an error when the function is invoked? Or maybe you could say "would match" instead of "matches", and then note that java.lang.Math provides only the first form of the method and therefore there's no ambiguity?

Is there a particular rationale for the order of types in the table? Just for consistency you might want to use the order in http://db.apache.org/derby/docs/dev/ref/rrefsqlj58560.html, which groups the types similarly but in a slightly different order.

I can see that it is a little hard to figure out where to place the new topic. I was thinking that it would make sense either to put it after the "Statements" section (where CREATE PROCEDURE and CREATE FUNCTION are introduced) or after the "Data types" section. But you probably have a reason for placing it where you did (between "JOIN operations" and "Queries").

Rick Hillegas added a comment - 04/Mar/09 07:54 PM
Thanks for the quick feedback, Kim. I have addressed all of your comments in the next rev of the patch, which I am attaching: derby-4078-01-ab-refGuide

Kim Haase added a comment - 04/Mar/09 10:36 PM
Thanks -- the changes look fine. Looks like you moved the topic outside the "SQL language reference" section to the top level along with "SQL reserved words" and "Derby support for SQL-92 features" -- which probably makes sense. It is sort of on the borderline.

Rick Hillegas added a comment - 05/Mar/09 05:48 PM
Thanks for the review, Kim. I have committed derby-4078-01-ab-refGuide at subversion revision 750519.

I don't have any clear theory about the best place to put this material in the Reference Guide. Feel free to move this section around if you have even a mild preference for some better location. Thanks.

Kim Haase added a comment - 10/Mar/09 03:28 PM
I think the Ref Guide location you chose is just fine, Rick.

+1 to resolve and close this issue.

Rick Hillegas added a comment - 10/Mar/09 03:38 PM
Thanks, Kim.