# Scheduled Transaction Groups Record Two Values

**URL:** <https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047>\
**Category:** Ignition\
**Created:** [August 23, 2012, 7:01pm UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047 "2012-08-23T19:01:16Z")\
**Posts on this page:** 16\
**Page:** 1

<div class="post-metadata">

**Author:** ![Duffanator](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/duffanator/32/3560_2.png) [@Duffanator](https://forum.inductiveautomation.com/u/Duffanator)\
**Post date:** [August 23, 2012, 7:01pm UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/1 "2012-08-23T19:01:16Z")

</div>

Hey guys,

Last Saturday, for some reason, a scheduled transaction group started logging to the database twice. It’s been working fine for a few months now and nothing has changed recently with it. Here is the schedule settings:

![](https://us1.discourse-cdn.com/inductiveautomation/original/2X/7/73c52ad700e067636d0bc578ee5f8ef5aca9fa5f.png)

and the data in the database:

 ![](https://us1.discourse-cdn.com/inductiveautomation/original/2X/c/c1fa8611092897d474ee72c5def138ff48cc63c3.png)  

I’m not sure what to look for here since it was working fine with no issues for a while now. Any thoughts?

---

<div class="post-metadata">

**Author:** ![dave.fogle](https://avatars.discourse-cdn.com/v4/letter/d/43a26b/32.png) [@dave.fogle](https://forum.inductiveautomation.com/u/dave.fogle)\
**Post date:** [August 23, 2012, 11:51pm UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/2 "2012-08-23T23:51:05Z")

</div>

You didn't happen to make a copy of that project on Friday did you? Any other gateways (like a development gateway) running that project and writing to the same database?

---

<div class="post-metadata">

**Author:** ![Duffanator](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/duffanator/32/3560_2.png) [@Duffanator](https://forum.inductiveautomation.com/u/Duffanator)\
**Post date:** [August 23, 2012, 11:54pm UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/3 "2012-08-23T23:54:41Z")

</div>

No… but I do have a redundant server setup though… However, it is connected to the primary server so it shouldn’t be writing to the database at all.

---

<div class="post-metadata">

**Author:** ![Robert.McKenzie](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/robert.mckenzie/32/4134_2.png) [@Robert.McKenzie](https://forum.inductiveautomation.com/u/Robert.McKenzie)\
**Post date:** [August 24, 2012, 12:01am UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/4 "2012-08-24T00:01:09Z")

</div>

Can you stop the service on the slave tonight and see if it still logs twice?

---

<div class="post-metadata">

**Author:** ![Duffanator](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/duffanator/32/3560_2.png) [@Duffanator](https://forum.inductiveautomation.com/u/Duffanator)\
**Post date:** [August 24, 2012, 11:16am UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/5 "2012-08-24T11:16:02Z")

</div>

I got this after I left work so I couldn’t stop it last night. I will stop it today and report back tomorrow.

FYI, I have a bunch of other transaction groups that are trigger based, not schedule based, and they are NOT being written to the database twice. Seems to be only an issue with the schedule based transaction groups. I will let you know what I find out about the backup server possibly being the issue. Thanks!

---

<div class="post-metadata">

**Author:** ![Robert.McKenzie](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/robert.mckenzie/32/4134_2.png) [@Robert.McKenzie](https://forum.inductiveautomation.com/u/Robert.McKenzie)\
**Post date:** [August 24, 2012, 3:26pm UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/6 "2012-08-24T15:26:42Z")

</div>

OK, let us know how it goes tonight. Also, what version of Ignition are you using?

---

<div class="post-metadata">

**Author:** ![Duffanator](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/duffanator/32/3560_2.png) [@Duffanator](https://forum.inductiveautomation.com/u/Duffanator)\
**Post date:** [August 24, 2012, 3:30pm UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/7 "2012-08-24T15:30:45Z")

</div>

Will do.

Ignition version: 7.5.1 (b1122)

---

<div class="post-metadata">

**Author:** ![Duffanator](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/duffanator/32/3560_2.png) [@Duffanator](https://forum.inductiveautomation.com/u/Duffanator)\
**Post date:** [August 25, 2012, 10:48am UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/8 "2012-08-25T10:48:46Z")

</div>

Someone marked my previous thread solved when it wasn’t and now I can’t add to it, so I’m starting this one. The previous thread is [here.](http://www.inductiveautomation.com/forum/viewtopic.php?f=72&t=8740)

I turned off the backup gateway but all of my scheduled transaction groups are still logging to the gateway twice, so it does not seem to be a redundant server issue. There is only one copy of this project running and now I have only one Ignition server running (I’m going to start the backup server up again now that I know this isn’t the issue.)

---

<div class="post-metadata">

**Author:** ![Robert.McKenzie](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/robert.mckenzie/32/4134_2.png) [@Robert.McKenzie](https://forum.inductiveautomation.com/u/Robert.McKenzie)\
**Post date:** [August 27, 2012, 11:53pm UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/9 "2012-08-27T23:53:42Z")

</div>

Something must have changed on the 18th for this to start happening. Try adding another column to your transaction group that logs a string with the name of the project? If you have a second project or gateway logging this info, then one of the duplicates will be blank each time.

---

<div class="post-metadata">

**Author:** ![Duffanator](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/duffanator/32/3560_2.png) [@Duffanator](https://forum.inductiveautomation.com/u/Duffanator)\
**Post date:** [August 29, 2012, 12:04pm UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/10 "2012-08-29T12:04:10Z")

</div>

I did what you suggested and it logs the same thing to the database. The other weird thing is that on Monday night it worked fine, no double logs, but last night it did a double log again.

Another thing I thought of is that the server was moved to the cloud on the 11th, but it was fine for an entire week and then started double logging on the 18th. Not sure if that has something to do with it? ![:scratch:](https://us1.discourse-cdn.com/inductiveautomation/original/1X/76d1620bec252bfac07050c889ff5a91dc8a9c25.gif ":scratch:")

![](https://us1.discourse-cdn.com/inductiveautomation/original/2X/1/1e2dd0c9b92b914df0238d286469a45230999356.png)

---

<div class="post-metadata">

**Author:** ![Colby.Clegg](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/colby.clegg/32/3282_2.png) [@Colby.Clegg](https://forum.inductiveautomation.com/u/Colby.Clegg)\
**Post date:** [August 29, 2012, 11:33pm UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/11 "2012-08-29T23:33:54Z")

</div>

Hi,

Looking closely at those times, and at how the scheduling works, I’m going to guess that it’s an issue on our side with rounding in the timing/executing system. Basically, it works by finding the next time that it should run, subtracting the current time, and telling the system to wait that long. As soon as the group runs, it is asked to calculate the next execution time.

Looking at your timestamps, we see some rows coming in at 23:56:59, not 57:00. IF it ran then, and then immediately calculated the time, it would say, “hey, run again in 1 second- at 57:00”, which is in line with what we see.

I’ll have to look closely at how to handle this. If nothing else, this scheduling system only offers resolution to the minute, so if you’re specifying an exact time, there really shouldn’t be a way for it to run more than once a minute.

As a work around, I think you can do the following: Specify a range (“23:57-23:58”), and then set the rate for something larger than the range, like 5 minutes. When you specify a range, you can then specify a rate, and this works by adding the rate on to the last execution, until it’s outside the range. Then, it looks to the start of the next range (which can be the next day). In this case, your rate is large, so it will always forward over to 23:57 the next day. If it happens to run at 22:59, no problem, because 5 minutes will still be outside of the range.

Hope this helps,

---

<div class="post-metadata">

**Author:** ![Colby.Clegg](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/colby.clegg/32/3282_2.png) [@Colby.Clegg](https://forum.inductiveautomation.com/u/Colby.Clegg)\
**Post date:** [August 30, 2012, 12:00am UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/12 "2012-08-30T00:00:28Z")

</div>

Err, I might be wrong about my work-around. It only adds the rate when the time falls inside the range, so if my guess at what’s happening is true, it’s still going to execute twice - once early, and once at the right time. We’ll have to try to get some sort of fix or extra check in for the next update.

Regards,

---

<div class="post-metadata">

**Author:** ![Colby.Clegg](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/colby.clegg/32/3282_2.png) [@Colby.Clegg](https://forum.inductiveautomation.com/u/Colby.Clegg)\
**Post date:** [September 5, 2012, 10:01pm UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/13 "2012-09-05T22:01:09Z")

</div>

Ok, we’ve tweaked the scheduling a bit in 7.5.3 beta 3, so that a group can only run once per minute, unless using a range with a slower rate. In other words, if it happens to run a bit early, it won’t run again immediately, but will instead calculate the next time after that.

That beta should be up tomorrow, I think.

Regards,

---

<div class="post-metadata">

**Author:** ![Duffanator](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/duffanator/32/3560_2.png) [@Duffanator](https://forum.inductiveautomation.com/u/Duffanator)\
**Post date:** [September 5, 2012, 10:13pm UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/14 "2012-09-05T22:13:00Z")

</div>

Cool, I’ll check it out. Thanks, Colby!

---

<div class="post-metadata">

**Author:** ![James.Lorenz](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/james.lorenz/32/3290_2.png) [@James.Lorenz](https://forum.inductiveautomation.com/u/James.Lorenz)\
**Post date:** [September 7, 2012, 8:05pm UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/15 "2012-09-07T20:05:12Z")

</div>

Ran a little behind with the beta, but it is now up on the website.

---

<div class="post-metadata">

**Author:** ![Duffanator](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/duffanator/32/3560_2.png) [@Duffanator](https://forum.inductiveautomation.com/u/Duffanator)\
**Post date:** [October 1, 2012, 2:16pm UTC](https://forum.inductiveautomation.com/t/scheduled-transaction-groups-record-two-values/5047/16 "2012-10-01T14:16:52Z")

</div>

FYI, after upgrading to 7.5.3 this does not seem to be an issue anymore. I haven’t seen it record a double value since upgrading. I think this issue is resolved. Thanks for the help!
