diff --git a/BUILD/mdbci/copy_repos.sh b/BUILD/mdbci/copy_repos.sh index 517ef82dd..fd9503c92 100755 --- a/BUILD/mdbci/copy_repos.sh +++ b/BUILD/mdbci/copy_repos.sh @@ -70,4 +70,7 @@ $(<${script_dir}/templates/repository-config/deb.json.template) fi cd $dir +echo "cleaning ${unsorted_repo_dir}/$target/$box" +rm -rf ${unsorted_repo_dir}/$target/$box + ${mdbci_dir}/mdbci generate-product-repositories --product maxscale_ci --product-version $target diff --git a/BUILD/mdbci/create_remote_repo.sh b/BUILD/mdbci/create_remote_repo.sh index 335197d13..16f1e7b3b 100755 --- a/BUILD/mdbci/create_remote_repo.sh +++ b/BUILD/mdbci/create_remote_repo.sh @@ -34,8 +34,10 @@ if [ $? != 0 ] ; then exit 1 fi -echo "cleaning ${unsorted_repo_dir}/$target/$box/" -rm -rf ${unsorted_repo_dir}/$target/$box/* +echo "cleaning ${unsorted_repo_dir}/$target/$box" +rm -rf ${unsorted_repo_dir}/$target/$box +echo "cleaning ${pre_repo_dir}/$target/$box" +rm -rf ${pre_repo_dir}/$target/$box echo "copying repo from $box" mkdir -p ${unsorted_repo_dir}/$target/$box diff --git a/query_classifier/qc_sqlite/sqlite-src-3110100/src/parse.y b/query_classifier/qc_sqlite/sqlite-src-3110100/src/parse.y index c1e1cd542..801c8b1ed 100644 --- a/query_classifier/qc_sqlite/sqlite-src-3110100/src/parse.y +++ b/query_classifier/qc_sqlite/sqlite-src-3110100/src/parse.y @@ -1874,9 +1874,14 @@ idlist(A) ::= nm(Y). } expr(A) ::= term(X). {A = X;} +%ifndef MAXSCALE expr(A) ::= LP(B) expr(X) RP(E). {A.pExpr = X.pExpr; spanSet(&A,&B,&E);} +%endif %ifdef MAXSCALE -expr(A) ::= LP expr(X) COMMA(OP) expr(Y) RP. {spanBinaryExpr(&A,pParse,@OP,&X,&Y);} +%type exprs {ExprSpan} +exprs(A) ::= expr(X). { A = X; } +exprs(A) ::= exprs(X) COMMA(OP) expr(Y). {spanBinaryExpr(&A,pParse,@OP,&X,&Y);} +expr(A) ::= LP(B) exprs(X) RP(E). {A.pExpr = X.pExpr; spanSet(&A,&B,&E);} term(A) ::= DEFAULT(X). {spanExpr(&A, pParse, @X, &X);} %endif term(A) ::= NULL(X). {spanExpr(&A, pParse, @X, &X);} @@ -1922,6 +1927,13 @@ expr(A) ::= VARIABLE(X). { spanSet(&A, &X, &X); } %ifdef MAXSCALE +expr(A) ::= id(X) INTEGER(Y). { + // The sole purpose of this is to interpret something like '_utf8mb4 0xD091D092D093' + // as a string. It does not matter that any identifier followed by an integer will + // be interpreted as a string, as invalid usage will be caught by the server. + A.pExpr = sqlite3PExpr(pParse, TK_STRING, 0, 0, &Y); + spanSet(&A, &X, &Y); +} expr(A) ::= VARIABLE(X) variable_tail(Y). { // As we won't be executing any queries, we do not need to do // the things that are done above. diff --git a/query_classifier/test/maxscale.test b/query_classifier/test/maxscale.test index 83b8fb37e..36606fb46 100644 --- a/query_classifier/test/maxscale.test +++ b/query_classifier/test/maxscale.test @@ -133,6 +133,10 @@ XA RECOVER 'xid'; # MXS-2688 SET @saved_cs_client= @@character_set_client; +# MXS-2699 +SELECT NEXTVAL(id_generator), context FROM t1 WHERE (a,b,c) >= (1,2,3); +select soundex(_utf8mb4 0xD091D092D093) as vx, gray_user_tag from user_extends where user_id > last_insert_id(); + # MXS-2432 RESET QUERY CACHE; RESET MASTER;