Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-03 Thread Yingyi Bu (Code Review)
Yingyi Bu has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 12: Code-Review+2

Fwd Till's +2.

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 12
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-03 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 12: Integration-Tests+1

Integration Tests Successful

https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-integration-tests/1449/ 
: SUCCESS

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 12
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-03 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 12:

Integration Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-integration-tests/1449/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 12
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-03 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 12: BAD-1

BAD Compatibility Tests Failed

https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/171/ : FAILURE

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 12
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-03 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 12:

BAD Compatibility Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/171/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 12
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-03 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 12:

Build Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-notopic/3746/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 12
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-03 Thread Yingyi Bu (Code Review)
Hello Steven Jacobs, Till Westmann, Jenkins,

I'd like you to reexamine a change.  Please visit

https://asterix-gerrit.ics.uci.edu/1401

to look at the new patch set (#12).

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..

ASTERIXDB-1755: add UPSERT in SQL++.

Detailed list of changes included:
- Fix AQL RETURNING clause to use an expression instead of a query;
- Add a rule to check whether a RETURNING expression contains dataset accesses;
- Perform AST-level rewrites for INSERT/UPSERT as a whole, including the
  body query and the returning expression.

Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
---
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/base/RuleCollections.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/CheckInsertUpsertReturningRule.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/InsertUpsertCheckUtil.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AqlExpressionToPlanTranslator.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/CompiledStatements.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/api/common/APIFramework.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
M 
asterixdb/asterix-app/src/test/java/org/apache/asterix/test/sqlpp/ParserTestExecutor.java
M 
asterixdb/asterix-app/src/test/resources/optimizerts/results/insert-return-custom-result.plan
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.3.query.aql
M 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.3.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.4.sleep.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.5.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.6.query.sqlpp
A 
asterixdb/asterix-app/src/te

Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-03 Thread Till Westmann (Code Review)
Till Westmann has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 11: Code-Review+2

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 11
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-03 Thread Yingyi Bu (Code Review)
Yingyi Bu has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 11:

(1 comment)

https://asterix-gerrit.ics.uci.edu/#/c/1401/11/asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql
File 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql:

Line 36: where $y.tweetid=5
> Should the order by be removed as well then?
It doesn't matter -- the stuff after returning is still a valid FLWOGR.  It 
should still work, but shouldn't globally order the results.


-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 11
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: Yes


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-03 Thread Steven Jacobs (Code Review)
Steven Jacobs has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 11: Code-Review+1

(2 comments)

I'm going ahead with my +1 here. I'll fix the corresponding review for bad 
after this gets in, so you don't need to wait for me.

https://asterix-gerrit.ics.uci.edu/#/c/1401/11/asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql
File 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql:

Line 36: where $y.tweetid=5
> Because there is no way that the results can be totally ordered.  Note that
Should the order by be removed as well then?


https://asterix-gerrit.ics.uci.edu/#/c/1401/11/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp
File 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp:

Line 28: insert into TweetMessageuuids as message (
> No. It's SQL++, not AQL.
Sorry, my mistake.


-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 11
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: Yes


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-03 Thread Yingyi Bu (Code Review)
Yingyi Bu has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 11:

(2 comments)

https://asterix-gerrit.ics.uci.edu/#/c/1401/11/asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql
File 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql:

Line 36: where $y.tweetid=5
> why this change?
Because there is no way that the results can be totally ordered.  Note that the 
stuff after returning is an expression, i.e., a FLWOGR expression here, which 
cannot perturb the order of the incoming tuple stream. Therefore only inserting 
one tuple would always get deterministic results.


https://asterix-gerrit.ics.uci.edu/#/c/1401/11/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp
File 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp:

Line 28: insert into TweetMessageuuids as message (
> Do we not require "$" for variables, e.g. "$message?"
No. It's SQL++, not AQL.


-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 11
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: Yes


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-03 Thread Steven Jacobs (Code Review)
Steven Jacobs has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 11:

(2 comments)

A couple of questions on the tests. It seems like this change doesn't break the 
channels stuff, although I will need to revisit the plans which are still 
coming out differently on my corresponding change. I can do that after this 
change is in though.

https://asterix-gerrit.ics.uci.edu/#/c/1401/11/asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql
File 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql:

Line 36: where $y.tweetid=5
why this change?


https://asterix-gerrit.ics.uci.edu/#/c/1401/11/asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp
File 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp:

Line 28: insert into TweetMessageuuids as message (
Do we not require "$" for variables, e.g. "$message?"


-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 11
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: Yes


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-03 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 11: Integration-Tests+1

Integration Tests Successful

https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-integration-tests/1440/ 
: SUCCESS

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 11
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-02 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 11: BAD-1

BAD Compatibility Tests Failed

https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/164/ : FAILURE

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 11
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-02 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 11:

Integration Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-integration-tests/1440/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 11
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-02 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 11:

BAD Compatibility Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/164/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 11
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-02 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 11:

Build Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-notopic/3738/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 11
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-02 Thread Yingyi Bu (Code Review)
Yingyi Bu has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 9:

(14 comments)

https://asterix-gerrit.ics.uci.edu/#/c/1401/9//COMMIT_MSG
Commit Message:

Line 9: Detailed list of changes include:
> s/include/included/?
Done


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/CheckInsertUpsertRule.java
File 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/CheckInsertUpsertRule.java:

Line 3:  *  * Licensed to the Apache Software Foundation (ASF) under one
> Double indentation of comment.
Done


Line 37: public class CheckInsertUpsertRule implements IAlgebraicRewriteRule {
> Should this be called CheckReturningRule? It's really about RETURNING and n
Done


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/InsertUpsertCheckUtil.java
File 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/InsertUpsertCheckUtil.java:

Line 3:  *  * Licensed to the Apache Software Foundation (ASF) under one
> Double indentation of comment.
Done


Line 39: 
> Remove the empty line?
Done


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AqlExpressionToPlanTranslator.java
File 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AqlExpressionToPlanTranslator.java:

Line 175: if (expr.getKind() == Kind.FLWOGR_EXPRESSION) {
> reuse "isFLWOGR" ?
Done


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java
File 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java:

Line 567: if (compiledUpsert.getReturnExpression() != null) {
> Reuse "returnExpression" declared above?
Done


Line 629: rootOperator = new DelegateOperator(new 
CommitOperator(returnExpression == null ? true : false));
> s/returnExpression == null ? true : false/returnExpression == null/ ?
Done


Line 645: rootOperator.getInputs().add(new 
MutableObject<>(upsertOp));
> Could we pull these last 2 lines behind the else?
Done


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-lang-aql/src/main/java/org/apache/asterix/lang/aql/rewrites/AqlQueryRewriter.java
File 
asterixdb/asterix-lang-aql/src/main/java/org/apache/asterix/lang/aql/rewrites/AqlQueryRewriter.java:

Line 61: private void setup(List declaredFunctions, 
StatementWithReturn topExpr,
> Rename parameter to "topStatement" (or "topStmt") as well?
Done


Line 71: public void rewrite(List declaredFunctions, 
StatementWithReturn topExpr,
> Rename parameter to "topStatement" (or "topStmt") as well?
Done


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-lang-common/src/main/java/org/apache/asterix/lang/common/base/StatementWithReturn.java
File 
asterixdb/asterix-lang-common/src/main/java/org/apache/asterix/lang/common/base/StatementWithReturn.java:

Line 3:  *  * Licensed to the Apache Software Foundation (ASF) under one
> Double indentation of comment.
Done


Line 30: public interface StatementWithReturn extends Statement {
> Maybe rename this to "IReturningStatement"? 
Done


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-lang-sqlpp/src/main/java/org/apache/asterix/lang/sqlpp/visitor/base/AbstractSqlppExpressionScopingVisitor.java
File 
asterixdb/asterix-lang-sqlpp/src/main/java/org/apache/asterix/lang/sqlpp/visitor/base/AbstractSqlppExpressionScopingVisitor.java:

Line 365: Expression returningExpr = 
insertStatement.getReturnExpression();
> Move this down to the place where it is used?
Done


-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 9
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: Yingyi Bu 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: Yes


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-02 Thread Yingyi Bu (Code Review)
Hello Jenkins,

I'd like you to reexamine a change.  Please visit

https://asterix-gerrit.ics.uci.edu/1401

to look at the new patch set (#11).

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..

ASTERIXDB-1755: add UPSERT in SQL++.

Detailed list of changes included:
- Fix AQL RETURNING clause to use an expression instead of a query;
- Add a rule to check whether a RETURNING expression contains dataset accesses;
- Perform AST-level rewrites for INSERT/UPSERT as a whole, including the
  body query and the returning expression.

Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
---
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/base/RuleCollections.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/CheckInsertUpsertReturningRule.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/InsertUpsertCheckUtil.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AqlExpressionToPlanTranslator.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/CompiledStatements.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/api/common/APIFramework.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
M 
asterixdb/asterix-app/src/test/java/org/apache/asterix/test/sqlpp/ParserTestExecutor.java
M 
asterixdb/asterix-app/src/test/resources/optimizerts/results/insert-return-custom-result.plan
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.3.query.aql
M 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.3.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.4.sleep.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.5.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.6.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries

Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-02 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 10:

Build Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-notopic/3737/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 10
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-02 Thread Yingyi Bu (Code Review)
Hello Jenkins,

I'd like you to reexamine a change.  Please visit

https://asterix-gerrit.ics.uci.edu/1401

to look at the new patch set (#10).

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..

ASTERIXDB-1755: add UPSERT in SQL++.

Detailed list of changes include:
- Fix AQL RETURNING clause to use an expression instead of a query;
- Add a rule to check whether a RETURNING expression contains dataset accesses;
- Perform AST-level rewrites for INSERT/UPSERT as a whole, including the
  body query and the returning expression.

Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
---
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/base/RuleCollections.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/CheckInsertUpsertReturningRule.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/InsertUpsertCheckUtil.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AqlExpressionToPlanTranslator.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/CompiledStatements.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/api/common/APIFramework.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
M 
asterixdb/asterix-app/src/test/java/org/apache/asterix/test/sqlpp/ParserTestExecutor.java
M 
asterixdb/asterix-app/src/test/resources/optimizerts/results/insert-return-custom-result.plan
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.3.query.aql
M 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.3.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.4.sleep.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.5.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.6.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_

Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-02 Thread Till Westmann (Code Review)
Till Westmann has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 9:

(14 comments)

https://asterix-gerrit.ics.uci.edu/#/c/1401/9//COMMIT_MSG
Commit Message:

Line 9: Detailed list of changes include:
s/include/included/?


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/CheckInsertUpsertRule.java
File 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/CheckInsertUpsertRule.java:

Line 3:  *  * Licensed to the Apache Software Foundation (ASF) under one
Double indentation of comment.


Line 37: public class CheckInsertUpsertRule implements IAlgebraicRewriteRule {
Should this be called CheckReturningRule? It's really about RETURNING and not 
about any other INSERTs or UPSERTs. (Maybe even CheckReturningClauseRule ...).


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/InsertUpsertCheckUtil.java
File 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/InsertUpsertCheckUtil.java:

Line 3:  *  * Licensed to the Apache Software Foundation (ASF) under one
Double indentation of comment.


Line 39: 
Remove the empty line?


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AqlExpressionToPlanTranslator.java
File 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AqlExpressionToPlanTranslator.java:

Line 175: if (expr.getKind() == Kind.FLWOGR_EXPRESSION) {
reuse "isFLWOGR" ?


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java
File 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java:

Line 567: if (compiledUpsert.getReturnExpression() != null) {
Reuse "returnExpression" declared above?


Line 629: rootOperator = new DelegateOperator(new 
CommitOperator(returnExpression == null ? true : false));
s/returnExpression == null ? true : false/returnExpression == null/ ?


Line 645: rootOperator.getInputs().add(new 
MutableObject<>(upsertOp));
Could we pull these last 2 lines behind the else?


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-lang-aql/src/main/java/org/apache/asterix/lang/aql/rewrites/AqlQueryRewriter.java
File 
asterixdb/asterix-lang-aql/src/main/java/org/apache/asterix/lang/aql/rewrites/AqlQueryRewriter.java:

Line 61: private void setup(List declaredFunctions, 
StatementWithReturn topExpr,
Rename parameter to "topStatement" (or "topStmt") as well?


Line 71: public void rewrite(List declaredFunctions, 
StatementWithReturn topExpr,
Rename parameter to "topStatement" (or "topStmt") as well?


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-lang-common/src/main/java/org/apache/asterix/lang/common/base/StatementWithReturn.java
File 
asterixdb/asterix-lang-common/src/main/java/org/apache/asterix/lang/common/base/StatementWithReturn.java:

Line 3:  *  * Licensed to the Apache Software Foundation (ASF) under one
Double indentation of comment.


Line 30: public interface StatementWithReturn extends Statement {
Maybe rename this to "IReturningStatement"? 

"StatementWithReturn" confused me in the beginning as e.g. SQL++ queries don't 
mention RETURN at all and INSERT/UPSERT have a RETURNING clause. 

I'm proposing "IReturningStatement" as a way of saying "this is a statement 
that returns data" and not as "this is a a statement that has a returning 
clause". I see that that still could be confusing but IStatementThatReturnsData 
seems bad as well ...

I propose to prefix the interface name with "I" even though this is 
inconsistent with "Statement", because is is consistent with most other 
interface is in org.apache.asterix.lang.common.base (and I think that we should 
probably rename "Statement" to "IStatement" in another change for more 
consistency).


https://asterix-gerrit.ics.uci.edu/#/c/1401/9/asterixdb/asterix-lang-sqlpp/src/main/java/org/apache/asterix/lang/sqlpp/visitor/base/AbstractSqlppExpressionScopingVisitor.java
File 
asterixdb/asterix-lang-sqlpp/src/main/java/org/apache/asterix/lang/sqlpp/visitor/base/AbstractSqlppExpressionScopingVisitor.java:

Line 365: Expression returningExpr = 
insertStatement.getReturnExpression();
Move this down to the place where it is used?


-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 9
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven J

Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-02 Thread Steven Jacobs (Code Review)
Steven Jacobs has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 9:

@Yingyi - I made the corresponding BAD review and I'll add you to it. I want to 
make sure that that can build before this gets the +2

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 9
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-02 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 9:

BAD Compatibility Tests Failed

https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/158/ : FAILURE

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 9
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2017-01-02 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 9:

BAD Compatibility Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/158/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 9
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-Reviewer: Michael Blow 
Gerrit-Reviewer: Steven Jacobs 
Gerrit-Reviewer: Till Westmann 
Gerrit-Reviewer: abdullah alamoudi 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-29 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 9: Integration-Tests+1

Integration Tests Successful

https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-integration-tests/1409/ 
: SUCCESS

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 9
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 9: BAD-1

BAD Compatibility Tests Failed

https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/133/ : FAILURE

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 9
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 9:

BAD Compatibility Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/133/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 9
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 9:

Integration Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-integration-tests/1409/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 9
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 9:

Build Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-notopic/3690/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 9
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Yingyi Bu (Code Review)
Hello Jenkins,

I'd like you to reexamine a change.  Please visit

https://asterix-gerrit.ics.uci.edu/1401

to look at the new patch set (#9).

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..

ASTERIXDB-1755: add UPSERT in SQL++.

Detailed list of changes include:
- Fix AQL RETURNING clause to use an expression instead of a query;
- Add a rule to check whether a RETURNING expression contains dataset accesses;
- Perform AST-level rewrites for INSERT/UPSERT as a whole, including the
  body query and the returning expression.

Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
---
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/base/RuleCollections.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/CheckInsertUpsertRule.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/InsertUpsertCheckUtil.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AqlExpressionToPlanTranslator.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/CompiledStatements.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/api/common/APIFramework.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
M 
asterixdb/asterix-app/src/test/java/org/apache/asterix/test/sqlpp/ParserTestExecutor.java
M 
asterixdb/asterix-app/src/test/resources/optimizerts/results/insert-return-custom-result.plan
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.3.query.aql
M 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.3.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.4.sleep.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.5.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.6.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feed

Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 8: Integration-Tests-1

Integration Tests Timed Out

https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-integration-tests/1407/ 
: ABORTED

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 8
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 8: BAD-1

BAD Compatibility Tests Failed

https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/131/ : FAILURE

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 8
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 8:

BAD Compatibility Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/131/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 8
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 8:

Integration Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-integration-tests/1407/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 8
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 8:

Build Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-notopic/3688/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 8
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Yingyi Bu (Code Review)
Hello Jenkins,

I'd like you to reexamine a change.  Please visit

https://asterix-gerrit.ics.uci.edu/1401

to look at the new patch set (#8).

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..

ASTERIXDB-1755: add UPSERT in SQL++.

Detailed list of changes include:
- Fix AQL RETURNING clause to use an expression instead of a query;
- Add a rule to check whether a RETURNING expression contains dataset accesses;
- Perform AST-level rewrites for INSERT/UPSERT as a whole, including the
  body query and the returning expression.

Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
---
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/base/RuleCollections.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/CheckInsertUpsertRule.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/InsertUpsertCheckUtil.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AqlExpressionToPlanTranslator.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/CompiledStatements.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/api/common/APIFramework.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
M 
asterixdb/asterix-app/src/test/java/org/apache/asterix/test/sqlpp/ParserTestExecutor.java
M 
asterixdb/asterix-app/src/test/resources/optimizerts/results/insert-return-custom-result.plan
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.3.query.aql
M 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.3.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.4.sleep.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.5.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.6.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feed

Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 5: BAD-1

BAD Compatibility Tests Failed

https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/130/ : FAILURE

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 5
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 6:

Build Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-notopic/3686/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 6
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Yingyi Bu (Code Review)
Hello Jenkins,

I'd like you to reexamine a change.  Please visit

https://asterix-gerrit.ics.uci.edu/1401

to look at the new patch set (#6).

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..

ASTERIXDB-1755: add UPSERT in SQL++.

Detailed list of changes include:
- Fix AQL RETURNING clause to use an expression instead of a query;
- Add a rule to check whether a RETURNING expression contains dataset accesses;
- Perform AST-level rewrites for INSERT/UPSERT as a whole, including the
  body query and the returning expression.

Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
---
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/base/RuleCollections.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/CheckInsertUpsertRule.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/InsertUpsertCheckUtil.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/AqlExpressionToPlanTranslator.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/CompiledStatements.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/api/common/APIFramework.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
M 
asterixdb/asterix-app/src/test/java/org/apache/asterix/test/sqlpp/ParserTestExecutor.java
M 
asterixdb/asterix-app/src/test/resources/optimizerts/results/insert-return-custom-result.plan
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.3.query.aql
M 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.3.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.4.sleep.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.5.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.6.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feed

Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 5:

Integration Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-integration-tests/1406/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 5
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 5:

BAD Compatibility Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/130/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 5
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 5:

Build Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-notopic/3685/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 5
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Yingyi Bu (Code Review)
Hello Jenkins,

I'd like you to reexamine a change.  Please visit

https://asterix-gerrit.ics.uci.edu/1401

to look at the new patch set (#5).

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..

ASTERIXDB-1755: add UPSERT in SQL++.

Detailed list of changes include:
- Fix AQL RETURNING clause to use an expression instead of a query;
- Add a rule to check whether a RETURNING expression contains dataset accesses;
- Perform AST-level rewrites for INSERT/UPSERT as a whole, including the
  body query and the returning expression.

Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
---
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/base/RuleCollections.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/CheckInsertUpsertRule.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/InsertUpsertCheckUtil.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/CompiledStatements.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/api/common/APIFramework.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
M 
asterixdb/asterix-app/src/test/java/org/apache/asterix/test/sqlpp/ParserTestExecutor.java
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.3.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.4.sleep.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.5.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.6.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.7.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.8.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-delete/enforced-type-delete.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/tes

Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 4:

Build Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-notopic/3684/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 4
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Yingyi Bu (Code Review)
Hello Jenkins,

I'd like you to reexamine a change.  Please visit

https://asterix-gerrit.ics.uci.edu/1401

to look at the new patch set (#4).

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..

ASTERIXDB-1755: add UPSERT in SQL++.

Detailed list of changes include:
- Fix AQL RETURNING clause to use an expression instead of a query;
- Add a rule to check whether a RETURNING expression contains dataset accesses;
- Perform AST-level rewrites for INSERT/UPSERT as a whole, including the
  body query and the returning expression.

Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
---
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/base/RuleCollections.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/CheckInsertUpsertRule.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/InsertUpsertCheckUtil.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/CompiledStatements.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/api/common/APIFramework.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
M 
asterixdb/asterix-app/src/test/java/org/apache/asterix/test/sqlpp/ParserTestExecutor.java
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname-implicit/insert-returning-fieldname-implicit.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.3.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.4.sleep.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.5.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.6.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.7.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.8.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-delete/enforced-type-delete.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/tes

Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 3:

Build Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-notopic/3682/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 3
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-28 Thread Yingyi Bu (Code Review)
Hello Jenkins,

I'd like you to reexamine a change.  Please visit

https://asterix-gerrit.ics.uci.edu/1401

to look at the new patch set (#3).

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..

ASTERIXDB-1755: add UPSERT in SQL++.

Detailed list of changes include:
- Fix AQL RETURNING clause to use an expression instead of a query;
- Add a rule to check whether a RETURNING expression contains dataset accesses;
- Perform AST-level rewrites for INSERT/UPSERT as a whole, including the
  body query and the returning expression.

Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
---
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/base/RuleCollections.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/CheckInsertUpsertRule.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/optimizer/rules/util/InsertUpsertCheckUtil.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/CompiledStatements.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/api/common/APIFramework.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.1.ddl.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries/dml/insert-returning-udf/insert-returning-udf.3.query.aql
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-return-records/insert-return-records.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-fieldname/insert-returning-fieldname.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-returning-udf/insert-returning-udf.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/insert-with-bad-return/insert-with-bad-return.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-return-custom-result/upsert-return-custom-result.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.3.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.4.sleep.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.5.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.6.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.7.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.8.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-delete/enforced-type-delete.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-delete/enforced-type-delete.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-delete/enforced-type-delete.3.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-delete/enforced-type-delete.4.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-delete/enforced-type-delete.5.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enf

Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-27 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 2:

Build Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-notopic/3675/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 2
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-27 Thread Yingyi Bu (Code Review)
Hello Jenkins,

I'd like you to reexamine a change.  Please visit

https://asterix-gerrit.ics.uci.edu/1401

to look at the new patch set (#2).

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..

ASTERIXDB-1755: add UPSERT in SQL++.

Detailed list of changes include:
- Fix AQL RETURNING clause to use an expression instead of a query;
- Add checks for the case when a RETURNING expression contains dataset accesses.

Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
---
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/CompiledStatements.java
M 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/LangExpressionToPlanTranslator.java
A 
asterixdb/asterix-algebra/src/main/java/org/apache/asterix/translator/util/InsertUpsertCheckUtil.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/app/translator/QueryTranslator.java
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/dml/upsert-dataset-with-meta/upsert-dataset-with-meta.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.3.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.4.sleep.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.5.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.6.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.7.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.8.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-delete/enforced-type-delete.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-delete/enforced-type-delete.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-delete/enforced-type-delete.3.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-delete/enforced-type-delete.4.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-delete/enforced-type-delete.5.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-upsert/enforced-type-upsert.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-upsert/enforced-type-upsert.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-upsert/enforced-type-upsert.3.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-upsert/enforced-type-upsert.4.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/open-index-enforced/type-checking/enforced-type-upsert/enforced-type-upsert.5.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/filtered-dataset/filtered-dataset.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/filtered-dataset/filtered-dataset.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/filtered-dataset/filtered-dataset.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/issue1587-foreignDataType/issue1587-foreignDataType.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/issue1587-foreignDataType/issue1587-foreignDataType.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/issue1587-foreignDataType/issue1587-foreignDataType.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/issue1587-foreignDataType/issue1587-foreignDataType.4.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/multiple-secondaries/multiple-secondaries.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/multiple-secondaries/multiple-secondaries.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/multiple-secondaries/multiple-seco

Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-21 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 1: Integration-Tests+1

Integration Tests Successful

https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-integration-tests/1376/ 
: SUCCESS

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 1
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-21 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 1:

Integration Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-integration-tests/1376/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 1
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-21 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 1: Integration-Tests-1

Integration Tests Timed Out

https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-integration-tests/1375/ 
: ABORTED

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 1
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-21 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 1: BAD+1

BAD Compatibility Tests Successful

https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/99/ : SUCCESS

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 1
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-21 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 1:

BAD Compatibility Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterixbad-compat/99/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 1
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-21 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 1:

Integration Tests Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-integration-tests/1375/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 1
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-21 Thread Jenkins (Code Review)
Jenkins has posted comments on this change.

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..


Patch Set 1:

Build Started 
https://asterix-jenkins.ics.uci.edu/job/asterix-gerrit-notopic/3636/

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/1401
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
Gerrit-PatchSet: 1
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Yingyi Bu 
Gerrit-Reviewer: Jenkins 
Gerrit-HasComments: No


Change in asterixdb[master]: ASTERIXDB-1755: add UPSERT in SQL++.

2016-12-21 Thread Yingyi Bu (Code Review)
Yingyi Bu has uploaded a new change for review.

  https://asterix-gerrit.ics.uci.edu/1401

Change subject: ASTERIXDB-1755: add UPSERT in SQL++.
..

ASTERIXDB-1755: add UPSERT in SQL++.

Change-Id: I02b2be7ff2653573eccb48037895f5c8c4bc8c74
---
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.3.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.4.sleep.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.5.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.6.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.7.server.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/feeds/upsert-feed/upsert-feed.8.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/filtered-dataset/filtered-dataset.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/filtered-dataset/filtered-dataset.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/filtered-dataset/filtered-dataset.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/issue1587-foreignDataType/issue1587-foreignDataType.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/issue1587-foreignDataType/issue1587-foreignDataType.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/issue1587-foreignDataType/issue1587-foreignDataType.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/issue1587-foreignDataType/issue1587-foreignDataType.4.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/multiple-secondaries/multiple-secondaries.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/multiple-secondaries/multiple-secondaries.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/multiple-secondaries/multiple-secondaries.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/nested-index/nested-index.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/nested-index/nested-index.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/nested-index/nested-index.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/nullable-index/nullable-index.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/nullable-index/nullable-index.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/nullable-index/nullable-index.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/open-index/open-index.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/open-index/open-index.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/open-index/open-index.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/primary-index/primary-index.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/primary-index/primary-index.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/primary-index/primary-index.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/primary-secondary-btree/primary-secondary-btree.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/primary-secondary-btree/primary-secondary-btree.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/primary-secondary-btree/primary-secondary-btree.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/primary-secondary-inverted/primary-secondary-inverted.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/primary-secondary-inverted/primary-secondary-inverted.2.update.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/primary-secondary-inverted/primary-secondary-inverted.3.query.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/primary-secondary-rtree/primary-secondary-rtree.1.ddl.sqlpp
A 
asterixdb/asterix-app/src/test/resources/runtimets/queries_sqlpp/upsert/primary-secondary-rtree/primary-secondar