|
-
Hi.
Can't really understand what your problem is from your post. I can see your trigger definition is a little off. Is you problem the compilation of the trigger, or what it does subsequently. I guess it should read:
Code:
create or replace trigger job_bifert
before insert on jobs
for each row
begin
if (:new.xmldoc is null) then
return;
end if;
select
xmltype.getstringval(:new.xmldoc.extract('/recordset/row/title/text()')),
xmltype.getstringval(:new.xmldoc.extract('/recordset/row/company/text()')),
xmltype.getstringval(:new.xmldoc.extract('/recordset/row/location/text()'))
into :new.title, :new.company, :new.location
from dual;
end;
/
Is all the XML in a variable ready to pass into you procedure?
Why are you parsing it in the trigger, rather than the procedure, since this would perform better than doing half of the job in the procedure and half in the trigger.
Please provide everything you need to build the test case, including the CREATE TABLE statements. Provide a version of the code you are using, and the errors you are getting (compile or runtime errors).
Cheers
Tim...
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|