> Therefore, for each post-back, I'll need to query the database before > _either_ of these methods return. > > If both methods query the database independently, intervening CRUD > operations may cause them to return inconsistent results (a size that is too > small or too large). I can and should retrieve both the rows and their > number with a single query. The question is where I should do this.
Like I stated in my other email, hide this in your model implementation. For example, on detach load the results (window) and the current row count in one transaction. > MY PROBLEM is that I'm seeing an inconsistent number of rows displayed for > the same query. It seems to depend upon how large the previous query's > results were. That sounds like something very specific for your situation. Is the database regularly updated from outside your application? Please don't cross post and keep discussions about the same topic in the same thread so that it is easier for people to follow them. Eelco ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnk&kid0944&bid$1720&dat1642 _______________________________________________ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user