Python Forum

Full Version: datatype check
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello,
using synapse pipeline, I generate a .parquet file with data in columns such as HoseNo (Which contains numbers), ClientName (which contains text), etc.
In pyspark, I check for the type of the value in each column and it shows as str for every single field.
Do you know why I do not get number columns as integer datatypes?

example:
type(row["HouseNo"])
result:
Output:
<class 'str'>
p.s. I am unable to placed the above simple python code in code snipt using the button in the thread.

Thank you
It's pretty much impossible to answer without seeing your code, don't you think? Is it taking care to convert strings to numbers? Is it failing somewhere? Please don't make us guess!