Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Oracle->Doris] Chunjun Source 实时同步异常 #192

Closed
baisui1981 opened this issue Mar 17, 2023 · 2 comments
Closed

[Oracle->Doris] Chunjun Source 实时同步异常 #192

baisui1981 opened this issue Mar 17, 2023 · 2 comments
Labels
bug Something isn't working
Milestone

Comments

@baisui1981
Copy link
Member

baisui1981 commented Mar 17, 2023

使用数据库:Oracle11

Oracle Create Table DDL

CREATE TABLE "DMP"."DMP_USER_" 
   (  "ID" NUMBER NOT NULL ENABLE, 
  "NAME" VARCHAR2(100), 
  "CREATED_TM" DATE, 
   CONSTRAINT "DMP_USER_PK" PRIMARY KEY ("ID")
  USING INDEX PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS 
  STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
  PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT)
  TABLESPACE "USERS"  ENABLE, 
   SUPPLEMENTAL LOG DATA (PRIMARY KEY) COLUMNS, 
   SUPPLEMENTAL LOG DATA (ALL) COLUMNS
   ) SEGMENT CREATION IMMEDIATE 
  PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS NOLOGGING
  STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
  PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT)
  TABLESPACE "USERS";

insert SQL

 INSERT INTO DMP.DMP_USER_(ID, NAME, CREATED_TM) VALUES (SEQ_DMP_USER.nextval, 'Wyw', SYSDATE);

Source 端采用oracle chunjun,
异常:

  ava.lang.IllegalArgumentException: null
        at java.sql.Date.valueOf(Date.java:143) ~[?:1.8.0_251]
        at com.dtstack.chunjun.connector.jdbc.source.JdbcInputFormat.queryForPolling(JdbcInputFormat.java:742) ~[chunjun-connector-jdbc-base-1.12.5.jar:?]
        at com.dtstack.chunjun.connector.jdbc.source.JdbcInputFormat.reachedEnd(JdbcInputFormat.java:290) ~[chunjun-connector-jdbc-base-1.12.5.jar:?]
        at com.dtstack.chunjun.source.DtInputFormatSourceFunction.run(DtInputFormatSourceFunction.java:137) [chunjun-core-1.12.5.jar:?]
        at org.apache.flink.streaming.api.operators.StreamSource.run(StreamSource.java:110) [flink-dist_2.11-tis-1.13.1.jar:tis-1.13.1]

@张三丰

@baisui1981 baisui1981 added bug Something isn't working 3.7.1 labels Mar 17, 2023
@baisui1981
Copy link
Member Author

已经修改了,之前在 OracleDataSourceFactory中设置了 Oracle Date类型转 转Types.DATE 的转化去掉了(Oracle 的Date类型实际上是 timestamp的类型)

//                if ("DATE".equalsIgnoreCase(type.typeName)) {
                // 由于Oracle的Date类型在实际上是精确到秒的,不能简单输出成Date类型
//                    return new DataType(Types.DATE, type.typeName, type.columnSize);
//                }

baisui1981 added a commit to qlangtech/plugins that referenced this issue Mar 27, 2023
@baisui1981
Copy link
Member Author

fixed

@baisui1981 baisui1981 added this to the v3.7.1 milestone Apr 13, 2023
baisui1981 added a commit to qlangtech/plugins that referenced this issue Apr 18, 2023
…nt process on Source or Sink end for oracle Date type
baisui1981 added a commit that referenced this issue Apr 18, 2023
…n Source or Sink end for oracle Date type
baisui1981 added a commit to qlangtech/DataX that referenced this issue Apr 18, 2023
…nt process on Source or Sink end for oracle Date type
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant