cast story.{upvotes,downvotes} to signed on mysql, integer on postgres

old mysql doesn't support 'cast(1 as integer)', but new/mariadb does

postgres doesn't support 'cast(1 as signed)'

should fix #145