Skip to Main Content

Database Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Usage of ora:contains

270193Mar 9 2005 — edited Mar 31 2005
Hi 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

Comments

Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Apr 28 2005
Added on Mar 9 2005
2 comments
255 views