# \_dateparsefailure while using JDBC plugin

**URL:** https://discuss.elastic.co/t/dateparsefailure-while-using-jdbc-plugin/374595
**Category:** Logstash
**Created:** [February 16, 2025, 11:15am UTC](https://discuss.elastic.co/t/dateparsefailure-while-using-jdbc-plugin/374595 "2025-02-16T11:15:31Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![jack\_a](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jack_a/32/133082_2.png) [@jack\_a](https://discuss.elastic.co/u/jack_a)
#### Post date: [February 16, 2025, 11:15am UTC](https://discuss.elastic.co/t/dateparsefailure-while-using-jdbc-plugin/374595/1 "2025-02-16T11:15:31Z")

</div>

I am trying to read some data from a database, but when i try to parse a date field i get` _dateparsefailure` while the field i am trying to convert is in `ISO8601` format.

Here is my full logstash config:

```auto
input {
  jdbc {
    jdbc_driver_library => "---"
    jdbc_driver_class => "---"
    jdbc_connection_string => "---"
    jdbc_user => "---"
    jdbc_password => "---"
    schedule => "* * * * *"
    statement => "select calldate from ---"
    
  }
}

filter {
  
  date {
    match => ["calldate", "ISO8601"]
    target => "db_time"

  }

}
output {
  stdout {}
}

```

it connects to the database but when it tries to pars the `calldate` field it throw and error. Here is a sample output:

```auto
{
      "calldate" => 2025-02-15T13:07:31.000Z,
      "@version" => "1",
          "tags" => [
        [0] "_dateparsefailure"
    ],
    "@timestamp" => 2025-02-16T11:05:00.341017552Z
}

```

I checked, for example when i run the timestamp : `2025-02-15T13:07:31.000Z` with the following config it works fine:

```auto
input {
  stdin { }
}
 
 
filter {
  date {
    match => ["message", "ISO8601"]
    target => "db_time"
  }
}
 
 
output {
  stdout{}
}

```

am i doing some obvious mistake?

---

<div class="post-metadata">

### Author: ![jack\_a](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jack_a/32/133082_2.png) [@jack\_a](https://discuss.elastic.co/u/jack_a)
#### Post date: [February 16, 2025, 12:01pm UTC](https://discuss.elastic.co/t/dateparsefailure-while-using-jdbc-plugin/374595/2 "2025-02-16T12:01:46Z")

</div>

Sorry to ask a redundant question but i belive this is a duplicate question.

> [@\_dateparsefailure in ISO8601 date strings](https://discuss.elastic.co/t/dateparsefailure-in-iso8601-date-strings/292799):
>
> I want to pull logs from an mssql server and parse their date strings. unfortunately I can not figure out why it can not parse the date. My filter looks like this: filter { date { match =\> ["evtime", "ISO8601"] timezone =\> "UTC" target =\> "@timestamp" add\_field =\> { "debug" =\> "timestampMatched"} } fingerprint { source =\> ["@timestamp", "evhost", "evinfo"] method =\> "SHA1" target =\> "[@metadata][generated\_id]" } } It does not work if there is a timezone option or not. The entrys …

---

<div class="post-metadata">

### Author: ![Rios](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rios/32/95745_2.png) [@Rios](https://discuss.elastic.co/u/Rios)
#### Post date: [February 16, 2025, 1:04pm UTC](https://discuss.elastic.co/t/dateparsefailure-while-using-jdbc-plugin/374595/3 "2025-02-16T13:04:43Z")

</div>

Can you provide the `message` or `calldate` how show up in the filter, without any transformation?

`"calldate" => 2025-02-15T13:07:31.000Z` - without quotes, this is already in the timestamp format

`"calldate" => "2025-02-15T13:07:31.000Z"` - with quotes, this would be the string format for the date conversion.

---

<div class="post-metadata">

### Author: ![leandrojmp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leandrojmp/32/107231_2.png) [@leandrojmp](https://discuss.elastic.co/u/leandrojmp)
#### Post date: [February 16, 2025, 1:33pm UTC](https://discuss.elastic.co/t/dateparsefailure-while-using-jdbc-plugin/374595/4 "2025-02-16T13:33:34Z")

</div>

As mentioned in this duplicates post, the jdb input already converts date columns into timestamp values in Logstash.

So there is no need in using a `date` filter into those values and doing so results in this error as logstash is trying to conver a field into its internal date type, but the field is already converted.
