mirror of
https://github.com/postgres/postgres.git
synced 2025-07-07 00:36:50 +03:00
Teach jsonpath string() to unwrap in lax mode
This was an ommission in commit 66ea94e
, and brings it into compliance
with both other methods and the standard.
Per complaint from David Wheeler.
Author: David Wheeler, Jeevan Chalke
Reviewed-by: Chapman Flack
Discussion: https://postgr.es/m/A64AE04F-4410-42B7-A141-7A7349260F4D@justatheory.com
This commit is contained in:
@ -1606,6 +1606,9 @@ executeItemOptUnwrapTarget(JsonPathExecContext *cxt, JsonPathItem *jsp,
|
||||
JsonbValue jbv;
|
||||
char *tmp = NULL;
|
||||
|
||||
if (unwrap && JsonbType(jb) == jbvArray)
|
||||
return executeItemUnwrapTargetArray(cxt, jsp, jb, found, false);
|
||||
|
||||
switch (JsonbType(jb))
|
||||
{
|
||||
case jbvString:
|
||||
|
Reference in New Issue
Block a user