If you have a JSON document that you need to insert into a table in a SQL Server database, the OPENJSON()
function could be just what you need.
OPENJSON()
is a table-valued function that returns JSON in tabular format. That is, it converts your JSON into a tabular result set consisting of rows and columns. Therefore, it enables you to insert it into a table.