# Powerchart Keycolumn distinctions

**URL:** <https://forum.inductiveautomation.com/t/powerchart-keycolumn-distinctions/112795>\
**Category:** Ignition\
**Tags:** perspective, database\
**Created:** [December 12, 2025, 9:44pm UTC](https://forum.inductiveautomation.com/t/powerchart-keycolumn-distinctions/112795 "2025-12-12T21:44:18Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![mark.landman89](https://avatars.discourse-cdn.com/v4/letter/m/ed8c4c/32.png) [@mark.landman89](https://forum.inductiveautomation.com/u/mark.landman89)\
**Post date:** [December 12, 2025, 9:44pm UTC](https://forum.inductiveautomation.com/t/powerchart-keycolumn-distinctions/112795/1 "2025-12-12T21:44:18Z")

</div>

I’m looking for some guidance on how the keycolum/keyvalue pairs communicate with the DB historian table. The following two instances work:

histprov:OBD\_Log\_Files:/table:flex\_logs:/column:System\_Mode

histprov:OBD\_Log\_Files:/table:flex\_logs:/column:System\_Mode:/keycolumn:MS\_STATE:/keyvalue:4

However, for some reason the following path does not return any data:

histprov:OBD\_Log\_Files:/table:flex\_logs:/column:System\_Mode:/keycolumn:unit\_id:/keyvalue:V30\_TST

For reference is a screenshot of the DB table associated with the historian-

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/8/a/8a56cb2322b1fb52a4938d2da903fe90615f59bc.png)

Not sure if this is relevant, but the DB table’s structure itself requires a composite key using t\_stamp, unit\_id, and batch\_id to avoid duplicates during file inserts.

An alternative would be pivoting to individual tables in the schema for each unit, but I’d rather not have an increasing number of tables at each unit deployment

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [December 12, 2025, 10:21pm UTC](https://forum.inductiveautomation.com/t/powerchart-keycolumn-distinctions/112795/2 "2025-12-12T22:21:15Z")

</div>

Might be that the keyvalue is always interpreted as a string? So will never match any integers?

---

<div class="post-metadata">

**Author:** ![mark.landman89](https://avatars.discourse-cdn.com/v4/letter/m/ed8c4c/32.png) [@mark.landman89](https://forum.inductiveautomation.com/u/mark.landman89)\
**Post date:** [December 12, 2025, 10:42pm UTC](https://forum.inductiveautomation.com/t/powerchart-keycolumn-distinctions/112795/3 "2025-12-12T22:42:34Z")

</div>

The instance that is using the integer as a keyvalue, used with keycolumn:MS\_STATE does return data to the powerchart. It is the string V30\_TST instance that is giving me problem.

Are you implying that keyvalue is expecting an integer?

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [December 12, 2025, 10:45pm UTC](https://forum.inductiveautomation.com/t/powerchart-keycolumn-distinctions/112795/4 "2025-12-12T22:45:40Z")

</div>

Ah, missed that. Does the table column have space padding?

---

<div class="post-metadata">

**Author:** ![mark.landman89](https://avatars.discourse-cdn.com/v4/letter/m/ed8c4c/32.png) [@mark.landman89](https://forum.inductiveautomation.com/u/mark.landman89)\
**Post date:** [December 12, 2025, 10:50pm UTC](https://forum.inductiveautomation.com/t/powerchart-keycolumn-distinctions/112795/5 "2025-12-12T22:50:15Z")

</div>

It does not - here is a snippet of the table parameters from MySQL. I have it defined as VARCHAR(7) which matches my value for V30\_TST.

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/b/e/bed56df9318ef76886f2c2fd24c24d9107bc537e.png)

---

<div class="post-metadata">

**Author:** ![mark.landman89](https://avatars.discourse-cdn.com/v4/letter/m/ed8c4c/32.png) [@mark.landman89](https://forum.inductiveautomation.com/u/mark.landman89)\
**Post date:** [December 12, 2025, 11:07pm UTC](https://forum.inductiveautomation.com/t/powerchart-keycolumn-distinctions/112795/6 "2025-12-12T23:07:37Z")

</div>

I’ve also tested other key/value pairs that utilized strings and were successful. My thought was that it might be related to the DB having a composite key, but I briefly removed unit\_id as a key

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [December 12, 2025, 11:08pm UTC](https://forum.inductiveautomation.com/t/powerchart-keycolumn-distinctions/112795/7 "2025-12-12T23:08:06Z")

</div>

I'm out of ideas. Time for a support ticket.
