# Desired output not achieved while logs parsing

**URL:** https://discuss.elastic.co/t/desired-output-not-achieved-while-logs-parsing/199357
**Category:** Logstash
**Created:** [September 13, 2019, 5:02am UTC](https://discuss.elastic.co/t/desired-output-not-achieved-while-logs-parsing/199357 "2019-09-13T05:02:30Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![gaurav.itsoft](https://avatars.discourse-cdn.com/v4/letter/g/a88e4f/32.png) [@gaurav.itsoft](https://discuss.elastic.co/u/gaurav.itsoft)
#### Post date: [September 13, 2019, 5:02am UTC](https://discuss.elastic.co/t/desired-output-not-achieved-while-logs-parsing/199357/1 "2019-09-13T05:02:30Z")

</div>

I have system log file for one of my application having pattern like below , i want to capture only the lines having sql exception like: +java.sql.SQLException: ORA-\*\*\* to be shown in kibana while rest of log lines are drop and not captured in message.

app.data.2019-08-28:08:53:49,129 INFO [string] (appsys\_11) +java.sql.SQLException: ORA-28001: the password has expired  
app.data.2019-08-28:08:53:49,129 INFO [string] (appsys\_11) Caused by: java.sql.SQLException: Exception occurred while getting connection: oracle.ucp.UniversalConnectionPoolException: Cannot get Connection from Datasource: java.sql.SQLException: ORA-28001: the password has expired  
app.data.2019-08-28:08:53:49,130 INFO [string] (appsys\_11) Caused by: oracle.ucp.UniversalConnectionPoolException: Cannot get Connection from Datasource: java.sql.SQLException: ORA-28001: the password has expired  
app.data.2019-08-28:08:53:49,130 INFO [string] (appsys\_11) Caused by: java.sql.SQLException: ORA-28001: the password has expired  
app.data.2019-08-28:08:53:49,134 INFO [string] (appCommandsys\_15) +java.sql.SQLException: Exception occurred while getting connection: oracle.ucp.UniversalConnectionPoolException: Cannot get Connection from Datasource: java.sql.SQLException: ORA-28001: the password has expired  
app.data.2019-08-28:08:53:49,134 INFO [string] (appCommandsys\_15) +oracle.ucp.UniversalConnectionPoolException: Cannot get Connection from Data

---

<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: [October 11, 2019, 5:02am UTC](https://discuss.elastic.co/t/desired-output-not-achieved-while-logs-parsing/199357/2 "2019-10-11T05:02:35Z")

</div>

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