# Tracking column not found in dataset

**URL:** https://discuss.elastic.co/t/tracking-column-not-found-in-dataset/216377
**Category:** Logstash
**Created:** [January 24, 2020, 7:27am UTC](https://discuss.elastic.co/t/tracking-column-not-found-in-dataset/216377 "2020-01-24T07:27:53Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![legolas\_bilbao](https://avatars.discourse-cdn.com/v4/letter/l/3da27b/32.png) [@legolas\_bilbao](https://discuss.elastic.co/u/legolas_bilbao)
#### Post date: [January 24, 2020, 7:27am UTC](https://discuss.elastic.co/t/tracking-column-not-found-in-dataset/216377/1 "2020-01-24T07:27:53Z")

</div>

Good morning,

I've an issue with the tracking\_column with the mysql plug-in.

the conf.d

```
input {
  jdbc {
    jdbc_connection_string => "jdbc:mysql://localhost:3306/KPIS?useSSL=false"
    jdbc_user => "labo"
    jdbc_password => "arcsight_L4B0"
    jdbc_driver_library => "/<path connector>/mysql-connector-java-5.1.47.jar"
    jdbc_driver_class => "com.mysql.jdbc.Driver"
    schedule => "10 7 * * 1,2,3,4,5,6,7"
    statement => "Select reglasArcsight.idreglasArcsight, reglasArcsight.prioridad, reglasArcsight.fecha, reglasArcsight.nombreAgente, reglasArcsight.flexString1, reglasArcsight.flexString2, reglasArcsight.regla, reglasArcsight.nombre, reglasArcsight.generatorName, reglasArcsight.nombrePais, reglasArcsight.codigoPais, reglasArcsight.localizacion, reglasArcsight.ipAtacante, reglasArcsight.dispositivo, reglasArcsight.nombreObjetivo, reglasArcsight.usuarioObjetivo, reglasArcsight.ipDestino, reglasArcsight.nombreAtacante, reglasArcsight.nombreDispositivo, reglasArcsight.url, reglasArcsight.fabricante, reglasArcsight.nombreProducto FROM KPIS.reglasArcsight where idreglasArcsight>:sql_last_value"
    use_column_value => true
    clean_run => false
    tracking_column => idreglasArcsight
    jdbc_paging_enabled => true
    jdbc_page_size => 250000
    last_run_metadata_path => "<pathFile"
 }
}
output {
  elasticsearch {
  "hosts" => "localhost:9200"
  "index" => "reglas"
  }
stdout { codec => json_lines }
}

```

the error that shows logstash log is the following:  
tracking\_column not found in dataset. {:tracking\_column=\>"idreglasArcsight"}

any idea?

regards

---

<div class="post-metadata">

### Author: ![inhinyera16](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/inhinyera16/32/61625_2.png) [@inhinyera16](https://discuss.elastic.co/u/inhinyera16)
#### Post date: [January 24, 2020, 6:17pm UTC](https://discuss.elastic.co/t/tracking-column-not-found-in-dataset/216377/2 "2020-01-24T18:17:05Z")

</div>

Make the trackingcolumn smallcaps

---

<div class="post-metadata">

### Author: ![ropc](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ropc/32/47022_2.png) [@ropc](https://discuss.elastic.co/u/ropc)
#### Post date: [January 25, 2020, 4:14am UTC](https://discuss.elastic.co/t/tracking-column-not-found-in-dataset/216377/3 "2020-01-25T04:14:01Z")

</div>

Agreed with @inhinyera16 - it could be a casing issue (c.f [github issue](https://github.com/logstash-plugins/logstash-input-jdbc/issues/346)). You are also using `SELECT reglasArcsight.idreglasArcsight` and it is possible that the `tracking_column` needs to contain the full name of the column (i.e. `reglasArcsight.idreglasArcsight` or `reglasarcsight.idreglasarcsight` depending on the `lowercase_column_names` value).

---

<div class="post-metadata">

### Author: ![legolas\_bilbao](https://avatars.discourse-cdn.com/v4/letter/l/3da27b/32.png) [@legolas\_bilbao](https://discuss.elastic.co/u/legolas_bilbao)
#### Post date: [January 28, 2020, 7:31am UTC](https://discuss.elastic.co/t/tracking-column-not-found-in-dataset/216377/4 "2020-01-28T07:31:07Z")

</div>

hi everybody,

I've changed the different values (name, case sensitive, etc) but the problem persists

regards

---

<div class="post-metadata">

### Author: ![ropc](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ropc/32/47022_2.png) [@ropc](https://discuss.elastic.co/u/ropc)
#### Post date: [January 28, 2020, 8:18am UTC](https://discuss.elastic.co/t/tracking-column-not-found-in-dataset/216377/5 "2020-01-28T08:18:55Z")

</div>

@legolas_bilbao . This is what I would recommend:

a) Check that the SQL statement syntax is correct and that the SQL statement runs successfully against your database? This is the SQL statement that you provided:

```auto
Select reglasArcsight.idreglasArcsight, reglasArcsight.prioridad, reglasArcsight.fecha, reglasArcsight.nombreAgente, reglasArcsight.flexString1, reglasArcsight.flexString2, reglasArcsight.regla, reglasArcsight.nombre, reglasArcsight.generatorName, reglasArcsight.nombrePais, reglasArcsight.codigoPais, reglasArcsight.localizacion, reglasArcsight.ipAtacante, reglasArcsight.dispositivo, reglasArcsight.nombreObjetivo, reglasArcsight.usuarioObjetivo, reglasArcsight.ipDestino, reglasArcsight.nombreAtacante, reglasArcsight.nombreDispositivo, reglasArcsight.url, reglasArcsight.fabricante, reglasArcsight.nombreProducto FROM KPIS.reglasArcsight where idreglasArcsight>:sql_last_value

```

b) You can run logstash from the [command line](https://www.elastic.co/guide/en/logstash/current/running-logstash-command-line.html) with the `--debug` flag. For example: `bin/logstash --debug -f CONFIG_PATH`. You can attach the debug logs here, that would help us troubleshooting the issue.

Thank you.

---

<div class="post-metadata">

### Author: ![legolas\_bilbao](https://avatars.discourse-cdn.com/v4/letter/l/3da27b/32.png) [@legolas\_bilbao](https://discuss.elastic.co/u/legolas_bilbao)
#### Post date: [January 28, 2020, 8:52am UTC](https://discuss.elastic.co/t/tracking-column-not-found-in-dataset/216377/6 "2020-01-28T08:52:02Z")

</div>

thanks, with the log I've seen the problem and i feel a bit stupid.

regards

---

<div class="post-metadata">

### Author: ![ropc](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ropc/32/47022_2.png) [@ropc](https://discuss.elastic.co/u/ropc)
#### Post date: [January 28, 2020, 9:06am UTC](https://discuss.elastic.co/t/tracking-column-not-found-in-dataset/216377/7 "2020-01-28T09:06:17Z")

</div>

You're welcome @legolas_bilbao. Feel free to share your feedback/solution with us 🙂 that could help someone else facing similar scenario.

---

<div class="post-metadata">

### Author: ![legolas\_bilbao](https://avatars.discourse-cdn.com/v4/letter/l/3da27b/32.png) [@legolas\_bilbao](https://discuss.elastic.co/u/legolas_bilbao)
#### Post date: [January 28, 2020, 9:10am UTC](https://discuss.elastic.co/t/tracking-column-not-found-in-dataset/216377/8 "2020-01-28T09:10:15Z")

</div>

I see in the log that the index is recieving in lowcases then I've changed the column to lowcases and its works.

many thanks for the tips

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [February 25, 2020, 9:10am UTC](https://discuss.elastic.co/t/tracking-column-not-found-in-dataset/216377/9 "2020-02-25T09:10:26Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
