Copy operations correctly set the cursor.rowcount attribute

Fixes ticket #180.