# How to Parse SAP HANA DB Audit logs?

**URL:** <https://discuss.elastic.co/t/how-to-parse-sap-hana-db-audit-logs/178229>\
**Category:** Logstash\
**Created:** [April 24, 2019, 11:12am UTC](https://discuss.elastic.co/t/how-to-parse-sap-hana-db-audit-logs/178229 "2019-04-24T11:12:05Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Vigneshwaran\_Mohanas](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vigneshwaran_mohanas/32/44712_2.png) [@Vigneshwaran\_Mohanas](https://discuss.elastic.co/u/Vigneshwaran_Mohanas)\
**Post date:** [April 24, 2019, 11:12am UTC](https://discuss.elastic.co/t/how-to-parse-sap-hana-db-audit-logs/178229/1 "2019-04-24T11:12:05Z")

</div>

Hi Team,

I am new to ELK & GROK filtering . I am trying to parse SAP hana DB audit logs . I am facing one problem .. supposing if a log line consists of " ;;;;;;values\>" , if u notice, after 2 values I have 4 semicolons with empty values , but its not always empty , sometimes it has values . So , How can parse logs with semi-colon separated and it sometimes has values and sometimes it wont have data between 2 semi-colons, if i have value , then it parses correctly , otherwise it throws me error. kindly advise.

Sample logs :

2013-11-30 13:04:54;indexserver;myhanablade23.customer.corp;HAN;01;30103;10.29.14.177;lu306309;6776;58060;Alter User Policy;INFO;ALTER USER;SYSTEM;;;;;;ADAMS;SUCCESSFUL;;;;;;alter user ADAMS VAXXXXXXXXXXXXX;434597;

Thanks

Vigneshwaran M

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [April 24, 2019, 1:26pm UTC](https://discuss.elastic.co/t/how-to-parse-sap-hana-db-audit-logs/178229/2 "2019-04-24T13:26:28Z")

</div>

Use a [dissect](https://www.elastic.co/guide/en/logstash/current/plugins-filters-dissect.html) filter. That works when the fields are empty.

---

<div class="post-metadata">

**Author:** ![Vigneshwaran\_Mohanas](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/vigneshwaran_mohanas/32/44712_2.png) [@Vigneshwaran\_Mohanas](https://discuss.elastic.co/u/Vigneshwaran_Mohanas)\
**Post date:** [April 25, 2019, 9:07am UTC](https://discuss.elastic.co/t/how-to-parse-sap-hana-db-audit-logs/178229/3 "2019-04-25T09:07:07Z")

</div>

Thanks Much .. It works like a charm 🙂

Vigneshwaran M

---

<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:** [May 23, 2019, 9:07am UTC](https://discuss.elastic.co/t/how-to-parse-sap-hana-db-audit-logs/178229/4 "2019-05-23T09:07:12Z")

</div>

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