Hello,
is it possible with Transaction Group after entering new measurements/data (new rows in the SQL table) to get back the "id" value of the row ("id" is a parameter that is automatically generated/increased when a new value is entered)? Similar like in query in the picture?
Many thanks in advance for your replies,
David
Yes, that works. But I would like to get "id" back inside Transaction Group.
If I first write the data to the DB with the Transaction Group (Standard Group) and then immediately make a query for runNamesQuery, it happens that I don't get the last "id" value. It's like that Transaction Group wrote to the DB later (with a delay).
Ignition uses DB connection pools, so the odds that a following, separate, query will use the same actual connection as the transaction group are very low. And retrieving the "last inserted ID" requires execution on the same actual DB connection.
You will need to switch to a script if this ID is critical to your application.