explicit casts to int in sql queries