All Questions
16
questions
1
vote
1
answer
43
views
Using param in SQL stored procedure select value
I have a stored procedure that I am using to extract values from a JSON column in a table:
@ReferenceID int,
@BureausID int,
@EmployersID int,
@FileType varchar(12),
@TargetIndex ...
2
votes
2
answers
82
views
JSON Object Query SQL Server
I have a JSON string which is the following:
[
{
"id": 103001058774,
"name": "status",
"label": "Status",
"...
0
votes
1
answer
56
views
Json input to Sql table
I've a requirement to load the json input into a table which has multiple arrays
declare @json nvarchar(max);
set @json =
'{
"method":"email",
"value&...
-1
votes
1
answer
57
views
How can I modify JSON object from a column while retrieving the data in SQL Server
I have a JSON array object like below in a SQL Server table column:
[
{
"Name": "test1",
"Favouties": {
"LikedColor": "Red",
&...
0
votes
1
answer
847
views
How to use OPENJSON to concatenate json Array in a column of a table
I have a column in SQL table which has a string value denoting a JSON array. I need to concatenate the array for comparison. There are multiple rows of this data and will be using a CURSOR to iterate ...
2
votes
1
answer
384
views
sql-server OPENJSON ways to parse multiple array value elements as one element?
Is there is any other (more pretty) way to accomplish the following?
I am struggling with a way to display multiple elements of an array as one element.
I have a JSON-string, that looks like this:
...
0
votes
3
answers
162
views
Parse JSON arrays using OPENJSON to table
I am confused how to shred my JSON data into a table because is not formatted with names for the arrays
The actual JSON file is much bigger (19K lines) so I only pulled a small portion of it out (the ...
0
votes
1
answer
3k
views
How to extract array data from a JSON Column in SQL Server (OPENJSON, JSON_QUERY)
We have a SQL Server table that has a varchar(max) column with JSON data, but one of the fields is an array. Try as I might I can't get it to extract these one-per-row. In the past I've managed to do ...
1
vote
2
answers
6k
views
How to parse JSON list of list using SQL Server
To parse data in a SQL Server database from an API that returns the data in the following format:
declare @json nvarchar(4000) = N'{
"List":{
"header":{
"id&...
5
votes
3
answers
4k
views
How to Set OPENJSON Path to Nested Array
I'm trying to set the path for my OPENJSON function for the nested array, but it's not working. Tried different variations and examples/resources I found online and still cannot figure it out.
Any ...
1
vote
1
answer
3k
views
Concatenate Array Values Using Json_Query
I have a table in a SQL Server database that stores JSON in one of its columns. The structure is as follows:
Table Person
| Name | ExtraInfo |
|--------|:----------...
1
vote
1
answer
266
views
SQL query OpenJson with deep nested arrays loop
I know there a lot of similar questions and answers here. I've read most of them but I'm unable to query nested arrays in a JSON structure. I'm lost in the CROSS APPLY's.
I'm actually querying a web ...
0
votes
2
answers
1k
views
Difficulty with PATH for JSON Data in SQL Server using OPENJSON function
I am now importing JSON data into a SQL Server table where the JSON data is stored as a single column entry.
I now have a more complex JSON structure and I am having difficulty with the path
in the ...
-2
votes
1
answer
103
views
How can I read below Json column stored in SQL Server using openjson?
Declare @ResponseText nvarchar(4000)
set @responseText ='{
"submissions": [
{
"xml_id":"id_x5d94851726b470.68571510",
"fields": [
{"fieldvalue":"customerEmail@...
1
vote
1
answer
111
views
JSON to SQL Server 2016 missing rows from array
I am new to getting JSON into SQL Server 2016, I thought I had it down, but I notice that I am missing some details from the array, looking at the image, there are four address', but I saw there are ...