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

Error when define default value avro in decimal columns

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Critical Critical
    • 1.7.1.Final
    • 1.6.0.Final, 1.7.0.Final
    • postgresql-connector
    • None
    • False
    • False

      when decimal.handling.mode is defined to string an error is throwed.

      org.apache.kafka.connect.errors.DataException: Invalid Java object for schema type STRING: class java.math.BigDecimal for field: "null"
      

      This error is throwed when PostgreSQL database has decimal columns with default  values.

       

      CREATE TABLE public.dados_contexto_lote_recurso (
          id text NOT NULL,
          qtd_guias_glosadas bigint NOT NULL,
          todo_contexto_trabalhado boolean NOT NULL,
          contexto_lote_recurso text NOT NULL,
          total_glosa_guias numeric DEFAULT 0
      );

       

      In debezium 1.5.X- works.

        1. sink.log
          4 kB
          Henrique Luiz da Silva Mota

              Unassigned Unassigned
              henriquelsmota Henrique Luiz da Silva Mota (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: