Made SqlBagOStuff fully avoid transactions when possible

Change-Id: I775d872b522f68462496bbfa685665cc8faf9bf1
Merge "Made SqlBagOStuff fully avoid transactions when possible"