If the error has been produced in the database engine, it will return the SQL error code. Otherwise, return null.
 

1 error.sqlcode

<error.sqlcode />
Example
Copy
<xsql-script>
    <body>

        <try>
            <body>
                <!-- A exception in the database engine can be performed (description column does not exist) -->
                <insert table='cdiarios'>
                    <column name='descri'>test</column>
                </insert>
            </body>
            <catch>
                <println>Error at line: <error.line/></println>
                <println>.......in tag: <error.tag/></println>
                <println>...root cause: <error.message/></println>
                <println>....sql code1: <error.sqlcode/></println>
            </catch>
        </try>

    </body>
</xsql-script>

Returns:

Copy
Error at line: 7
.......in tag: insert
...root cause: java.sql.SQLException: Column (descri) not found in any table in the query (or SLV is undefined)., 
Column (descri) not found in any table in the query (or SLV is undefined).
...node cause: java.sql.SQLException: Column (descri) not found in any table in the query (or SLV is undefined)., 
Column (descri) not found in any table in the query (or SLV is undefined).
....sql code1: -217