Varible in trigger - refering to correct schema


Posted on 16th Feb 2014 07:03 pm by admin

Hello

Im having some issues with my trigger.
What I want to do is call opon a different schema - depending on which data the triggers picks up.

For example, lets say, triggers picks up CUSTOMER_ID & MARKET_CODE
CUSTOMER_ID = 20
MARKET_CODE = IT

then I want call a PLSQL package in that is in a schema called CORE_IT. What I tried is using varibles with define, and concat, but I cannot get it to work.

CREATE OR REPLACE TRIGGER AFTER_801
after insert on market_table
referencing new as new old as old
for each row
declare
v_marketcode varchar2(2) := :new.market_code;
begin
CORE_||v_market_code||.Execute_package();
end;
Iv also tried

..
define MK := :new.MARKET_ID
CORE_&MK.Execute_package();
..
I hope you get my picture, any ideas on how to get this to work?

No comments posted yet

Your Answer:

Login to answer
197 Like 21 Dislike
Previous forums Next forums
Other forums

Fatal error: Call to a member function fetchrow() on a non-object in C:xamppht
okay i have this query and everytime i add `item_id`=? to it... it gives me the error in the title..

Data Function is Its Not working IN IE8
This is my first time to use formums. I hope i can get solution for this problem. view plaincopy to

writing my own sobel filter convolution - something is wrong
I am trying to keep it very simple, I cant see anything wrong with my logic, could anybody help poin

Procedure with variable number of columns
Hi, I have a procedure that looks like this:

PROCEDURE PROC(p_cursor OUT sys_refcurso

having probem inserting data into db table
hi

i have a table with following columns in it
Code: candidate_id, degree, cgpa, institute

Need Reporting Advice
My SQL server doesn't support MS SQL reporting services that comes with SQL Enterprise or Express. T

Help If user voted, block them
On my Prayer request site, i let users Click a button to Pray for somone that has posted a pray, i g

Login Script Issues
I am using a script I got from http://phpsense.com/php/php-login-script.html in order to allow peopl

COde for a Cc
I'm not receiving $ft as a Cc. Why is that??

$to = "$email";
$headers = "Fr

sapgui f4 help last search
I know this has to be simople. One user (maybe more) does not have the "last search saved" from the

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash