There is one parameter (userID) which is being passed into the query via cmd.Parameters.Add. The C# type of this variable is long (Int64) and the types of the columns it's being compared to in the db ...