Uploaded image for project: 'Debezium'
  1. Debezium
  2. DBZ-2644

Sql server connector - Error converting string value etutcdate( into data type datetime2 using culture '')

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Major
    • None
    • 1.3.0.Final
    • sqlserver-connector
    • None
    • False
    • False
    • Undefined
    • Hide
      1. Start sql server
      2. Start kafka and debeiuzm
      3. Pull the snapshot for whitelist tables and we receive data to kafka topics
      4. Stop sql for 1 minute (and we receive connection error correctly)
      5. Restart sql server
      6. Insert into sql server for a table that was in the snapshot
      7. Insert into sql server for a table that wasn't in the snapshot and doesn't have a kafka topic
      8. Nothing is entering into kafka topic because the connector died in point number 4
      9. Restart sql server connector
      10. The table that was in the snapshot now have the new data from point number 6
      11. The table thas wasn't in the snapshot (insert from point number 7) still doesn't have data neither kafka topic (we also tried to create the topic manually before inserting data to sql server but it's the same)
      12. In the connector log we have the error:
        com.microsoft.sqlserver.jdbc.SQLServerException: Error converting string value 'etutcdate(' into data type datetime2 using culture ''.
      13. We do another insert for the same table from point number 7 (not in snapshot) and this time it create the kafka topic and we have only data from the second insert. The one from point number 7 is still lost.
        14) Tried another restart of kafka connector but nothing happened. The first insert from point number 7 is lost forever.
      Show
      Start sql server Start kafka and debeiuzm Pull the snapshot for whitelist tables and we receive data to kafka topics Stop sql for 1 minute (and we receive connection error correctly) Restart sql server Insert into sql server for a table that was in the snapshot Insert into sql server for a table that wasn't in the snapshot and doesn't have a kafka topic Nothing is entering into kafka topic because the connector died in point number 4 Restart sql server connector The table that was in the snapshot now have the new data from point number 6 The table thas wasn't in the snapshot (insert from point number 7) still doesn't have data neither kafka topic (we also tried to create the topic manually before inserting data to sql server but it's the same) In the connector log we have the error: com.microsoft.sqlserver.jdbc.SQLServerException: Error converting string value 'etutcdate(' into data type datetime2 using culture ''. We do another insert for the same table from point number 7 (not in snapshot) and this time it create the kafka topic and we have only data from the second insert. The one from point number 7 is still lost. 14) Tried another restart of kafka connector but nothing happened. The first insert from point number 7 is lost forever.

    Description

      I have a problem with debezium and sql server connector that give us the following error when connector restart after the connection to sql server is lost:

      com.microsoft.sqlserver.jdbc.SQLServerException: Error converting string value 'etutcdate(' into data type datetime2 using culture ''.

      And this is the full error stack:

      2020-10-06 14:55:08,681 INFO || [Consumer clientId=abc-dbhistory, groupId=abc-dbhistory] Join group failed with org.apache.kafka.common.errors.MemberIdRequiredException: The group member needs to have a valid member id before actually entering a consumer group. [org.apache.kafka.clients.consumer.internals.AbstractCoordinator]
      com.microsoft.sqlserver.jdbc.SQLServerException: Error converting string value 'etutcdate(' into data type datetime2 using culture ''.
      at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:262)
      at com.microsoft.sqlserver.jdbc.SQLServerResultSet$FetchBuffer.nextRow(SQLServerResultSet.java:5427)
      at com.microsoft.sqlserver.jdbc.SQLServerResultSet.fetchBufferNext(SQLServerResultSet.java:1758)
      at com.microsoft.sqlserver.jdbc.SQLServerResultSet.next(SQLServerResultSet.java:1016)
      com.microsoft.sqlserver.jdbc.SQLServerException: Error converting string value 'etutcdate(' into data type datetime2 using culture ''.
      at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:262)
      at com.microsoft.sqlserver.jdbc.SQLServerResultSet$FetchBuffer.nextRow(SQLServerResultSet.java:5427)
      at com.microsoft.sqlserver.jdbc.SQLServerResultSet.fetchBufferNext(SQLServerResultSet.java:1758)
      at com.microsoft.sqlserver.jdbc.SQLServerResultSet.next(SQLServerResultSet.java:1016)
      com.microsoft.sqlserver.jdbc.SQLServerException: Error converting string value 'etutcdate(' into data type datetime2 using culture ''.
      at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:262)
      at com.microsoft.sqlserver.jdbc.SQLServerResultSet$FetchBuffer.nextRow(SQLServerResultSet.java:5427)
      at com.microsoft.sqlserver.jdbc.SQLServerResultSet.fetchBufferNext(SQLServerResultSet.java:1758)
      at com.microsoft.sqlserver.jdbc.SQLServerResultSet.next(SQLServerResultSet.java:1016)
      2020-10-06 14:55:16,158 WARN || [Producer clientId=connector-producer-sysint-sqlserver-abc-runinit-connector-0] Error while fetching metadata with correlation id 3 :
      
      CREATE TABLE [dbo].[Payment](
      	[IDPayment] [int] IDENTITY(1,1) NOT FOR REPLICATION NOT NULL,
      	[Date] [datetime] NULL,
      	[IDData] [int] NULL,
      	[TrackNumber] [int] NOT NULL,
      	[Note] [varchar](50) NOT NULL,
      	[IsVerified] [bit] NOT NULL,
      	[Date2] [datetime] NULL,
      	[IDAccount] [int] NOT NULL,
      	[OrderNumber] [int] NOT NULL,
      	[OrderQuantity] [int] NULL,
      	[Import] [bit] NOT NULL,
      	[ImportDate] [datetime] NULL,
      	[Processed] [bit] NOT NULL,
      	[ProcessedAuto] [bit] NOT NULL,
      	[Transfer] [bit] NOT NULL,
      	[TransferNote] [varchar](50) NULL,
      	[VerifiedTransfer] [bit] NOT NULL,
       CONSTRAINT [PK_Payment] PRIMARY KEY CLUSTERED 
      (
      	[IDPayment] ASC
      )
      

      Attachments

        1. 1 connector ok.txt
          479 kB
        2. 2 connector ko.txt
          616 kB
        3. ed thompson ddl
          8 kB
        4. export.csv
          0.2 kB
        5. FullLog.txt
          1.15 MB

        Issue Links

          Activity

            People

              jpechane Jiri Pechanec
              fballerinivvdo Fabio Ballerini (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: