# How to filter "select" queries from a log file that contains over 30000 lines with logstash

**URL:** https://discuss.elastic.co/t/how-to-filter-select-queries-from-a-log-file-that-contains-over-30000-lines-with-logstash/173708
**Category:** Logstash
**Created:** [March 25, 2019, 9:40am UTC](https://discuss.elastic.co/t/how-to-filter-select-queries-from-a-log-file-that-contains-over-30000-lines-with-logstash/173708 "2019-03-25T09:40:48Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![angham](https://avatars.discourse-cdn.com/v4/letter/a/f6c823/32.png) [@angham](https://discuss.elastic.co/u/angham)
#### Post date: [March 25, 2019, 9:40am UTC](https://discuss.elastic.co/t/how-to-filter-select-queries-from-a-log-file-that-contains-over-30000-lines-with-logstash/173708/1 "2019-03-25T09:40:48Z")

</div>

how to filter "select" queries from a log file that contains over 30000 lines with logstash  
exp:  
name: securityStore  
persistence provider classname: org.hibernate.ejb.HibernatePersistence  
15:49:05,479 DEBUG [org.hibernate.stat.internal.ConcurrentStatisticsImpl] (default task-43) HHH000117: HQL: select T from translator\_MenuTranslator T where (T.codeMessage = ?1 and (T.language = ?2 and (T.label = ?3 and T.label = ?4))), time: 2ms, rows: 0

grok {  
match =\> ["message", "%{TIME:timestamp}\s%{LOGLEVEL:level} [%{JAVACLASS:class}]\s(%{GREEDYDATA:thread}) HHH000117: HQL: select T from %{GREEDYDATA:tableName}T where (T.codeMessage = ?%{NOTSPACE}1 and (T.language = ?%{NOTSPACE}2 and (T.label = ?%{NOTSPACE}3 and T.label = ?%{NOTSPACE}4))), time:\s%{GREEDYDATA:time},\s%{GREEDYDATA:rows}" ]

}

---

<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: [April 22, 2019, 9:41am UTC](https://discuss.elastic.co/t/how-to-filter-select-queries-from-a-log-file-that-contains-over-30000-lines-with-logstash/173708/2 "2019-04-22T09:41:03Z")

</div>

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