[ https://issues.apache.org/jira/browse/TRAFODION-2299?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Hans Zeller updated TRAFODION-2299: ----------------------------------- Description: The sqlci tool looks at the first word of a query to determine what type of statement it is: SELECT --> a select query UPDATE --> an update statement (or update statistics, need to look at second word) With the new WITH syntax, that is not so easy anymore. An SQL statement that begins with WITH is usually a select statement, but it could also be another type of DML statement, like insert, update, delete. Right now, sqlci does not show the number of rows selected when it encounters a select using the WITH clause. The same is true for trafci: {noformat} >>with q as (values (10)) select * from q; (EXPR) ------ 10 --- SQL operation complete. >>values (10); (EXPR) ------ 10 --- 1 row(s) selected. >> {noformat} We could try to improve that. was: The sqlci tool looks at the first word of a query to determine what type of statement it is: SELECT --> a select query UPDATE --> an update statement (or update statistics, need to look at second word) With the new WITH syntax, that is not so easy anymore. An SQL statement that begins with WITH is usually a select statement, but it could also be another type of DML statement, like insert, update, delete. Right now, sqlci does not show the number of rows selected when it encounters a select using the WITH clause. The same is true for trafci: >>with q as (values (10)) select * from q; (EXPR) ------ 10 --- SQL operation complete. >>values (10); (EXPR) ------ 10 --- 1 row(s) selected. >> We could try to improve that. > SQL statement type is not clear when using the WITH clause > ---------------------------------------------------------- > > Key: TRAFODION-2299 > URL: https://issues.apache.org/jira/browse/TRAFODION-2299 > Project: Apache Trafodion > Issue Type: Improvement > Components: sql-general > Affects Versions: 2.1-incubating > Reporter: Hans Zeller > Priority: Minor > > The sqlci tool looks at the first word of a query to determine what type of > statement it is: > SELECT --> a select query > UPDATE --> an update statement (or update statistics, need to look at second > word) > With the new WITH syntax, that is not so easy anymore. An SQL statement that > begins with WITH is usually a select statement, but it could also be another > type of DML statement, like insert, update, delete. > Right now, sqlci does not show the number of rows selected when it encounters > a select using the WITH clause. The same is true for trafci: > {noformat} > >>with q as (values (10)) select * from q; > (EXPR) > ------ > 10 > --- SQL operation complete. > >>values (10); > (EXPR) > ------ > 10 > --- 1 row(s) selected. > >> > {noformat} > We could try to improve that. -- This message was sent by Atlassian JIRA (v6.3.4#6332)