SWATI RAO created CARBONDATA-706:
------------------------------------ Summary: Mulitiple OR operators does not work properly in carbondata Key: CARBONDATA-706 URL: https://issues.apache.org/jira/browse/CARBONDATA-706 Project: CarbonData Issue Type: Bug Components: sql Affects Versions: 1.1.0-incubating Environment: Spark 2.1 Reporter: SWATI RAO Priority: Minor Attachments: 100_hive_test.csv Multiple OR operators result does not match with hive. Steps to Reproduces: 1:Create table using following Command " create table Carbon_automation (imei string,deviceInformationId int,MAC string,deviceColor string,device_backColor string,modelId string,marketName string,AMSize string,ROMSize string,CUPAudit string,CPIClocked string,series string,productionDate timestamp,bomCode string,internalModels string, deliveryTime string, channelsId string, channelsName string , deliveryAreaId string, deliveryCountry string, deliveryProvince string, deliveryCity string,deliveryDistrict string, deliveryStreet string, oxSingleNumber string, ActiveCheckTime string, ActiveAreaId string, ActiveCountry string, ActiveProvince string, Activecity string, ActiveDistrict string, ActiveStreet string, ActiveOperatorId string, Active_releaseId string, Active_EMUIVersion string, Active_operaSysVersion string, Active_BacVerNumber string, Active_BacFlashVer string, Active_webUIVersion string, Active_webUITypeCarrVer string,Active_webTypeDataVerNumber string, Active_operatorsVersion string, Active_phonePADPartitionedVersions string, Latest_YEAR int, Latest_MONTH int, Latest_DAY int, Latest_HOUR string, Latest_areaId string, Latest_country string, Latest_province string, Latest_city string, Latest_district string, Latest_street string, Latest_releaseId string, Latest_EMUIVersion string, Latest_operaSysVersion string, Latest_BacVerNumber string, Latest_BacFlashVer string, Latest_webUIVersion string, Latest_webUITypeCarrVer string, Latest_webTypeDataVerNumber string, Latest_operatorsVersion string, Latest_phonePADPartitionedVersions string, Latest_operatorId string, gamePointDescription string,gamePointId double,contractNumber double,imei_count int) STORED BY 'org.apache.carbondata.format' TBLPROPERTIES ('DICTIONARY_INCLUDE'='deviceInformationId,Latest_YEAR,Latest_MONTH,Latest_DAY')" 2:Load Data with following command " LOAD DATA INPATH 'HDFS_URL/BabuStore/Data/HiveData' INTO TABLE Carbon_automation OPTIONS('DELIMITER'=',','QUOTECHAR'='"','BAD_RECORDS_ACTION'='FORCE','FILEHEADER'='imei,deviceInformationId,MAC,deviceColor,device_backColor,modelId,marketName,AMSize,ROMSize,CUPAudit,CPIClocked,series,productionDate,bomCode,internalModels,deliveryTime,channelsId,channelsName,deliveryAreaId,deliveryCountry,deliveryProvince,deliveryCity,deliveryDistrict,deliveryStreet,oxSingleNumber,contractNumber,ActiveCheckTime,ActiveAreaId,ActiveCountry,ActiveProvince,Activecity,ActiveDistrict,ActiveStreet,ActiveOperatorId,Active_releaseId,Active_EMUIVersion,Active_operaSysVersion,Active_BacVerNumber,Active_BacFlashVer,Active_webUIVersion,Active_webUITypeCarrVer,Active_webTypeDataVerNumber,Active_operatorsVersion,Active_phonePADPartitionedVersions,Latest_YEAR,Latest_MONTH,Latest_DAY,Latest_HOUR,Latest_areaId,Latest_country,Latest_province,Latest_city,Latest_district,Latest_street,Latest_releaseId,Latest_EMUIVersion,Latest_operaSysVersion,Latest_BacVerNumber,Latest_BacFlashVer,Latest_webUIVersion,Latest_webUITypeCarrVer,Latest_webTypeDataVerNumber,Latest_operatorsVersion,Latest_phonePADPartitionedVersions,Latest_operatorId,gamePointId,gamePointDescription,imei_count')" 3:Now run the Select Query: " select imei,gamePointId, channelsId,series from Carbon_automation where channelsId >=10 OR channelsId <=1 or series='7Series' " 4:Result Displays " 0: jdbc:hive2://localhost:10000> select imei,gamePointId, channelsId,series from Carbon_automation where channelsId >=10 OR channelsId <=1 or series='7Series'; +-------------+--------------+-------------+----------+--+ | imei | gamePointId | channelsId | series | +-------------+--------------+-------------+----------+--+ | 1AA1 | 2738.562 | 4 | 7Series | | 1AA10 | 1714.635 | 4 | 7Series | | 1AA100 | 1271.0 | 6 | 5Series | | 1AA1000 | 692.0 | 3 | 5Series | | 1AA10000 | 2175.0 | 1 | 7Series | | 1AA100000 | 136.0 | 6 | 9Series | | 1AA1000000 | 1600.0 | 6 | 7Series | | 1AA100001 | 505.0 | 7 | 0Series | | 1AA100002 | 1341.0 | 3 | 0Series | | 1AA100003 | 2239.0 | 3 | 5Series | | 1AA100004 | 2970.0 | 2 | 4Series | | 1AA100005 | 2593.0 | 1 | 1Series | | 1AA100006 | 2572.0 | 2 | 6Series | | 1AA100007 | 1991.0 | 3 | 9Series | | 1AA100008 | 1442.0 | 1 | 8Series | | 1AA100009 | 1841.0 | 3 | 0Series | | 1AA10001 | 298.0 | 5 | 2Series | | 1AA100010 | 79.0 | 6 | 3Series | | 1AA100011 | 202.0 | 1 | 0Series | | 1AA100012 | 568.0 | 2 | 4Series | | 1AA100013 | 355.0 | 6 | 1Series | | 1AA100014 | 151.0 | 3 | 5Series | | 1AA100015 | 2863.0 | 1 | 4Series | | 1AA100016 | 1873.0 | 3 | 3Series | | 1AA100017 | 2205.0 | 3 | 9Series | | 1AA100018 | 441.0 | 4 | 8Series | | 1AA100019 | 2194.0 | 3 | 5Series | | 1AA10002 | 2972.0 | 5 | 0Series | | 1AA100020 | 256.0 | 7 | 5Series | | 1AA100021 | 1778.0 | 6 | 0Series | | 1AA100022 | 1999.0 | 5 | 5Series | | 1AA100023 | 2194.0 | 3 | 5Series | | 1AA100024 | 2483.0 | 2 | 6Series | | 1AA100025 | 1724.0 | 1 | 0Series | | 1AA100026 | 1768.0 | 7 | 7Series | | 1AA100027 | 2436.0 | 4 | 0Series | | 1AA100028 | 2849.0 | 5 | 5Series | | 1AA100029 | 1691.0 | 5 | 2Series | | 1AA10003 | 2071.0 | 4 | 7Series | | 1AA100030 | 1333.0 | 3 | 7Series | | 1AA100031 | 1080.0 | 1 | 7Series | | 1AA100032 | 1053.0 | 7 | 1Series | | 1AA100033 | 760.0 | 6 | 8Series | | 1AA100034 | 2061.0 | 6 | 2Series | | 1AA100035 | 2142.0 | 7 | 5Series | | 1AA100036 | 2224.0 | 5 | 5Series | | 1AA100037 | 1015.0 | 6 | 7Series | | 1AA100038 | 1229.0 | 3 | 6Series | | 1AA100039 | 1750.0 | 1 | 8Series | | 1AA10004 | 1717.0 | 4 | 5Series | | 1AA100040 | 2078.0 | 7 | 8Series | | 1AA100041 | 2734.0 | 1 | 5Series | | 1AA100042 | 2745.0 | 5 | 3Series | | 1AA100043 | 571.0 | 6 | 9Series | | 1AA100044 | 1697.0 | 2 | 8Series | | 1AA100045 | 2553.0 | 6 | 2Series | | 1AA100046 | 1077.0 | 4 | 3Series | | 1AA100047 | 1823.0 | 1 | 9Series | | 1AA100048 | 2399.0 | 1 | 3Series | | 1AA100049 | 2890.0 | 6 | 0Series | | 1AA10005 | 1608.0 | 2 | 8Series | | 1AA100050 | 29.0 | 1 | 2Series | | 1AA100051 | 1407.0 | 7 | 2Series | | 1AA100052 | 845.0 | 7 | 6Series | | 1AA100053 | 1655.0 | 3 | 2Series | | 1AA100054 | 1368.0 | 2 | 7Series | | 1AA100055 | 1728.0 | 7 | 7Series | | 1AA100056 | 750.0 | 5 | 6Series | | 1AA100057 | 2288.0 | 6 | 9Series | | 1AA100058 | 2635.0 | 4 | 5Series | | 1AA100059 | 1337.0 | 7 | 4Series | | 1AA10006 | 2478.0 | 5 | 3Series | | 1AA100060 | 538.0 | 4 | 8Series | | 1AA100061 | 1407.0 | 6 | 6Series | | 1AA100062 | 2952.0 | 6 | 9Series | | 1AA100063 | 1226.0 | 3 | 2Series | | 1AA100064 | 865.0 | 7 | 6Series | | 1AA100065 | 901.0 | 7 | 0Series | | 1AA100066 | 1864.0 | 4 | 6Series | | 1AA100067 | 572.0 | 7 | 4Series | | 1AA100068 | 412.0 | 7 | 8Series | | 1AA100069 | 1491.0 | 5 | 8Series | | 1AA10007 | 1350.0 | 3 | 8Series | | 1AA100070 | 1567.0 | 3 | 0Series | | 1AA100071 | 1973.0 | 5 | 0Series | | 1AA100072 | 448.0 | 7 | 4Series | | 1AA100073 | 2488.0 | 2 | 4Series | | 1AA100074 | 907.0 | 7 | 6Series | | 1AA100075 | 2507.0 | 6 | 3Series | | 1AA100076 | 732.0 | 7 | 0Series | | 1AA100077 | 2077.0 | 6 | 3Series | | 1AA100078 | 1434.0 | 5 | 2Series | | 1AA100079 | 1098.0 | 6 | 4Series | | 1AA10008 | 813.0 | 4 | 5Series | | 1AA100080 | 954.0 | 6 | 9Series | | 1AA100081 | 613.0 | 2 | 5Series | | 1AA100082 | 2348.0 | 7 | 5Series | | 1AA100083 | 2192.0 | 2 | 0Series | | 1AA100084 | 2826.0 | 4 | 0Series | +-------------+--------------+-------------+----------+--+ 99 rows selected (0.221 seconds) " 5:Csv attached "100_hive_test.csv" -- This message was sent by Atlassian JIRA (v6.3.15#6346) |
Free forum by Nabble | Edit this page |