You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When an application executes SELECT LAST_INSERT_ID() , ProxySQL doesn't execute this query on any backend, but replies returning the value of last_insert_id sent in the OK packet
Although this is ok in many circumstances, this is not always correct.
Details, similarities and differences about the two are listed here
For this reason, ProxySQL should try to not send incorrect data when they do not match.
To return the correct value of LAST_INSERT_ID() and not last_insert_id, ProxySQL should execute the query on the same backend connection. This is possible only if multiplexing is disabled.
A possible workaround that should work on most of the use cases is:
track the the last HG where affected_rows is not 0
if the HG has already a connection attached (multiplexing is disabled) execute the query on the same connection
if the HG doesn't have a connection attached, fall back on old algorithm and return last_insert_id
The text was updated successfully, but these errors were encountered:
When an application executes
SELECT LAST_INSERT_ID()
, ProxySQL doesn't execute this query on any backend, but replies returning the value oflast_insert_id
sent in the OK packetAlthough this is ok in many circumstances, this is not always correct.
Details, similarities and differences about the two are listed here
For this reason, ProxySQL should try to not send incorrect data when they do not match.
To return the correct value of
LAST_INSERT_ID()
and notlast_insert_id
, ProxySQL should execute the query on the same backend connection. This is possible only if multiplexing is disabled.A possible workaround that should work on most of the use cases is:
affected_rows
is not 0last_insert_id
The text was updated successfully, but these errors were encountered: