ADS : 14-rc-42
Platform : Ubuntu 12.04 64 bit
MongoDB : 2.4.4
With reference to the attached 'tde.json' dataset imported into 'tde' collection, when we try to run following query:
select stats from tde
intersect
select name.last from tde
ADS returns multiple occurrences of same values viz (null) and Cat in this particular case. (Pls refer to attached mongoSQL_intersect.png).
Could you please check if it's intended behavior?
N.B.: INTERSECT operation in postgresql and sqlserver removes redundant occurrences of the same values and returns just a single instance.
![]() |
7 KB
|
135 KB
|
35 KB
No, the reunion ( UNION | UNION ALL | INTERSECT | EXCEPT ) is handled by the JDBC driver. MongoDB has no support for it.
In current version of the JDBC driver, duplicates are removed only for the UNION. Should we keep duplicate occurrences only for UNION ALL and remove them (i.e. return distinct occurrences) for UNION , INTERSECT and EXCEPT ?
No, the reunion ( UNION | UNION ALL | INTERSECT | EXCEPT ) is handled by the JDBC driver. MongoDB has no support for it.
In current version of the JDBC driver, duplicates are removed only for the UNION. Should we keep duplicate occurrences only for UNION ALL and remove them (i.e. return distinct occurrences) for UNION , INTERSECT and EXCEPT ?
Let's update INTERSECT and EXCEPT to return distinct values in v14.
In a future release, we can add INTERSECT ALL and EXCEPT ALL that don't remove duplicate values.
Let's update INTERSECT and EXCEPT to return distinct values in v14.
In a future release, we can add INTERSECT ALL and EXCEPT ALL that don't remove duplicate values.
OK, I've updated the behaviour for INTERSECT and EXCEPT.
OK, I've updated the behaviour for INTERSECT and EXCEPT.
Verified on ADS 14.0.1. Test case forwarded to Jenny.
Verified on ADS 14.0.1. Test case forwarded to Jenny.
Issue #10361 |
Closed |
Fixed |
Resolved |
Completion |
No due date |
Fixed Build ADS 14.0.0-2 (mongo-jdbc 1.3.8) |
No time estimate |
1 issue link |
relates to #10435
Issue #10435Support for INTERSECT ALL and EXCEPT ALL operations on mongoSQL |
Emil, is this a Mongo API behavior?