Skip to content Skip to sidebar Skip to footer

Keeping Blank Values For Int Columns In Python Pandas

I am loading csv files to sql server table. EmpNo Ename ProdID Sales Value Int Varchar Int Int Float But I am getting ProdID,Sales,Amount Values as 0 for blanks.But want to keep th

Solution 1:

Try: df=df.where(df[['Ename','ProdID','Sales']].eq(' '),0)


Post a Comment for "Keeping Blank Values For Int Columns In Python Pandas"