RE: purgedata can not be put in a transaction?

2018-01-11 Thread Anoop Sharma
currently, purgedata(or truncate) is a non-transactional operation. It is performed by truncating the underlying traf/hbase object. That truncate operation cannot be undone or rolled back as it is not protected by traf transactional layer (dtm). 'drop table' on the other hand, is a transactional o

RE: purgedata can not be put in a transaction?

2018-01-12 Thread Anoop Sharma
set it? Best regards, Yuan -----Original Message- From: Anoop Sharma [mailto:anoop.sha...@esgyn.com] Sent: Friday, January 12, 2018 12:44 PM To: dev@trafodion.apache.org Subject: RE: purgedata can not be put in a transaction? currently, purgedata(or truncate) is a non-transactional operation.

RE: Set autocommit to OFF in db level

2018-01-22 Thread Anoop Sharma
hi, set transaction statements are runtime stmts and only impact that session when issued. They are not like a cqd (control query default) that could be set at system level. By default, autocommit is OFF. But sqlci and trafci set it to ON at startup by internally issuing 'set transaction autocomm

RE: Rowsets in Trafodion

2018-01-23 Thread Anoop Sharma
hi you can look at file executor/ExExeUtilCli.h/cpp. It has code/examples on how to use columnwise or rowwise rowsets from C code in case you want to test different interfaces. Look for cwrs* or rwrs* in that file. java/jdbc app will be easier to use though from a user app interface. But there

RE: Where is the session?

2018-01-23 Thread Anoop Sharma
hi, Is this only for when a connection is made to the master executor(mxosrvr) or does it also apply when a child process (esp, udr server, arkcmp, ...) are started as well? Is this for trafci only or for other clients as well, like odbc/jdbc apps, or sqlci or T2/T4? Is this for the very first

RE: mxosrvr debugging

2018-01-24 Thread Anoop Sharma
yes, show remoteprocess can be used but only from trafci and not from a standalone jdbc program. anoop -Original Message- From: Roberta Marton [mailto:roberta.mar...@esgyn.com] Sent: Wednesday, January 24, 2018 1:46 PM To: dev@trafodion.apache.org Subject: RE: mxosrvr debugging Couple o

RE: Where is the session?

