Attention is currently required from: fixeria, pespin. keith has posted comments on this change by keith. ( https://gerrit.osmocom.org/c/osmo-msc/+/28340?usp=email )
Change subject: sqlite optimisation: Avoid unneeded database operation ...................................................................... Patch Set 4: (1 comment) File src/libmsc/db.c: https://gerrit.osmocom.org/c/osmo-msc/+/28340/comment/ce8942e1_460cd2a1?usp=email : PS4, Line 302: id = $id LIMIT 1 > Why are you adding `LIMIT 1`? Can there really be more than one entry with > `id = $id`? I consider it standard practice to add a LIMIT 1 to a query that is only intended to ever delete maximum of 1 row. I can't say off the top of my head where I learned this, but I have surely seen it. I don't know if there's any performance benefit. Maybe it's just one more of those oh so many things that programmers do to convey intention to other programmers but that one could always argue are not really necessary, because X or Y will "never" happen. -- To view, visit https://gerrit.osmocom.org/c/osmo-msc/+/28340?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: comment Gerrit-Project: osmo-msc Gerrit-Branch: master Gerrit-Change-Id: I777155c0f818b979c636bb59953719e472771603 Gerrit-Change-Number: 28340 Gerrit-PatchSet: 4 Gerrit-Owner: keith <[email protected]> Gerrit-Reviewer: Jenkins Builder Gerrit-CC: fixeria <[email protected]> Gerrit-CC: pespin <[email protected]> Gerrit-Attention: fixeria <[email protected]> Gerrit-Attention: pespin <[email protected]> Gerrit-Comment-Date: Sat, 11 Oct 2025 18:10:40 +0000 Gerrit-HasComments: Yes Gerrit-Has-Labels: No Comment-In-Reply-To: fixeria <[email protected]>
