Hi,
Would appreciate any help with this!
I have generated an automated SQL script in Synapse to score a ML model:
-- Create a stored procedure for storing the scoring script.
CREATE PROCEDURE dbo.view_NYC
AS
BEGIN
-- Select input scoring data and assign aliases.
WITH InputData AS
(
SELECT
[tipped],
[paymentType],
[passengerCount],
CAST([tripDistance] AS [real]) AS [tripDistance],
[tripTimeSecs],
CAST([pickupTimeBin] AS [varchar]) AS [pickupTimeBin]
FROM [dbo].[NYC_manual]
)
-- Using T-SQL Predict command to score machine learning models.
SELECT *
FROM PREDICT (MODEL = (SELECT [model] FROM dbo.aml_nyc WHERE [ID] = 'gr-synapse-nyc_taxi_train-20220508121353-Best:1'),
DATA = InputData,
RUNTIME = ONNX) WITH ([variable_out1] [float])
END
GO
Execute the above stored procedure.
EXEC dbo.view_NYC
However, I get the following error:
11:06:45
Started executing query at Line 1
Arithmetic Overflow.
Total execution time: 00:00:05.930
How do I debug this error?
From searching for an answer, this type of error is caused when converting one data type to another. But how do I even start to debug where this is happening?