# How are UDTs represented internally inside a tag provider/db?

**URL:** <https://forum.inductiveautomation.com/t/how-are-udts-represented-internally-inside-a-tag-provider-db/102958>\
**Category:** Ignition\
**Tags:** ignition81\
**Created:** [February 27, 2025, 3:37am UTC](https://forum.inductiveautomation.com/t/how-are-udts-represented-internally-inside-a-tag-provider-db/102958 "2025-02-27T03:37:12Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Leor\_Fishman](https://avatars.discourse-cdn.com/v4/letter/l/e19adc/32.png) [@Leor\_Fishman](https://forum.inductiveautomation.com/u/Leor_Fishman)\
**Post date:** [February 27, 2025, 3:37am UTC](https://forum.inductiveautomation.com/t/how-are-udts-represented-internally-inside-a-tag-provider-db/102958/1 "2025-02-27T03:37:12Z")

</div>

I'm about to start working with some UDTs, and I want to get a grounding in how they're represented inside the database.

---

<div class="post-metadata">

**Author:** ![michael.flagler](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/michael.flagler/32/26272_2.png) [@michael.flagler](https://forum.inductiveautomation.com/u/michael.flagler)\
**Post date:** [February 27, 2025, 4:38am UTC](https://forum.inductiveautomation.com/t/how-are-udts-represented-internally-inside-a-tag-provider-db/102958/2 "2025-02-27T04:38:03Z")

</div>

If you're talking about the DB on disk in the background, you don't need to know how they're stored to use/make UDTs.

If you haven't gone through Inductive University, I suggest going through ALL the videos there. If you want to learn about UDTs, here's the relevant videos:

> **[Understanding UDTs Video at Inductive University](https://inductiveuniversity.com/videos/understanding-udts/8.1)**
>
> Learn about User-Defined Types, an easy way to organize Tags in Ignition.

---

<div class="post-metadata">

**Author:** ![Leor\_Fishman](https://avatars.discourse-cdn.com/v4/letter/l/e19adc/32.png) [@Leor\_Fishman](https://forum.inductiveautomation.com/u/Leor_Fishman)\
**Post date:** [February 27, 2025, 5:19am UTC](https://forum.inductiveautomation.com/t/how-are-udts-represented-internally-inside-a-tag-provider-db/102958/3 "2025-02-27T05:19:47Z")

</div>

I'm looking to get a sense of how they're stored in the background DB, since I will be running queries from external services into that DB and want to know how to understand those queries.

---

<div class="post-metadata">

**Author:** ![michael.flagler](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/michael.flagler/32/26272_2.png) [@michael.flagler](https://forum.inductiveautomation.com/u/michael.flagler)\
**Post date:** [February 27, 2025, 5:29am UTC](https://forum.inductiveautomation.com/t/how-are-udts-represented-internally-inside-a-tag-provider-db/102958/4 "2025-02-27T05:29:04Z")

</div>

That DB is a SQLite DB and is going away in v8.3 if I understand correctly, so I wouldn't rely on it. That DB also doesn't store live values from OPC, etc so if you're wanting live data, you're better looking into the WebDev module to write an API, or using transaction manager to store live values in a database with the format of your choice.

You might also explain EXACTLY what you're trying to do so anyone reading this can help you find the proper solution for your end goal.

---

<div class="post-metadata">

**Author:** ![Leor\_Fishman](https://avatars.discourse-cdn.com/v4/letter/l/e19adc/32.png) [@Leor\_Fishman](https://forum.inductiveautomation.com/u/Leor_Fishman)\
**Post date:** [February 27, 2025, 5:40am UTC](https://forum.inductiveautomation.com/t/how-are-udts-represented-internally-inside-a-tag-provider-db/102958/5 "2025-02-27T05:40:43Z")

</div>

Oh, I mean "If i'm using a postgres tag provider or similar, what tables are those UDTs going to be written to in that tag provider, etc"

---

<div class="post-metadata">

**Author:** ![Leor\_Fishman](https://avatars.discourse-cdn.com/v4/letter/l/e19adc/32.png) [@Leor\_Fishman](https://forum.inductiveautomation.com/u/Leor_Fishman)\
**Post date:** [February 27, 2025, 5:43am UTC](https://forum.inductiveautomation.com/t/how-are-udts-represented-internally-inside-a-tag-provider-db/102958/6 "2025-02-27T05:43:51Z")

</div>

Actually, I've realized I misunderstood -- those tag providers are just for historizing data, not for the actual tag schemata (which are just stored in the internal config db/in the jsonified format in 8.3)

---

<div class="post-metadata">

**Author:** ![Chris\_Bingham](https://avatars.discourse-cdn.com/v4/letter/c/e5b9ba/32.png) [@Chris\_Bingham](https://forum.inductiveautomation.com/u/Chris_Bingham)\
**Post date:** [February 27, 2025, 1:41pm UTC](https://forum.inductiveautomation.com/t/how-are-udts-represented-internally-inside-a-tag-provider-db/102958/7 "2025-02-27T13:41:03Z")

</div>

To better understand the Historian table schema:

> **[Ignition Database Table Reference | Ignition User Manual](https://www.docs.inductiveautomation.com/docs/8.1/appendix/reference-pages/ignition-database-table-reference)**
>
> Ignition has a lot of systems built-in that will query the database automatically without requiring you to build a query. These systems automatically create the necessary tables in the database, insert the relevant data, and even query it back out...

Though, there are some built in functions that make querying of tag history a breeze. My most-used:

- [system.tag.queryTagHistory](https://www.docs.inductiveautomation.com/docs/8.1/appendix/scripting-functions/system-tag/system-tag-queryTagHistory)

If you need **external** access to query or interrogate tags, I second the recommendation to build an API (via WebDev module).

Otherwise, system functions are accessible from within Ignition, where you can write your own script to interrogate (& export) data.

Some useful functions:

- [system.tag.exportTags](https://www.docs.inductiveautomation.com/docs/8.1/appendix/scripting-functions/system-tag/system-tag-exportTags)
- [system.tag.getConfiguration](https://www.docs.inductiveautomation.com/docs/8.1/appendix/scripting-functions/system-tag/system-tag-getConfiguration)
- [system.tag.query](https://www.docs.inductiveautomation.com/docs/8.1/appendix/scripting-functions/system-tag/system-tag-query)

There is also a [Tag Report Tool](https://www.docs.inductiveautomation.com/docs/8.1/platform/tags/tag-report-tool) which adds a GUI for quick generation of a tag query intended for use in scripting.

---

<div class="post-metadata">

**Author:** ![nminchin](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/nminchin/32/6911_2.png) [@nminchin](https://forum.inductiveautomation.com/u/nminchin)\
**Post date:** [February 27, 2025, 1:51pm UTC](https://forum.inductiveautomation.com/t/how-are-udts-represented-internally-inside-a-tag-provider-db/102958/8 "2025-02-27T13:51:50Z")

</div>

You probably shouldn't be querying the config.idb while ignition is running, but if you did, the tags are linked together using uuids and parent uuids. You'll have fun piecing everything together 🙂 (I don't have it open so can't go into specifics...)

3rd vote for writing functions in webdev to retrieve tag json via an api call though. Or depending what you want to do with it, you could also have ignition update a sql table with a list of every tag in the system of that will suffice. Or even chuck the whole tag json into a table field... Or into a file that your other app can read

---

<div class="post-metadata">

**Author:** ![michael.flagler](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/michael.flagler/32/26272_2.png) [@michael.flagler](https://forum.inductiveautomation.com/u/michael.flagler)\
**Post date:** [February 27, 2025, 2:27pm UTC](https://forum.inductiveautomation.com/t/how-are-udts-represented-internally-inside-a-tag-provider-db/102958/9 "2025-02-27T14:27:36Z")

</div>

Yeah, most of us don't call those tag providers. Those are history providers for tags. Tag providers are for live data.
