I'm trying to create a SQL function which is collecting JSON data from the db . First i faced the problem that i cant write function(JSON_EXTRACT,...) but after little research i think when i remove the "function" it works . But now when i try to put the values to List it throws this error . My Function :
create function returnRecord()
returns boolean
deterministic
begin
declare @myList varchar(255);
SELECT r.data as r1
INTO @myList
FROM records r
join columns c on r.view_id = c.view_id
where ('JSON_EXTRACT', r.data, c.name);
end;
I was trying different ways and i want to take the Json data from the db .