- CPS-309Getting issue details... STATUS
DB contains something like /bookstore/category[@code=01] 'code 'is the key for the list entry but there is also a 'name' attribute
user does NOT know key value (or even what the key attribute is)
imagine category has 'name' value. 'SciFi. User wants to finds category with that name using
//category[@name='SciFi']
This means any xPath that ends-with a 'category' (list entry) that as an attribute of 'name' with value 'SciFi'
System COULD find out using models but path is incomplete more then 1 match possible for 'category' in theory. But this might not be needed. Instead
1) looks for xPath that ends with //category[@name='SciFi'] -> 0 results (existing behavior, no new code)
NEW
2) look for xPath that ends with //category[@Name=*] ->
a) 0 results -> 'name' is NOT the key, continue with step 3
b) 1+ results 'name' is key but value not found, no need to continue!
3) Looks for XPath that ends with //category[@*] AND attributes(jsonb) contains "name='SciFi'"
Note. the part for "attributes(jsonb) contains "name='SciFi'"" has already been implemented for another query