# Error Forwarding Data

**URL:** <https://forum.inductiveautomation.com/t/error-forwarding-data/65557>\
**Category:** Ignition\
**Tags:** ignition81, scripting\
**Created:** [October 21, 2022, 9:43pm UTC](https://forum.inductiveautomation.com/t/error-forwarding-data/65557 "2022-10-21T21:43:02Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![vshn](https://avatars.discourse-cdn.com/v4/letter/v/df788c/32.png) [@vshn](https://forum.inductiveautomation.com/u/vshn)\
**Post date:** [October 21, 2022, 9:43pm UTC](https://forum.inductiveautomation.com/t/error-forwarding-data/65557/1 "2022-10-21T21:43:02Z")

</div>

Hey folks, I'm using a tag change script on Ignition Edge Compute (8.1.17) to log data to my history provider. The script is defined in a UDT, with all 100 instances logging incoming data to the same location, and uses _system.tag.storeTagHistory()_ to push the tag data to the storage provider.

I've noticed an error on the logs (MemoryForwardTransaction -- Error Forwarding Data), saying a SQLiteException was thrown, "A PRIMARY KEY Constraint failed (Unique Constraint failed: tagdata.t\_stamp, tagdata.tagid)".

I'm wondering if this is because multiple tags are writing to the same location? Does storeTagHistory() only let you write to a unique location each time? Thanks! (Not much of a SQL expert sorry!)

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

---

<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:** [October 21, 2022, 9:45pm UTC](https://forum.inductiveautomation.com/t/error-forwarding-data/65557/2 "2022-10-21T21:45:41Z")

</div>

Only one value permitted for a tag at a particular timestamp. Your storage logic needs to account for that.
