[mythtv-commits] Ticket #3061: MSqlQuery.size() removal for libmythtv
MythTV
mythtv at cvs.mythtv.org
Fri Feb 9 08:30:13 UTC 2007
#3061: MSqlQuery.size() removal for libmythtv
-----------------------+----------------------------------------------------
Reporter: anonymous | Owner: ijr
Type: patch | Status: new
Priority: minor | Milestone: unknown
Component: mythtv | Version: head
Severity: medium | Resolution:
-----------------------+----------------------------------------------------
Comment (by david at hardeman.nu):
Replying to [comment:5 luitjens]:
> This patch has worked just fine. Tonight I recorded 9 programs in 2
hours while watching another recorded program with zero problems. I have
also updated the patch to the latest head and removed a couple more
.size() calls and replaced some of them with .numRowsAffected(). usleep
is this function compatible for you?
Ok, I did a quick review of the patch:
* I couldn't find any numRowsAffected calls in the patch.
* There are still a lot of redundant isActive() calls left
* The .size() removal has been taken too far. For instance, code like
this is just plain ugly:
{{{
- int qsize = query.size();
+ while(query.next())
+ qsize++
}}}
MySQL and PostgreSQL (and any other DB I've used with QT) support the
.size() call, so I see no point in not using it where appropriate.
In order to not come across as a nag...I'll provide an updated patch later
today or tomorrow.
--
Ticket URL: <http://svn.mythtv.org/trac/ticket/3061#comment:6>
MythTV <http://www.mythtv.org/>
MythTV
More information about the mythtv-commits
mailing list