2018-01-29 Thread Anoop Sharma
x27;s ContextCli::beginSession fits me well. Thanks. Regards, Wenjun Zhu. -邮件原件- 发件人: Anoop Sharma [mailto:anoop.sha...@esgyn.com] 发送时间: 2018年1月24日 13:31 收件人: dev@trafodion.apache.org 主题: RE: Where is the session? hi, Is this only for when a connection is made to the master executor(mxosrv

RE: uuid in Trafodion

2018-02-07 Thread Anoop Sharma
hi select uuid(); syntax was added a while back based on corresponding mysql syntax. this syntax was being used for some testing/poc at that time. It could be removed and changed to normal function usage. anoop -Original Message- From: Liu, Ming (Ming) [mailto:ming@esgyn.cn] Sent

RE: problem when adding a new metadata table in Trafodion

2018-03-05 Thread Anoop Sharma
change to metadata tables require version change and MD upgrade. It needs to be done carefully and in a coordinated way as MD upgrades are only done for major releases. As Roberta mentioned, why is TEXT table not sufficient? What kind of metadata changes are being added? In addition to CmpSeabas

RE: a redundant statement?

2018-03-08 Thread Anoop Sharma
yes, the first call to getAtttibutes with entry value of 1 is leftover obsolete code. It could be removed. thanks for finding it. anoop -Original Message- From: Zhu, Wen-Jun Sent: Thursday, March 8, 2018 2:16 AM To: dev@trafodion.apache.org Subject: a redundant statement? Hi, When I

RE: Trafodion systimestamp and current_timestamp

2018-03-09 Thread Anoop Sharma
yes, that is correct. All times are returned as local time of the system where the master executor (mxosrvr) is running. One can also use current_timestamp_utc to return the UTC/GMT equivalent value of current time. If mxosrvr is running in CA and that system's clock is set to represent local ti

RE: unique_id() not documented and get messy code

2018-03-09 Thread Anoop Sharma
latest trafodion code that will be part of traf 2.3 will generate a 36 byte unique id in string format. Apache Trafodion Conversational Interface 2.3.0 Copyright (c) 2015-2017 Apache Software Foundation >>select unique_id() from dual; (EXPR)

RE: how to get original text for value_expression in the parser

2018-03-10 Thread Anoop Sharma
Is this string representation needed for display purpose or something else? There is a virtual 'unparse' method defined on ItemExpr class which is the base class for value_expression. Calling that method will return the string representation by traversing over the tree. This method is used for cre

RE: How and where the ElemDDLColDefault is converted into ElemDDLColDef ?

2018-03-12 Thread Anoop Sharma
ElemDDLColDef is created in parser (sqlparser.y) as part of column_definition production when a column is specified. Fields are adjusted/populated in file ElemDDLCol.cpp in method setColumnAttribute. My suggestion would be to go through sqlparser.y, ElemDDL*.cpp, StmtDDLCreate.cpp(and others),

RE: about the length for varchar

2018-04-23 Thread Anoop Sharma
In current code, varchar datatype with no length is only allowed for the construct: convert(, varchar) It is changed to true in the following parser production: | TOK_CONVERT '(' value_expression ',' {empty_charlen_specifier_allowed =TRUE;} data_type ')' In other cases it i

RE: `log` command in regression test

2018-04-26 Thread Anoop Sharma
in sqlci, log with no argument will stop logging. The doc you refer to is for trafci where 'log off' will stop logging. Not all options listed in that doc specific to trafci are supported in sqlci. Also note that sqlci is not externalized. It is for internal or platform usage only. What change

RE: `log` command in regression test

2018-04-27 Thread Anoop Sharma
s not a block, We do a little trick with the word `exists` as following: * push IF onto the stack, * when meet `exists`, check if the peek of the stack is `IF` or not, if it is, pop the `IF` out. We can determine if it is in block by checking if the stack is empty. -邮件原件- 发件人: Anoop

RE: Question about trafodion insert

2018-04-27 Thread Anoop Sharma
For each insert statement, sql engine need to: - compile the query - begin transaction - send data to hbase server - commit transaction. For simple queries like an insert, most of the cost is in the 3rd step where values are sent to hbase server. This is a process hop from mxosrvr to hbase region

RE: Tables left over from regression test runs

2018-05-01 Thread Anoop Sharma
yes, it is true that some tests do not drop all the tables that are created as part of that test. This is not always intentional and at times it is because one missed cleaning them up. But there are some advantages of not dropping tables at the end of a test run. - drop hbase tables take a non

RE: Tables left over from regression test runs

2018-05-02 Thread Anoop Sharma
to recreate it from a stripped down version of the test script. I suspect this is true more often than not. So I haven't found this particular argument persuasive. Regarding speeding up HBase drop: Yes, that would be a great idea. Dave -Original Message- From: Anoop Sharma Sent

Trafodion regressions failures: RE: Trafodion master rh6 Daily Test Result - 461 - Failure

2018-06-04 Thread Anoop Sharma
With this checkin, privs2 and udr tests started to show these failures. And they have been consistently showing up since then. Did these pass on committer regressions run? -Original Message- From: steve.var...@esgyn.com Sent: Friday, June 1, 2018 5:38 AM To: dev@trafodion.apache.org Subj

RE: Trafodion regressions failures: RE: Trafodion master rh6 Daily Test Result - 461 - Failure

2018-06-05 Thread Anoop Sharma
dealing with udfs. anoop From: Yang, Yong-Feng (Andy) Sent: Monday, June 4, 2018 8:27 PM To: Anoop Sharma ; dev@trafodion.apache.org Subject: 答复: Trafodion regressions failures: RE: Trafodion master rh6 Daily Test Result - 461 - Failure Yes, it passed the regressions run. I don’t know why it would

RE: How to rename schema name quickly

2018-06-29 Thread Anoop Sharma
hi that operation is not supported as it is not a quick, metadata only change. Every traf table under a schema has corresponding hbase object of form: TRAFODION... Which means that all physical HBase objects need to be renamed/copied to the other name of the form TRAFODION... In addition, al

RE: Trafodion master rh6 Daily Test Result - 512 - Failure

2018-07-22 Thread Anoop Sharma
all regression failures are related to trafodion-3101 get command change. -Original Message- From: steve.var...@esgyn.com Sent: Sunday, July 22, 2018 5:02 AM To: dev@trafodion.apache.org Subject: Trafodion master rh6 Daily Test Result - 512 - Failure Daily Automated Testing master rh6

RE: How to analyze the completed sql statement

2018-07-30 Thread Anoop Sharma
once the query finishes, it is removed from rms and moved to repository unless it is a short running query. To see explain from repository, use the following command: (in your example, you are missing the keyword ‘QID’). >>explain options 'f' qid mxid123456 from repository; LC RC

RE: expression involving NULL and special process on it

2018-08-22 Thread Anoop Sharma
hi if the 'when' clause of a case stmt evaluates to non-true (false or null), it should branch to the 'else' part without evaluating the 'then' part. Since it is not doing that, this is a bug. You can do a showplan that shows the clauses generated for the 'case' stmt. Check why the branch claus

RE: expression involving NULL and special process on it

2018-09-21 Thread Anoop Sharma
Constraints on other datatype would not prevent the insertion. I cannot see why. 2. In the constraint, 1 is important, is OK. i.e. (int1<1) prevents the insertion, but (int<) does not. Thank you. Regards, Wenjun Zhu -邮件原件

RE: How to get a sort_groupby plan

2018-10-17 Thread Anoop Sharma
hi Yuan what was the reason or motivation behind your original question of ways to get a sort_groupby plan? Is it for a deeper understanding of a sort groupby plan, or to do perf comparison between hash and sort groupby, or you felt that your original query would run better with sort groupby, or

RE: [外部邮件] Re: How to get vsbb_scan plan?

2018-10-17 Thread Anoop Sharma
you may also be able to get a vsbb scan with rowset operations on a single table. something like: select * from t where a = This will internally be changed to a nested join with rowset of key values being passed to the inner table being scanned. So ultimately a nested join with multiple key pre