You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by bu...@apache.org on 2002/10/06 11:17:01 UTC

DO NOT REPLY [Bug 13344] New: - SQLTransformer: syntax error when submitting Oracle Stored Procedures spanning more than one line of code

DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=13344>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=13344

SQLTransformer: syntax error when submitting Oracle Stored Procedures spanning more than one line of code

           Summary: SQLTransformer: syntax error when submitting Oracle
                    Stored Procedures spanning more than one line of code
           Product: Cocoon 2
           Version: 2.0.3
          Platform: PC
        OS/Version: Windows NT/2K
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: general components
        AssignedTo: cocoon-dev@xml.apache.org
        ReportedBy: lmorandini@ieee.org


The Cocoon 2.0.3 version of SQLTransformer lacks the characters method, which in
Cocoon 2.0.2 took care of the proper concatenation
of queries (something super.characters(), apparently, cannot do).

Here's my patch (just a slightly modified version of the Cocoon 2.0.2 method):

    public void characters( char ary[], int start,
                            int length ) throws SAXException {
        if ( current_state != SQLTransformer.STATE_INSIDE_VALUE_ELEMENT &&
             current_state != SQLTransformer.STATE_INSIDE_QUERY_ELEMENT &&
             current_state != SQLTransformer.STATE_INSIDE_ESCAPE_STRING ) {
            super.characters( ary, start, length );
        }
        getLogger().debug( "RECEIVED CHARACTERS: " +
                           new String( ary, start, length ) );
		this.getCurrentQuery().addQueryPart( new String( ary, start, length ) );
    }

Could someone test it properly and put it in the next Cocoon release ?

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org