Forum Discussion
3 years ago
Hi Stewart,
We seem to have found the issue thanks to your help. We took your example and added it exactly as you had typed and it worked we then worked backwards and found the problem to be how Pandas handles the CSV data that is read in. We had previously casted the value of the custom property but never looked at the deviceId property which was also being returned as a Numpy.Int64 value. We were able to fix the problem on the Pandas function that we use to read the CSV and leveraged the dtype parameter to ensure that the datatype did not end up as a Numpy.Int64 type.
mydata = pd.read_csv("accounts.csv", skiprows=1, names=['deviceId', 'autotask.accountnumber'], dtype={'deviceId': int,'autotask.accountnumber':str})
Related Content
- 2 years ago
- 2 years ago
- 3 years ago
- 2 years ago