Skip to Main Content

SQL & PL/SQL

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!

vpd ploicy using connect by issue

HshihadahMar 22 2008 — edited Mar 22 2008
dear all

i have this table

hr_unit (node varchar2(20),
node_parent varchar2(20))

data in table like

node node_parent
------------------------------------------
1
2 1
3 2
4 3
5 4
6 4

---------------------------------------------------

i create vpd function like this

FUNCTION testvpdunit (schema_name IN VARCHAR2, object_name IN VARCHAR2)
RETURN VARCHAR2
IS
l_vpd VARCHAR2 (32000);
BEGIN
l_vpd :=
'1=1'
|| ' start with a.node = 3
connect by a.node_parent = prior a.node';
RETURN l_vpd;
END;

and add ploicy
using this

BEGIN
DBMS_RLS.add_policy ('hrmstest',
'hr_unit',
'unit_ploicy',
'hrmstest',
'VPDPLOICY.testvpdunit'
);
END;


-----------------------------------------------

when i make select on this table
i have this error ORA-28113: policy predicate has error.


any one have explanation for this error and is their problem when make connect by..start with in same table we have ploicy on it

thanks
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 19 2008
Added on Mar 22 2008
5 comments
460 views