Folks,

I've tried to pin down the problem revealed by test6
in SQLite3 tests [1]. I have added comment [2] with further
explanation of my findings.

It seems to be clear what needs to be done, but I'm not really
sure which of the two sequences represent desired behaviour
in SOCI in general. Here I copied the two versions from the comment:

1)
statement st1 = (sql.prepare << "update soci_test set val = val + 1");
st1.execute(false);
st1.get_affected_rows()

2)
statement st1 = (sql.prepare << "update soci_test set val = val + 1");
st1.execute(false);
st1.fetch();
st1.get_affected_rows()

I assume we all agree the get_affected_rows behaviour is
specific to DBMS backend and it is tricky to get it unified in
abstractions like SOCI.

But, speaking of SOCI public interface, which of the sequence
we want to support, 1) or 2) or both?
I'd like to have such question answered before diving into reimplementing it.

Please, feel free to brainstorm it here or comment the issue at GH.

[1] 
https://github.com/SOCI/soci/blob/master/src/backends/sqlite3/test/test-sqlite3.cpp
[2] https://github.com/SOCI/soci/issues/15#issuecomment-11922458

Best regards,
--
Mateusz Loskot, http://mateusz.loskot.net

------------------------------------------------------------------------------
Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS,
MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current
with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft
MVPs and experts. ON SALE this month only -- learn more at:
http://p.sf.net/sfu/learnmore_123012
_______________________________________________
soci-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/soci-users

Reply via email to