I am trying to parse JSON and pass the key-value pairs into a stored procedure.
declare @json nvarchar(max) = '{"bin":1,"type":"A"}',
@id int = 1234
exec someStoreProcedure select
json_value(@json, '$.bin'),
json_value(@json, '$.type'),
@id
How can I pass in json_values
to a stored procedure?