# Transaction Group writing -1 instead of Latched Value

**URL:** <https://forum.inductiveautomation.com/t/transaction-group-writing-1-instead-of-latched-value/104403>\
**Category:** Ignition\
**Tags:** ignition81\
**Created:** [March 28, 2025, 8:12pm UTC](https://forum.inductiveautomation.com/t/transaction-group-writing-1-instead-of-latched-value/104403 "2025-03-28T20:12:51Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![jesse.daniels](https://avatars.discourse-cdn.com/v4/letter/j/e36b37/32.png) [@jesse.daniels](https://forum.inductiveautomation.com/u/jesse.daniels)\
**Post date:** [March 28, 2025, 8:12pm UTC](https://forum.inductiveautomation.com/t/transaction-group-writing-1-instead-of-latched-value/104403/1 "2025-03-28T20:12:51Z")

</div>

i have a transaction group returning data from a view in database writing to PLC tags. i'm using one tag to line up the correct row to return from the view in the update/select area The TG writes the columns into four different tags. all the data in the Latched Value column of the TG are returned correctly, but i have one tag that writes to a -1 value instead of the returned string value, that is displayed in the Latched Value. running the data from a query always returns the correct string. I have tried using the TRACE and DEBUG in the loggers and there is no warnings or errors in anything i can see. Any ideas?

---

<div class="post-metadata">

**Author:** ![ryan.white](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ryan.white/32/73193_2.png) [@ryan.white](https://forum.inductiveautomation.com/u/ryan.white)\
**Post date:** [March 28, 2025, 8:15pm UTC](https://forum.inductiveautomation.com/t/transaction-group-writing-1-instead-of-latched-value/104403/2 "2025-03-28T20:15:34Z")

</div>

Make sure all of your values to record are placed into their respective tags BEFORE the trigger bit is set, not at the same time.

If its not already, put your transaction group into 'Read' mode instead of 'Subscribe'. That will make it force a new read request for all the values when the trigger fires.

Otherwise its using the values currently in the OPC tags when the trigger fires.

---

<div class="post-metadata">

**Author:** ![jesse.daniels](https://avatars.discourse-cdn.com/v4/letter/j/e36b37/32.png) [@jesse.daniels](https://forum.inductiveautomation.com/u/jesse.daniels)\
**Post date:** [March 28, 2025, 8:20pm UTC](https://forum.inductiveautomation.com/t/transaction-group-writing-1-instead-of-latched-value/104403/3 "2025-03-28T20:20:26Z")

</div>

my trigger for the TG is on a tag change. "only evaluate when values have changed". this is the same tag i'm using to line up my returned row

no change to behavior when changing from SUBSCRIBE to READ

---

<div class="post-metadata">

**Author:** ![ryan.white](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ryan.white/32/73193_2.png) [@ryan.white](https://forum.inductiveautomation.com/u/ryan.white)\
**Post date:** [March 28, 2025, 8:22pm UTC](https://forum.inductiveautomation.com/t/transaction-group-writing-1-instead-of-latched-value/104403/4 "2025-03-28T20:22:25Z")

</div>

> [@jesse.daniels](#):
>
> SUBSCRIBE to READ

Ah I read fast, you are doing db -\> PLC, the above change is more for PLC -\> DB.

Have you confirmed the tag in the PLC is of string type, and has enough length to hold the string you are sending it? Is the Ignition tag set to be a string as well? Is the tag in the transaction group pointed at the correct field/column?

---

<div class="post-metadata">

**Author:** ![jesse.daniels](https://avatars.discourse-cdn.com/v4/letter/j/e36b37/32.png) [@jesse.daniels](https://forum.inductiveautomation.com/u/jesse.daniels)\
**Post date:** [March 28, 2025, 8:29pm UTC](https://forum.inductiveautomation.com/t/transaction-group-writing-1-instead-of-latched-value/104403/5 "2025-03-28T20:29:59Z")

</div>

db view data type: varchar(150)  
Ignition tag data type: String  
PLC data type: String (82 Characters)  
TG DataType column is set to String

max string length coming from the view is 50 chars

---

<div class="post-metadata">

**Author:** ![ryan.white](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ryan.white/32/73193_2.png) [@ryan.white](https://forum.inductiveautomation.com/u/ryan.white)\
**Post date:** [March 28, 2025, 8:40pm UTC](https://forum.inductiveautomation.com/t/transaction-group-writing-1-instead-of-latched-value/104403/6 "2025-03-28T20:40:05Z")

</div>

Are you sure that nothing on the PLC is writing into that string? The fact that the latched value has the correct value makes me think the value is getting overwritten very quickly on the PLC side.

---

<div class="post-metadata">

**Author:** ![jesse.daniels](https://avatars.discourse-cdn.com/v4/letter/j/e36b37/32.png) [@jesse.daniels](https://forum.inductiveautomation.com/u/jesse.daniels)\
**Post date:** [March 28, 2025, 8:51pm UTC](https://forum.inductiveautomation.com/t/transaction-group-writing-1-instead-of-latched-value/104403/7 "2025-03-28T20:51:55Z")

</div>

nothing writes to this tag from the PLC.  
this tags' only function is to get the data in the plc from sql. then it is copied to a separate tag before we can do any manipulation to the data. only reference to this tag is within the AOI. This has been working flawlessly for several months, and just recently started doing this.

for reference i'm running v8.1.43

Transaction Group Trace is showing the write is not the same as the source data (latched value).  
 ![image](https://us1.discourse-cdn.com/inductiveautomation/optimized/3X/8/d/8dc2e9dd8907726cb732ac8d377141df0dd6c7df_2_690x28.png)

---

<div class="post-metadata">

**Author:** ![ryan.white](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ryan.white/32/73193_2.png) [@ryan.white](https://forum.inductiveautomation.com/u/ryan.white)\
**Post date:** [March 28, 2025, 8:58pm UTC](https://forum.inductiveautomation.com/t/transaction-group-writing-1-instead-of-latched-value/104403/8 "2025-03-28T20:58:59Z")

</div>

That's strange. My only other though is its using the default value, but for a string that should an empty string, not -1.

At this point its beyond anything I've run into. If its a time critical thing I would consider submitting a ticket to [support](https://support.inductiveautomation.com). This forum is not an official support venue.

If not, then hopefully someone has seen this behavior before.

---

<div class="post-metadata">

**Author:** ![jesse.daniels](https://avatars.discourse-cdn.com/v4/letter/j/e36b37/32.png) [@jesse.daniels](https://forum.inductiveautomation.com/u/jesse.daniels)\
**Post date:** [March 28, 2025, 9:06pm UTC](https://forum.inductiveautomation.com/t/transaction-group-writing-1-instead-of-latched-value/104403/9 "2025-03-28T21:06:04Z")

</div>

it's gotta be a bug in this version. i might try upgrading. if that doesn't fix it i'll put in a ticket. thanks for the replys

i saw this in the 8.1.47 release notes. my tags aren't configured for alarms, but worth a shot, sounds similar.

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/4/2/42ccc8539ed17e9b8f410777d17cea618bade3ca.png)
