1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

- Work on JSON and JSON UDF's

modified:
  storage/connect/json.cpp
  storage/connect/jsonudf.cpp
  storage/connect/tabjson.cpp

- CntReadNext: Enable EvalColumns for longjmp
modified:
  storage/connect/connect.cc
This commit is contained in:
Olivier Bertrand
2015-02-19 00:59:02 +01:00
parent 2201aa66cf
commit 564d41faf4
4 changed files with 1247 additions and 1105 deletions

View File

@@ -825,7 +825,9 @@ PJSON JSONCOL::GetRow(PGLOBAL g)
PJSON nwr, row = Tjp->Row;
for (int i = 0; i < Nod-1 && row; i++) {
switch (row->GetType()) {
if (Nodes[i+1].Op == OP_XX)
break;
else switch (row->GetType()) {
case TYPE_JOB:
if (!Nodes[i].Key)
// Expected Array was not there
@@ -932,7 +934,11 @@ void JSONCOL::WriteColumn(PGLOBAL g)
jsp = ParseJson(g, s, (int)strlen(s), 0);
if (arp) {
arp->AddValue(g, new(g) JVALUE(jsp));
if (Nod > 1 && Nodes[Nod-2].Rank)
arp->SetValue(g, new(g) JVALUE(jsp), Nodes[Nod-2].Rank-1);
else
arp->AddValue(g, new(g) JVALUE(jsp));
arp->InitArray(g);
} else if (objp) {
if (Nod > 1 && Nodes[Nod-2].Key)