Usage of ora:contains
270193Mar 9 2005 — edited Mar 31 2005Hi All,
I have a scenario where i need to check for a string in the Id attribute of an Element.
I tried with
SELECT
count(*)
FROM
CommonAssetCatalog
WHERE
(existsNode(object_value,'contains(//T@Id,"var")') = 1)
and it reutrns me 0 records
SELECT
count(*)
FROM
CommonAssetCatalog
WHERE
(existsNode(object_value,'//T@Id="variable"') = 1)
It returns the matching number of records..
The T Element is declated as CLOB while registering the schema.
Can we use ora:contains here. I tried the below query
SELECT
count(*)
FROM
CommonAssetCatalog
WHERE
existsNode(object_value,'//T[ora:contains(Id,"S")>0]','xmlns:era="http://abc.com/schema"') = 1
and it gives the error :
ORA-31013: Invalid XPATH expression
Pls let me know how can i resolve this..
Thanks in Advance
Sateesh