(Yet another ancient post I missed, sorry.) On 23 February 2011 04:03, William Doughty <[email protected]> wrote: > > The following code segment produces unexpected results when extracting > data from a postgres SELECT query > > rowset<row>::const_iterator i = rs.begin(); > for (i=rs.begin(); i != rs.end(); ++i) > { > // do something > } > > The calls to rs.begin() increment the row counter in backend fetch for > each call. The first begin returns the first row, the subsequent begin call > increments the row counter and returns the next row, not the first row.
Thanks for the report. So, short answer is that the current behaviour is by design. It is not a bug. I created ticket with additional comments: https://github.com/SOCI/soci/issues/50 Best regards, -- Mateusz Loskot, http://mateusz.loskot.net ------------------------------------------------------------------------------ Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_d2d_jan _______________________________________________ soci-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/soci-users
