小编Pro*_*007的帖子

Error Executing SQL Server Agent Job: JSON text is not properly formatted, Unexpected character '"'

Using Microsoft SQL Server 2016 (RTM) Standard Edition, I am trying load a JSON into a SQL Server table using a SQL Server Agent Job, and get the following error:

JSON text is not properly formatted. Unexpected character '"' is found at position 508. [SQLSTATE 42000] (Error 13609).

But when I run it as T-SQL it inserts the data with out errors.

DECLARE @return_value int,
    @responseText nvarchar(MAX),
    @json nvarchar(MAX)

EXEC    @return_value = [dbo].[HTTPRequest]
    @URI = N'http://flexapi.foresightgps.com/ForesightFlexAPI.ashx',
    @methodName = N'post',
    @requestBody …
Run Code Online (Sandbox Code Playgroud)

sql-server json sql-agent sql-agent-job

5
推荐指数
1
解决办法
6885
查看次数

标签 统计

json ×1

sql-agent ×1

sql-agent-job ×1

sql-server ×1