properly type cast param values