Fixing the datatype error