# EHRBase DB: Where the data actually stored in the PG database

**URL:** https://discourse.openehr.org/t/ehrbase-db-where-the-data-actually-stored-in-the-pg-database/5591
**Category:** Platform
**Created:** [21 August 2024 06:54 UTC](https://discourse.openehr.org/t/ehrbase-db-where-the-data-actually-stored-in-the-pg-database/5591 "2024-08-21T06:54:47Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![linforest](https://discourse.openehr.org/letter_avatar_proxy/v4/letter/l/ac8455/32.png) [@linforest](https://discourse.openehr.org/u/linforest)
#### Post date: [21 August 2024 06:54 UTC](https://discourse.openehr.org/t/ehrbase-db-where-the-data-actually-stored-in-the-pg-database/5591/1 "2024-08-21T06:54:47Z")

</div>

For EHRBase v2.6.0, where the data actually stored in the PG database?  
I have several OPT templates and Compositions stored in the EHRBase’s PG database.

Out of curiosity, I’d like to take a look at the data, to figure out what they look like. So, I want to know what databases and database tables this data actually reside in? Also, what level of database permissions do I need to have for this?

Thanks.

---

<div class="post-metadata">

### Author: ![birger.haarbrandt](https://discourse.openehr.org/user_avatar/discourse.openehr.org/birger.haarbrandt/32/24_2.png) [@birger.haarbrandt](https://discourse.openehr.org/u/birger.haarbrandt)
#### Post date: [21 August 2024 11:36 UTC](https://discourse.openehr.org/t/ehrbase-db-where-the-data-actually-stored-in-the-pg-database/5591/2 "2024-08-21T11:36:47Z")

</div>

Go to the ehr schema. The compositions are located in the comp\_data table.

The “standard” db users of EHRbase should be sufficient to access the data.

---

<div class="post-metadata">

### Author: ![linforest](https://discourse.openehr.org/letter_avatar_proxy/v4/letter/l/ac8455/32.png) [@linforest](https://discourse.openehr.org/u/linforest)
#### Post date: [21 August 2024 13:25 UTC](https://discourse.openehr.org/t/ehrbase-db-where-the-data-actually-stored-in-the-pg-database/5591/3 "2024-08-21T13:25:56Z")

</div>

Thanks a lot, Birger. ❤
