I’m running a training (cdf-fundamentals) but having an error while try to run a Datapoint Transformation.
My query is
/* MAPPING_MODE_ENABLED: false */
/* {"version":1,"sourceType":"raw","mappings":[{"from":"","to":"id","asType":"BIGINT"},{"from":"","to":"externalId","asType":"STRING"},{"from":"","to":"timestamp","asType":"TIMESTAMP"},{"from":"","to":"value","asType":"DOUBLE"}]} */
SELECT
concat('Milton1972:',dp.sensor) AS externalId,
cast(time_stamp/1000 as timestamp) AS timestamp,
cast(value AS double)
FROM IFSDB.values AS dp,
--selecting from _cdf.timeseries means we select from the timeseries we ingested to CDF earlier. We do this to make sure all the time series we try to add data points to actually exist
_cdf.timeseries AS ts WHERE CONCAT('Milton1972:',dp.sensor) = ts.externalId
When I try to run I receive the following message:
Request with id 59a5e9ab-c832-9d6d-8b0b-4562a0e8ddb3 to https://api.cognitedata.com/api/v1/projects/cdf-fundamentals/timeseries/data failed with status 400: Expected string value for data point for time series: (id: '8731588848856306', externalId: 'Milton1972:VAL_23-PT-92536:X.Value').
I´m sure I´ve created right the Time Series.