0

Is that possible to pass the variable path on JSON_QUERY? I've tried this

select
   t1.ID,
   JSON_QUERY(PRC_DATA, t2.key WITH WRAPPER)
from
   TEST_JSON T1,
   TEMPLATES T2 

But it returns the following error

ORA-40454: path expression not a literal
40454. 00000 -  "path expression not a literal"
*Cause:    The provided path expression was not a literal (a constant).
*Action:   Provide a constant path expression.
Error at Line: 9 Column: 35

I don't want to use Execute Immediate, because I want to INSERT-SELECT this JSON keys into a table.

1 Answer 1

1

The JSON path expression has to be a literal. We cannot work with case where the path to be evaluated is defendant on some other row, or even the same row.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.