db.QueryDefs.count, isn't the same number as actual exported queries.  Using obj_count instead for all exports.
Added obj_count to import, bit pointless knowing how many objects were export if you can't tally the number imported.