lovasoa opened a new issue, #1816:
URL: https://github.com/apache/datafusion-sqlparser-rs/issues/1816

   Postgres, db2, and oracle all support the `xmltable` table-valued function.
   
   ```sql
   
   SELECT xmltable.*
       FROM xmldata,
       XMLTABLE('//ROWS/ROW'
           PASSING data
               COLUMNS id int PATH '@id',
               ordinality FOR ORDINALITY,
               "COUNTRY_NAME" text,
               country_id text PATH 'COUNTRY_ID',
               size_sq_km float PATH 'SIZE[@unit = "sq_km"]',
               size_other text PATH 'concat(SIZE[@unit!="sq_km"], " ", 
SIZE[@unit!="sq_km"]/@unit)',
               premier_name text PATH 'PREMIER_NAME' DEFAULT 'not specified');
   ```
   
   Currently, sqlparser fails to parse it with the following error: `Expected: 
), found: PASSING`
   
   
https://www.postgresql.org/docs/15/functions-xml.html#FUNCTIONS-XML-PROCESSING
   
   
https://docs.oracle.com/en/database/oracle/oracle-database/19/sqlrf/XMLTABLE.html
    
   https://www.ibm.com/docs/en/db2/12.1.0?topic=data-xmltable-function
   
   Initially reported in https://github.com/sqlpage/SQLPage/issues/887


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org
For additional commands, e-mail: github-h...@datafusion.apache.org

Reply via email to