Uploaded image for project: 'Kylin'
  1. Kylin
  2. KYLIN-3500

kylin 2.4 use jdbc datasource :Unknown column 'A.A.CRT_DATE' in 'where clause'

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • v2.3.0, v2.4.0
    • v2.4.1, v2.5.0
    • RDBMS Source
    • None
    • Hadoop2.7.6+Hive-1.2.2+HBase1.2.6+Sqoop1.4.7

    Description

      Kylin2.4 使用JDBC数据源,构建时通过Sqoop从mysql抽取数据到hive报错,split-by字段出现名重复:tablename.tablename.field

      sqoop-1.4.6/bin/sqoop import -Dorg.apache.sqoop.splitter.allow_text_splitter=true -Dmapreduce.job.queuename=default --connect "jdbc:mysql://192.168.31.108:3306/kylin_jdbcresource_test" --driver com.mysql.jdbc.Driver --username root --password root1324 --query "SELECT A.NAME as A_NAME ,A.CRT_DATE FROM KYLIN_JDBCRESOURCE_TEST.A as A  WHERE 1=1 AND (A.CRT_DATE >= '2018-08-01 00:00:00' AND A.CRT_DATE < '2018-08-16 00:00:00')  AND \$CONDITIONS" --target-dir hdfs://localhost:9000/kylin/kylin_metadata/kylin-6bbe475b-ad11-4501-b3db-a56ee0222c90/kylin_intermediate_jdbc_resource_cube_7a4bd639_38ac_41be_9fba_6c64e040b175 --split-by A.A.CRT_DATE --boundary-query "SELECT min(A.CRT_DATE), max(A.CRT_DATE) FROM "KYLIN_JDBCRESOURCE_TEST".A as A WHERE A.CRT_DATE >= '2018-08-01 00:00:00' AND A.CRT_DATE < '2018-08-16 00:00:00'" --null-string '' --fields-terminated-by '|' --num-mappers 1

      Caused by: com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown column 'A.A.CRT_DATE' in 'where clause'

      Attachments

        1. TIM图片20180815175301.png
          100 kB
          cqli
        2. TIM图片20180815175342.png
          79 kB
          cqli
        3. TIM图片20180815175407.png
          26 kB
          cqli

        Issue Links

          Activity

            People

              zhanshaoxiong jimmyz
              Bryant_Lee cqli
              Votes:
              1 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: