You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2022/10/10 06:41:20 UTC

[GitHub] [shardingsphere] wayinit opened a new issue, #16652: union all not correct in multi table associated queries, but correct in onetable queries.

wayinit opened a new issue, #16652:
URL: https://github.com/apache/shardingsphere/issues/16652

   ### Which version of ShardingSphere did you use?
   5.1.0
   ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   shardingsphere-proxy
   ### Expected behavior
   get the result
   ### Actual behavior
   no result, empty
   ### Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.
   like the SQL, when I use multi table associated queries, the result is empty, but the tables has data.
   SELECT tu.use_id,
          tu.tb_mobile,
          ta.class_no
   FROM tb_user tu,
        tb_apply ta
   where tu.use_id = ta.use_id
     and tu.tb_cert_s = 'Y'
     and ta.tb_status = 2
   union all
   SELECT tu.use_id,
          tu.tb_mobile,
          ta.class_no
   FROM tb_a_user tu,
        tb_apply ta
   where tu.mem_no = ta.use_id
     and tu.cert_s = 'Y'
     and ta.tb_status = 2
   but only union all the tb_user and tb_a_user, I can get the result. 
   for this sutuation, there is just tb_a_user has data.
   


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

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org.apache.org

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


[GitHub] [shardingsphere] github-actions[bot] commented on issue #16652: union all not correct in multi table associated queries, but correct in onetable queries.

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on issue #16652:
URL: https://github.com/apache/shardingsphere/issues/16652#issuecomment-1272350082

   Hello , this issue has not received a reply for several days.
   This issue is supposed to be closed.


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

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

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


[GitHub] [shardingsphere] wayinit commented on issue #16652: union all not correct in multi table associated queries, but correct in onetable queries.

Posted by GitBox <gi...@apache.org>.
wayinit commented on issue #16652:
URL: https://github.com/apache/shardingsphere/issues/16652#issuecomment-1092638531

   <img width="614" alt="origin_img_v2_f325fe05-13e6-4d0c-a31a-3d9a14d9e3bg" src="https://user-images.githubusercontent.com/16432884/162402122-d208ed77-321e-4504-bf74-cc2867116be1.png">
   I have open this, but also empty.
   And I have found new issuer, 
   when I queries the two tables tb_a_user  tb_apply by each query,
   select * from tb_a_user;
   select * from tb_apply;
   I can got the result of both, 
   but for this sql:
   SELECT tu.use_id,
   tu.tb_mobile,
   ta.class_no
   FROM tb_a_user tu,
   tb_apply ta
   where tu.mem_no = ta.use_id
   and tu.cert_s = 'Y'
   and ta.tb_status = 2
   inner join in two tables association,
   I got empty.
   All tables' rules I made are same of that in two databases db0 and db1, and the data is only in db0 for tb_a_user and tb_apply.


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

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

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


Re: [I] union all not correct in multi table associated queries, but correct in onetable queries. [shardingsphere]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #16652:
URL: https://github.com/apache/shardingsphere/issues/16652#issuecomment-2026020855

   There hasn't been any activity on this issue recently, and in order to prioritize active issues, it will be marked as stale.


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

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

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


[GitHub] [shardingsphere] wayinit commented on issue #16652: union all not correct in multi table associated queries, but correct in onetable queries.

Posted by GitBox <gi...@apache.org>.
wayinit commented on issue #16652:
URL: https://github.com/apache/shardingsphere/issues/16652#issuecomment-1092639227

   @strongduanmu 
   <img width="614" alt="origin_img_v2_f325fe05-13e6-4d0c-a31a-3d9a14d9e3bg" src="https://user-images.githubusercontent.com/16432884/162405839-a59c9efc-f662-4415-83e0-ffd0cc962816.png">
   


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

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

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


[GitHub] [shardingsphere] wayinit commented on issue #16652: union all not correct in multi table associated queries, but correct in onetable queries.

Posted by GitBox <gi...@apache.org>.
wayinit commented on issue #16652:
URL: https://github.com/apache/shardingsphere/issues/16652#issuecomment-1092638961

   <img width="614" alt="origin_img_v2_f325fe05-13e6-4d0c-a31a-3d9a14d9e3bg" src="https://user-images.githubusercontent.com/16432884/162405792-6647aeec-477f-49be-9f99-8e2a4bfa3200.png">
   


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

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

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


[GitHub] [shardingsphere] strongduanmu commented on issue #16652: union all not correct in multi table associated queries, but correct in onetable queries.

Posted by GitBox <gi...@apache.org>.
strongduanmu commented on issue #16652:
URL: https://github.com/apache/shardingsphere/issues/16652#issuecomment-1092546418

   Hi @wayinit, Did you turn on the `sql-federation` config? `union all` statement is currently only supported through the experimental sql-federation feature.


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

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

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


[GitHub] [shardingsphere] github-actions[bot] closed issue #16652: union all not correct in multi table associated queries, but correct in onetable queries.

Posted by GitBox <gi...@apache.org>.
github-actions[bot] closed issue #16652: union all not correct in multi table associated queries, but correct in onetable queries.
URL: https://github.com/apache/shardingsphere/issues/16652


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

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

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