regexp_instr find an exact match

Need help in writing a statement regexp_instr - I think that's what I use if there is a better way please tell me.

The background is that I need to search for a string in a variable that contains a sql statement, I'm looking for bind variables before execution of

DBMS_SQL. Bind_variable and DBMS_SQL. RUN.  SQL statements may vary these are stored in a table, the only rules I have for research, that is in the sql variables are called P1 through P18.  The problem I have is that the search for P1 returns TRUE if the value contains P10 - P18.  Also P1 - P18 could appear anywhere in the statement so I don't know if they are followed by a comma, blank or at end of line.

Partial procedure (P1 - P18 are the procedure input parameters):

examples of variables val_txt:

Select the description of the Department where dept =: P10

Select decode (": P2, ' * ALL ', ' any CODES", code_desc) of code_master cm where cm.code = decode (: P2, ' * all THE ', cm.code,: P2) and cm.dept = decode (: P10, ' * all THE ', cm.dept,: P10)

I: = 0;

while I < p_parms_count loop

i: = i + 1;

p_x: = ('P' | I);

p_pos: = 0;

Select instr (val_txt, p_x, 1, 1)

in p_pos

Double;

case

When (i = 1 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P1', P1);

When (i = 2 and p_pos > 0) then

DBMS_SQL. Bind_variable (' c_validation, ': P2 ", P2);

When (i = 3 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P3', P3);

When (i = 4 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P4', P4);

When (i = 5 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P5', P5);

When (i = 6 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P6', P6).

When (i = 7 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P7', P7).

When (i = 8 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P8', P8).

When (i = 9 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P9', P9).

When (i = 10 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P10', P10).

When (i = 11 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P11', P11).

When (i = 12 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P12 ", P12).

When (i = 13 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P13', P13);

When (i = 14 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P14', P14).

When (i = 15 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P15', P15);

When (i = 16 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P16', P16).

When (i = 17 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P17', P17);

When (i = 18 and p_pos > 0) then

DBMS_SQL. Bind_variable (c_validation, ': P18', P18).

ON THE OTHER

null;

END CASE;

end loop;

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

It worked for up to 9 parameters.

You will appreciate the help thanks.

If you use a regular expression, check that the next character is not a digit or the end of the string:

regexp_instr( val_txt, ':P' || i || '(\D|$)' )

Tags: Database

Similar Questions

  • Find the exact match from the given string

    Hi friends,

    I have a string separated by commas parent ' asdf, 1234, Vanessa, rtu, 123'.

    If the string to find is "1234", the query should return 'Y' (as '1234' had an exact match).

    If the string to find is '12', the query should return "n" (for '12' has no exact match).

    If the string to find is "12345", the query should return "n" (since '12345' has no exact match).

    If the string to find '123', then the query must return 'Y' (from '123' has an exact match).

    If the string to find is "124", the query should return "n" (since "124" has no exact match).

    The string to find will not have a comma.

    I tried with INSTR, REGEXP, REPLACE logical BI-BOUTEILLE. It does not work. Please help me.

    Not sure exactly what you want or what are your intentions of PL/SQL, but it can help you!

    SQL > ed

    A written file afiedt.buf

    1 declare

    2 v_parent_str VARCHAR2 (200): ='asdf, 1234, Vanessa, rtu, 123';

    3 v_src_str1 VARCHAR2 (50): = '123';

    4 v_src_str2 VARCHAR2 (50): = '12';

    5 v_src_str3 VARCHAR2 (50): = '1234';

    6 v_src_str4 VARCHAR2 (50): = '12345'.

    7 - my varriables is declared.

    8 I PLS_INTEGER;

    9 str VARCHAR2 (100);

    tab 10 sys.dbms_utility.uncl_array;

    11 start

    12 str: = "" ' | " REPLACE (v_parent_str, ",", "",""). '"';

    13 sys.dbms_utility.comma_to_table (str, i, tab);

    14 d in 1.5 in loop

    15. If TRANSLATE (tab (j) "," has "', 'A') (v_src_str2, v_src_str3, v_src_str1, v_src_str4) then

    16 dbms_output.put_line (TRANSLATE (tab (j) "," has "', 'A') |') -exist");

    17 end if;

    18 end of loop;

    19 * end;

    20.

    1234 is

    123 exists

    PL/SQL procedure successfully completed.

    SQL >

    If you need something else, then please clearly describe the requirement.

  • RegExp - word filter swearing - exact match, no partial match

    Hello

    I'm working on a swearing word filter that works find except that it replaces even when the game is partial instead of exact match. Let me explain.

    I have a list of offensive words, but for the purpose of the example, let's say that my list contains only a single offensive word and with her, I build the following rational expression...

    var regexpString:String = "(a55)."
    patern = new RegExp (regexpString, "g |") i ») ;

    .. This filter as follows...

    var str:String = "a55".

    var filteredStr:String = str.replace (model, "*"); will trace *, which is fine for me.

    var str:String = "helloa55";

    var filteredStr:String = str.replace (model, "*"); is traced on Hello * which is not what I'm looking for.

    .. .This is what I would do differently, when I pass "helloa55", I want to spread the word without filtering, because he is not a football match of the word offensive, I would find the word helloa55 and not Hello *.

    I know I could use a feature that will analyse the word and do all the necessary control, but I was wondering if it is all simple and straighforward way to achieve this, some type of flag to add to the regular expression that partial Tunde will correspond to exact match.

    Thank you.

    Yes, \b is much simpler, I have to say

    var _regExp:RegExp = /\b(key|keyer)\b/gi;
    var str:String = "key and keyer and keyerrr"
    trace(str.replace(_regExp, "***"));
    
  • How to find the exact motherboard for Satellite P100-347 model?

    Hello
    I hope someone could help me. I'm looking for a new motherboard for my computer toshiba laptop because it replaced needs.

    I own a laptop Satellite P100-347 of pspa6e-03302cen and have not been able to find this anywhere online forum. Although I found two suppliers of many motherboards of p100, they use numbers of alternative model in which I can't find anywhere in my documents or on the computer. The model numbers they use are something like A000008350 or a number starting with k. I'm sure that the supplier I found has the motherboard, I would need but I would need a list of all the numbers of the other party for my laptop, or a way to find the exact numbers. Any help on this is appreciated...
    Thank you

    To be honest I really don't think that someone here can offer you this info. As you know, this info is for internal use and you can try to get this info from service provider authorized in your country. Sorry, but I don't see a better solution, except to wait here and hope someone can help.

    Good luck!

  • Value not subject to the entry list of values on tab out if an exact match is found

    Hi all

    I use Jdeveloper 12.1.3 (Alta Skin). I have a model based on the input of component values list.

    If I enter the exact value and press tab, the value is always set to the value of the LOV first.

    The value entered is lost and always return the first value of LOV if an exact match is found. Eneterd value is not properly submitted to the server.

    How to present the value if only one match is at LOV released tab?

    Here is my code:

    < af:inputListOfValues id = "DepartmentNameId".

    popupTitle = "search and select: #{bindings." DepartmentName.hints.label}.

    value = "#{bindings." DepartmentName.inputValue}.

    label = "#{bindings." DepartmentName.hints.label}.

    model = ' #{bindings. " Required to DepartmentName.listOfValuesModel'} = 'true '.

    columns = "#{bindings." DepartmentName.hints.displayWidth}.

    shortDesc = "#{bindings." AutoSubmit DepartmentName.hints.tooltip}' = 'true '.

    contentStyle = "" text-align: left ""

    valueChangeListener = "#{DepartmentInfoListener.setNestNumValue}" >

    < f: validator binding = "#{bindings." DepartmentName.validator} "/ >"

    < af:convertNumber groupingUsed = 'false' pattern = ' #{bindings. " DepartmentName.format} "/ >"

    < / af:inputListOfValues >

    the value is always set to the value of the LOV first.

    This is usually related to missing key (or wrong) in display used by LOV object.

    Dario

  • Find the exact need in oracle support site

    Hi all

    Oracle support is very complex to find the exact needs.

    Suppose I want to download FMW 11 GR 2 version 11.1.2.0.0 forms and reports

    I'm wonder how to find and download?

    kindly help.

    Hello

    Check this link MOS!
    -Asking the physical URL send or download software Media [ID 1071023.1]

    Kind regards

  • How to debug and find the exact constraint violation error

    {14:22:36:ErrorCode 122712 - 1 with ErrorMessage as ORA-00001: unique constraint (OPS$ CMS.)} {PK_TB_ML_EXER_UPLOAD) violated appeared [SSO16063259009], pk_xop_subsales.pr_process_exer [CMSCOST_USER]}

    {Pr_process_exer (PROCEDURE)
    p_voucher_num tb_xop_order_manager_t.voucher_num%TYPE,
    p_status_type tb_xop_order_manager_t.status_type%type,
    p_dest tb_xop_order_manager_t.dest%type,
    p_reference_key tb_xop_order_manager_t.reference_key%type,
    p_seq_num tb_xop_order_manager_t.seq_num%type,
    p_return_code tb_xop_order_manager_t.return_code%type,
    p_reason_desc tb_xop_order_manager_t.reason_desc%type,
    p_activity_qty tb_xop_order_manager_t.activity_qty%type,
    p_leaves_qty tb_xop_order_manager_t.leaves_qty%type,
    p_exec_price tb_xop_order_manager_t.exec_price%type,
    p_current_status tb_xop_order_manager_t.current_status%type,
    p_err_cur ON ref_cursor)
    IS
    CURSOR get_order_dtls (v_voucher_num tb_xop_order_manager_t.voucher_num%type)
    IS
    SELECT *.
    OF tb_xop_order_manager_t
    WHERE voucher_num = v_voucher_num;

    CURSOR get_mail_cd (v_opt_num OPTIONEE.opt_num%TYPE) IS
    SELECT mail_cd, sp_mail_cd
    OF XOP_OPTIONEE
    WHERE opt_num = v_opt_num;

    cursor get_opt_dtls (v_opt_num OPTIONEE.opt_num%TYPE) IS
    Select
    SUBSTR (Trim (O.name_first) |) ' ' || Trim (O.name_mi) | ' ' ||
    Trim (O.name_last), 1: 35) p_name,.
    SUBSTR (O.address1, 1, 35) opt_addr1,.
    SUBSTR (O.address2, 1, 35) opt_addr2,.
    SUBSTR (O.address3, 1, 35) opt_addr3,.
    SUBSTR (O.address4, 1, 35) opt_addr4,.
    SUBSTR (O.address5, 1, 35) opt_addr5,.
    SUBSTR (O.address6, 1, 35) opt_addr6,.
    SUBSTR (Trim (O.City) |) ' ' || Trim (O.State) | ' ' ||
    Trim (O.zip) | ' ' || Trim (O.Country), 1: 35) city_state_zip_country,.
    Trim town (O.City),
    Trim (O.State) State,
    Trim (O.zip) zip,
    Trim (O.Country) countries
    of the option o holder
    where o.opt_num = v_opt_num;
    -CQ: PCTUP00210726 - added wire instructions audit for info thread deleted.
    CURSOR (c_wire_instruction)
    in_wire_seq_no TB_XOP_WIRE_INSTRUCTIONS.wire_seq_no%TYPE) IS
    SELECT ml_brok_acct_num,
    SSN,
    plan_num,
    instr_type,
    aba_routing_num,
    swift_routing_code,
    bank_name,
    bank_acct_num,
    name_on_account,
    bank_addr_1,
    bank_addr_2,
    bank_addr_3,
    City,
    State,
    countries,
    zip,
    bank_ident_num,
    addtl_info
    OF TB_XOP_WIRE_INSTRUCTIONS
    WHERE wire_seq_no = in_wire_seq_no
    UNION
    SELECT ml_brok_acct_num,
    SSN,
    plan_num,
    instr_type,
    aba_routing_num,
    swift_routing_code,
    bank_name,
    bank_acct_num,
    name_on_account,
    bank_addr_1,
    bank_addr_2,
    bank_addr_3,
    City,
    State,
    countries,
    zip,
    bank_ident_num,
    addtl_info
    OF TB_XOP_WIRE_INSTRUCTIONS_AUDIT
    WHERE wire_seq_no = in_wire_seq_no;

    CURSOR c_order_qty IS
    SELECT order_qty
    OF tb_xop_order_manager
    WHERE voucher_num = p_voucher_num;
    v_order_qty tb_xop_order_manager.order_qty%TYPE;

    v_wire_instruction c_wire_instruction % ROWTYPE;
    v_order_dtls get_order_dtls % rowtype;
    v_opt_dtls get_opt_dtls % rowtype;
    v_settle_dt tb_ml_exer_upload.settle_dt%type;
    v_cusip_num corp.cusip_num%type;
    number of v_err_cd (12): = 0;
    v_err_msg varchar2 (4000);
    v_compy_nme tb_fc_Compy.compy_nme%type;
    v_ml_sec_num tb_fc_compy.ml_sec_num%type;
    v_mail_cd xop_optionee.mail_cd%type;
    v_count1 PLS_INTEGER: = 0;
    v_sum_activity_qty tb_xop_order_manager_t.activity_qty%TYPE;
    v_transact_no PLS_INTEGER;

    v_ivr_plan_num tb_fc_compy.ivr_plan_num%TYPE;

    wait_for_more EXCEPTION;
    exceeds_order_qty EXCEPTION;
    -Added CQ # PCTUP00481233
    number of v_sub_totfee;
    number of v_sub_fixedfee1;
    number of v_sub_fixedfee2;
    number of v_sub_fixedfee3;
    number of v_sub_secfee;
    number of v_sub_feenum;
    -Added CQ # PCTUP00481233
    v_fixedfee1 tb_xop_order_manager_t.fixed_fee1%TYPE; -SPIF # 43161 - variable to contain the fixed mensuels1

    BEGIN

    OPEN c_order_qty.
    SEEK c_order_qty INTO v_order_qty;
    CLOSE C_order_qty;
    DBMS.output.put_line ('completed1');
    IF v_order_qty <>p_activity_qty THEN
    DBMS.output.put_line ('completed2');
    IF p_status_type = "EO" AND v_order_qty < p_activity_qty THEN
    RAISE exceeds_order_qty;
    DBMS.output.put_line ('completed3');
    ELSIF p_status_type = 'EO' AND v_order_qty > p_activity_qty THEN
    -Partial enforcement
    INSERT INTO tb_xop_hold_multi_orders
    (voucher_num
    reference_key
    seq_num
    return_code
    reason_desc
    status_type
    activity_qty
    leaves_qty
    exec_price
    current_status
    waiting
    activ_dt)
    VALUES
    (p_voucher_num
    p_reference_key
    p_seq_num
    p_return_code
    p_reason_desc
    p_status_type
    p_activity_qty
    p_leaves_qty
    p_exec_price
    p_current_status
    , 'Y'
    SYSTIMESTAMP);
    DBMS.output.put_line ('completed4');
    ON THE OTHER
    IF p_status_type = "BE" THEN
    SELECT COUNT (1) IN v_count1
    OF tb_xop_hold_multi_orders
    WHERE voucher_num = p_voucher_num;
    DBMS.output.put_line ('completed5');
    IF v_count1 > 0 THEN
    INSERT INTO tb_xop_hold_multi_orders
    (voucher_num
    reference_key
    seq_num
    return_code
    reason_desc
    status_type
    activity_qty
    leaves_qty
    exec_price
    current_status
    waiting
    activ_dt)
    VALUES
    (p_voucher_num
    p_reference_key
    p_seq_num
    p_return_code
    p_reason_desc
    p_status_type
    , (-1) * p_activity_qty
    p_leaves_qty
    p_exec_price
    p_current_status
    , 'Y'
    SYSTIMESTAMP);
    UPDATE tb_xop_hold_multi_orders
    QUEUE = 'Y '.
    WHERE voucher_num = p_voucher_num;
    DBMS.output.put_line ('completed6');
    END IF;
    END IF;
    END IF;
    DBMS.output.put_line ('completed7');
    SELECT SUM (NVL(activity_qty,0)) IN the v_sum_activity_qty
    OF tb_xop_hold_multi_orders
    When pending = 'Y '.
    AND voucher_num = p_voucher_num;

    IF v_sum_activity_qty > 0 THEN
    IF v_sum_activity_qty <>v_order_qty THEN
    RAISE wait_for_more;
    ON THE OTHER
    -final order in the case of partial performance; complete the process
    UPDATE tb_xop_hold_multi_orders
    PUT on hold = ' don't
    process_dt = SYSDATE
    WHERE voucher_num = p_voucher_num;
    END IF;
    END IF;
    END IF;

    UPDATE tb_xop_order_manager_t
    SET activ_dt = TO_CHAR (SYSDATE, "YYYY-MM-DD HH24:MI:SS") | '. 000'
    dest = p_dest
    reference_key = p_reference_key,
    seq_num = p_seq_num
    return_code = p_return_code
    reason_desc = p_reason_desc,
    status_type = p_status_type
    , activity_qty = v_order_qty - p_activity_qty
    , leaves_qty = 0 - p_leaves_qty
    exec_price = p_exec_price,
    WHERE voucher_num = p_voucher_num;
    DBMS.output.put_line ('completed8');
    /*
    * SPIF # 43161 - update of the current situation to the PO moved to the end, even in works of the PROD.
    */

    IF (p_status_type = "EO") THEN

    BEGIN
    Select cusip_num
    in v_cusip_num
    Corp;
    EXCEPTION
    WHEN NO_DATA_FOUND THEN
    SELECT cusip_num
    IN v_cusip_num
    OF tb_xop_espp_compy
    WHERE compy_acronym = replace (replace(user,'CMS'), '_USER');
    WHILE OTHERS THEN
    NULL;
    END;

    Select compy_nme, ml_sec_num, ivr_plan_num
    in v_compy_nme, v_ml_sec_num, v_ivr_plan_num
    of tb_fc_compy
    where compy_acronym = replace (replace(user,'CMS'), '_USER')
    UNION ALL
    Select compy_nme, je_ml_security_number, ivr_plan_num
    of tb_xop_espp_compy
    where compy_acronym = replace (replace(user,'CMS'), '_USER');
    -where ivr_plan_num = replace (substr(p_voucher_num,1,7), 'NORTH', 'XOP');

    Open get_order_dtls (p_voucher_num);
    SEEK get_order_dtls INTO v_order_dtls;

    v_settle_dt: = fn_xop_bankopen_bizday (TRUNC (v_order_dtls.exer_date + 1));
    v_settle_dt: = fn_xop_bankopen_bizday (TRUNC (v_settle_dt + 1));
    v_settle_dt: = fn_xop_bankopen_bizday (TRUNC (v_settle_dt + 1));

    FOR c_mail_cd IN get_mail_cd (v_order_dtls.opt_num)
    LOOP
    v_mail_cd: = c_mail_cd.mail_cd;
    -We need get sp_mail_cd and overlay with the sp_mail_cd in order_manager_t?
    END LOOP;

    OPEN get_opt_dtls (v_order_dtls.opt_num);
    SEEK get_opt_dtls INTO v_opt_dtls;
    CLOSE Get_opt_dtls;

    v_fixedfee1: = nvl (v_order_dtls.fixed_fee1, 0);
    /*
    * SPIF # 43161 - at least one transaction per day fees
    */
    v_fixedfee1: = pk_xop_enh_exerupdate.chrg_tranxfixed_fee (v_fixedfee1,
    v_order_dtls. Symbol,
    v_order_dtls.corp_acronym,
    v_order_dtls.opt_num);
    -Insert in tb_ml_exer_upload
    -Added CQ # PCTUP00481233
    Pk_Xop_Transactmodel.GET_FEE (v_order_dtls. GROUP_ID, v_order_dtls. SVC_ID, 'SQ', v_order_dtls.opts_exer,
    round (v_order_dtls.exec_price, 4), v_sub_totfee, v_sub_fixedfee2, v_sub_fixedfee1,.
    v_sub_fixedfee3, v_sub_secfee, v_sub_feenum, LPAD (v_order_dtls. SSN, 9, 0));
    v_order_dtls.sec_fee: = v_sub_secfee;
    UPDATE tb_xop_order_manager_t
    SET sec_fee = v_sub_secfee
    WHERE voucher_num = p_voucher_num;

    DBMS.output.put_line ('completed8');
    -End CQ # PCTUP00481233
    INSERT INTO tb_ml_exer_upload
    (exer_num, exer_seq,
    exer_dt, written_flag, backout_flag, output_line,
    je_flag, opts_exer,
    tot_tax, shrs_sold, comm_value, tot_fee,
    mkt_prc, exer_type, soc_sec,
    name_first, name_mi,
    name_last, check_addr_1, check_addr_2, check_addr_3,
    check_addr_4, check_addr_5, city, state, zip, country,.
    city_state_zip_country,
    p_name, opt_addr1, opt_addr2, opt_addr3, opt_addr4,
    opt_addr5, opt_addr6,
    settle_dt, send_to_citibank_flag,
    dom_chek_distr, foreign_currency_code,
    distribution_method, wire_seq_no,
    cusip_num, ml_retail_account, multi_curr_handling_fee,
    ml_sec_num, corp_name, upd_optionee_addr,
    outbound_flag,-there are N
    corp_symbol, taxwire_approve,-not make applicaplabe
    exersource,
    mail_cd, sp_mail_cd,
    backup_withholding,
    user_id,
    acct_num_othr)
    VALUES (v_order_dtls.exer_num, 0, v_order_dtls.exer_date, 'No', not, NULL,)
    -Would be PG 12/12/05 Changed to fill the resulting je_flag of dom_chek_distr',.
    -PG 16/12/05 I should not be generated for international controls... If 'Y' always
    'Y',-je_flag
    v_order_dtls.opts_exer, 0,-total tax will be 0.
    v_order_dtls.opts_exer, shrs_sold,
    v_order_dtls.comm_value,
    -SPIF # 43161 - replaced nvl (v_order_dtls.fixed_fee1, 0), with v_fixedfee1
    v_fixedfee1 + nvl(v_order_dtls.fixed_fee3,0) + nvl(v_order_dtls.sec_fee,0), - v_order_dtls.fees_amt,
    round (v_order_dtls.exec_price, 4), v_order_dtls.exer_type.
    LPAD (v_order_dtls. SSN, 9, '0'),-v_order_dtls.ssn, modified by Suresh on 08/02/07 for SPIF # 37210
    v_order_dtls.name_first, v_order_dtls.name_mi, v_order_dtls.name_last,
    v_order_dtls.check_addr_1, v_order_dtls.check_addr_2, v_order_dtls.check_addr_3,
    v_order_dtls.check_addr_4, v_order_dtls.check_addr_5, NVL (v_order_dtls. City, v_opt_dtls. (City),
    NVL (v_order_dtls. State, v_opt_dtls. State), NVL (v_order_dtls.zip, v_opt_dtls.zip).
    NVL (v_order_dtls. Country, v_opt_dtls. (Country),
    SUBSTR (nvl (v_order_dtls.city | v_order_dtls.)) State | v_order_dtls.zip | v_order_dtls. Country,
    v_opt_dtls.city_state_zip_country), 1: 34),-COLUMN LENGTH MAX IS 35
    v_opt_dtls.p_name, v_opt_dtls.opt_addr1, v_opt_dtls.opt_addr2, v_opt_dtls.opt_addr3,
    v_opt_dtls.opt_addr4, v_opt_dtls.opt_addr5, v_opt_dtls.opt_addr6,
    v_settle_dt, Decode(v_order_dtls.distribution_method,'W','Y','D','Y','C','Y','D'),
    v_order_dtls.dom_chek_distr, v_order_dtls.foreign_currency_code,
    v_order_dtls.distribution_method, v_order_dtls.wire_seq_no,
    v_cusip_num, v_order_dtls.acct_num, v_order_dtls.multi_curr_handling_fee,
    -nvl (fn_get_sec_num (replace (substr (p_voucher_num, 1, 7), 'NORTH', 'XOP'), v_order_dtls.symbol), v_ml_sec_num).
    NVL (fn_get_sec_num (v_ivr_plan_num, v_order_dtls.symbol), v_ml_sec_num).
    v_compy_nme, v_order_dtls.upd_optionee_addr,
    'N'-' is for outgoing flag.
    v_order_dtls. Symbol, 'd', --a ' for disabled taxwires
    The of ', - the of ' source being a subsequent sale.
    v_mail_cd, need to get mail_Cd?
    v_order_dtls.sp_mail_cd, v_order_dtls.backup_withholding,
    (User, v_order_dtls.acct_num_othr);

    IF (NVL(v_order_dtls.wire_seq_no,0) > 0) THEN

    OPEN c_wire_instruction (v_order_dtls.wire_seq_no);
    SEEK c_wire_instruction INTO v_wire_instruction;
    CLOSE C_wire_instruction;

    INSERT INTO TB_XOP_TRANSACT_WIRE_INSTR
    (user_id, exer_num, wire_seq_no, ml_brok_acct_num, ssn,
    plan_num, instr_type, aba_routing_num,
    swift_routing_code, bank_name, bank_acct_num,
    name_on_account, bank_addr_1, bank_addr_2, bank_addr_3,
    City, State, country, zip, bank_ident_num, addtl_info)
    VALUES
    (USER, v_order_dtls.exer_num, v_order_dtls.wire_seq_no,
    v_wire_instruction.ml_brok_acct_num, v_wire_instruction.ssn,
    v_wire_instruction.plan_num, v_wire_instruction.instr_type, v_wire_instruction.aba_routing_num,
    v_wire_instruction.swift_routing_code, v_wire_instruction.bank_name, v_wire_instruction.bank_acct_num,
    v_wire_instruction.name_on_account, v_wire_instruction.bank_addr_1, v_wire_instruction.bank_addr_2,
    v_wire_instruction.bank_addr_3, v_wire_instruction.city, v_wire_instruction.state, v_wire_instruction.country, v_wire_instruction.zip,
    (v_wire_instruction.bank_ident_num, v_wire_instruction.addtl_info);
    DBMS.output.put_line ('completed10');
    END IF;


    / * PG 05/01/06 call conversion check only for international controls and son * /.
    IF = v_order_dtls.dom_chek_distr ' n AND v_order_dtls.distribution_method IN ('W' ' d ","C"" ") THEN
    / * PG 20/12/05 to treat the subsequent sales with the wire or the distribution of currency * /.
    v_transact_no: = 88;
    pk_xop_citibank_forex.pr_cashconversion_ins_request (v_order_dtls.acct_num
    LPAD(v_order_dtls.ssn,9,'0') - v_order_dtls.ssn, modified by Suresh on 15/02/07 for SPIF # 37210
    v_order_dtls.distribution_method
    v_order_dtls.foreign_currency_code
    v_order_dtls.wire_seq_no
    , TOWER ((v_order_dtls.opts_exer * ronds (v_order_dtls.exec_price, 4)), 2)
    -ROUND(v_order_dtls.comm_value,2)
    -ROUND (nvl(v_order_dtls.fixed_fee1,0) + nvl(v_order_dtls.fixed_fee3,0) + nvl(v_order_dtls.sec_fee,0), 2)
    -nvl(v_order_dtls.multi_curr_handling_fee,0)
    -product net nvl(v_order_dtls.backup_withholding,0)-
    , v_order_dtls.multi_curr_handling_fee - handling fee
    -Modified by Billon/Suresh on 03/02/2006-, v_order_dtls.login_name
    , CASE v_order_dtls.login_name WHEN ' CUSTOMER /' THEN v_order_dtls.login_name |' SSO' ELSE v_order_dtls.login_name |' / SSO' END
    , v_transact_no - transact_no as a placeholder for the 88 exer_type
    v_order_dtls.check_addr_1
    v_order_dtls.check_addr_2
    v_order_dtls.check_addr_3
    v_order_dtls.check_addr_4
    v_order_dtls.upd_optionee_addr
    v_order_dtls.city
    v_order_dtls.state
    v_order_dtls.zip
    v_order_dtls.country
    v_order_dtls.login_ipaddress
    v_order_dtls.fcnum
    v_order_dtls.opt_num
    v_settle_dt,
    p_exer_num = > v_order_dtls.exer_num
    );
    END IF;

    COMMIT;

    close get_order_dtls;

    END IF;

    /*
    * SPIF # 43161 - update of current status in IN. is moved to this part, even PROD.
    */
    UPDATE tb_xop_order_manager_t
    SET exec_dttime = decode (p_status_type, "EO", to_char (sysdate, 'DD-MON-YYYY HH24:mi:ss'), null)
    exer_date = trunc (sysdate)
    , cancel_dttime = decode (p_status_type, 'CX', to_char (sysdate, 'DD-MON-YYYY HH24:mi:ss'), 'UR', to_char (sysdate, "MON-DD-YYYY HH24:mi:ss), null)
    , current_status = "PO."
    sum_status = decode(p_status_type,'EO','X','C'),
    sum_stat_dttime = SYSDATE
    WHERE voucher_num = p_voucher_num;

    v_err_cd: = sqlcode;
    v_err_msg: = sqlerrm;

    Open the p_err_cur for v_err_cd select err_code, v_err_msg err_msg double;

    EXCEPTION
    DBMS.output.put_line ('completed200');
    / * PG 02/10 managed 'order of partial fill' exception * /.
    When wait_for_more then
    v_err_cd: = 0;
    v_err_msg: = ' ORA-0000: normal completion, successfully ';
    pr_xop_log_errors (' partially filled;) Pending-activity qty:' | TO_CHAR (v_sum_activity_qty) | "pk_xop_subsales.pr_process_exer");
    Open the p_err_cur for v_err_cd select err_code, v_err_msg err_msg double;
    When exceeds_order_qty then
    v_err_cd: = sqlcode;
    v_err_msg: = sqlerrm;
    Open the p_err_cur for v_err_cd select err_code, v_err_msg err_msg double;
    pr_xop_log_errors ("exceeded the amount of activity Order_qty - activity qty: ' | ') TO_CHAR (p_activity_qty) | "pk_xop_subsales.pr_process_exer");
    while others then
    v_err_cd: = sqlcode;
    v_err_msg: = sqlerrm;
    Open the p_err_cur for v_err_cd select err_code, v_err_msg err_msg double;
    pr_xop_log_errors (' error code ' | ') SQLCODE |' with ErrorMessage like ' | SQLERRM |' occurred '. the user | (' pk_xop_subsales.pr_process_exer');
    DBMS.output.put_line ('completed125');
    END pr_process_exer;
    }

    Hi friends, any1 help me how set ref-cursor in the declaration section and how to find the constraint error situation has occurred...

    956684 wrote:
    Hello.

    Friends please help... How to debug and find the exact position of the constraint violation... Thank you for the help...

    It's not a way to track it unless you have taken the exception raised.

    As a way to start debugging, you will need to monitor
    1. all DML against the Table on which you have constraint. Specifically, the DML that Act on the column you will be forced.
    2. use the exception handling, to record the error and the data that causes the constraint to fail.
    3. don't forget to monitor triggers, if used, could write data in the column you have forced on.

    Or

    Another track is to:

    select *
      from user_source
    where lower(text) like '%your_table_name%';
    order by type, name, line;
    

    Look at the lines, exclude that are in the statement or in the SELECT statements and targets of the DML.

    Looking at the unformatted code, that you have published, this statement looks like a culprit.

    INSERT INTO tb_ml_exer_upload
    (exer_num,exer_seq,
    exer_dt, written_flag, backout_flag, output_line,
    je_flag, opts_exer,
    tot_tax,shrs_sold,comm_value,tot_fee,
    mkt_prc,exer_type, soc_sec,
    name_first, name_mi,
    name_last,check_addr_1,check_addr_2,check_addr_3,
    check_addr_4,check_addr_5,city,state,zip,country,
    city_state_zip_country,
    p_name,opt_addr1,opt_addr2,opt_addr3,opt_addr4,
    opt_addr5,opt_addr6,
    settle_dt,send_to_citibank_flag,
    dom_chek_distr,foreign_currency_code,
    distribution_method,wire_seq_no,
    cusip_num, ml_retail_account,multi_curr_handling_fee,
    ml_sec_num, corp_name,upd_optionee_addr,
    outbound_flag, -- make it N
    corp_symbol,taxwire_approve, -- make it not applicaplabe
    exersource,
    mail_cd, sp_mail_cd,
    backup_withholding,
    user_id,
    acct_num_othr)
    VALUES(v_order_dtls.exer_num,0,v_order_dtls.exer_date,'N','N',NULL,
    -- PG 12/12/05 Changed to populate the je_flag based on dom_chek_distr 'D',
    -- PG 12/16/05 JE should not be generated for international checks.. So 'Y' always
    'Y', --je_flag
    v_order_dtls.opts_exer,0,--total tax will be 0.
    v_order_dtls.opts_exer, --shrs_sold,
    v_order_dtls.comm_value,
    --SPIF# 43161- replaced nvl(v_order_dtls.fixed_fee1, 0) with v_fixedfee1
    v_fixedfee1 + nvl(v_order_dtls.fixed_fee3,0) + nvl(v_order_dtls.sec_fee,0), --v_order_dtls.fees_amt,
    round(v_order_dtls.exec_price, 4),v_order_dtls.exer_type,
    LPAD(v_order_dtls.ssn,9,'0'), --v_order_dtls.ssn, Modified by Suresh on 02/08/07 for SPIF # 37210
    v_order_dtls.name_first,v_order_dtls.name_mi,v_order_dtls.name_last,
    v_order_dtls.check_addr_1,v_order_dtls.check_addr_2,v_order_dtls.check_addr_3,
    v_order_dtls.check_addr_4,v_order_dtls.check_addr_5,nvl(v_order_dtls.city,v_opt_dtls.city),
    nvl(v_order_dtls.state,v_opt_dtls.state),nvl(v_order_dtls.zip,v_opt_dtls.zip),
    nvl(v_order_dtls.country,v_opt_dtls.country),
    SUBSTR(nvl(v_order_dtls.city||v_order_dtls.state||v_order_dtls.zip||v_order_dtls.country,
    v_opt_dtls.city_state_zip_country),1,34), -- COLUMN LENGTH MAX IS 35
    v_opt_dtls.p_name,v_opt_dtls.opt_addr1,v_opt_dtls.opt_addr2,v_opt_dtls.opt_addr3,
    v_opt_dtls.opt_addr4,v_opt_dtls.opt_addr5,v_opt_dtls.opt_addr6,
    v_settle_dt,decode(v_order_dtls.distribution_method,'W','Y','D','Y','C','Y','D'),
    v_order_dtls.dom_chek_distr,v_order_dtls.foreign_currency_code,
    v_order_dtls.distribution_method,v_order_dtls.wire_seq_no,
    v_cusip_num,v_order_dtls.acct_num,v_order_dtls.multi_curr_handling_fee,
    -- nvl(fn_get_sec_num(replace(substr(p_voucher_num,1,7),'SSO','XOP'),v_order_dtls.symbol),v_ml_sec_num),
    nvl(fn_get_sec_num(v_ivr_plan_num, v_order_dtls.symbol),v_ml_sec_num),
    v_compy_nme,v_order_dtls.upd_optionee_addr,
    'N', --'N' is for outbound flag.
    v_order_dtls.symbol,'D', --'D' for taxwires disabled
    'S', -- 'S' for source being subsequent sale.
    v_mail_cd, --need to get mail_Cd??
    v_order_dtls.sp_mail_cd,v_order_dtls.backup_withholding,
    user,v_order_dtls.acct_num_othr);
    

    What is the structure of the tb_ml_exer_upload Table and the columns do you have constraints?
    Which column of the tb_ml_exer_upload table is your primary key (because the constraint name mentions pk_tb_ml_exer_upload)?

    Published by: Jen K on January 4, 2013 12:57

  • Exact match on the top of the list

    Hi all

    I have a list as ArrayList < user > where class user contains some fields such as firstname, lastname, and userID.
    Given a string of so-called search "searchString", I need to sort the list in a way that fits RIGHT in the list ON the fields firstname, lastname or userID comes on top and then the other. All entries already satisfied the criteria of partial matching. Just need to get exact matches on top of the list

    Example: If an ArrayList < user > contains {{' hominder', 'kumar', 'lpppp'}, {"leethom", "chuu', 'lpppx'}, {'thomas', 'dorothy', 'lxoxp'}, {'paul', 'meyer', 'thomyg'}, {"hom","jones","lwppp"}, {"susana","men","phpfa"}}
    where {'ajay', 'kumar', 'lpppp'} is firstname, lastname and userID of the user, respectively.

    {In this case if searchString = "hom", I should get {"hom", "jones", "lwppp"} and {"susana", "men", "phpfa"}} at the top of the list because they are exact matches. Kindly let me know in an effective way of TIME to do this because my site traffic is good and most of them are managers. Any help is very appreciated.

    Simply remove it and then insert it in the front. A LinkedList would be much more effective at this.

  • Find the exact model for ThinkPad Edge number?

    I have difficulties to find which exact model of thinkpad edge I. No idea how I can know exactly which model I have?

    Here you go:

    ThinkPad Edge 15 (0301-GZM)
    I3 - 380M (2 .53GHz) 2 GB RAM 320 GB 5400 RPM HD 15.6 in. 1366 x 768 LCD Intel HD Graphics CDRW/DVD-RW
    802.11bgn wireless Bluetooth 1 Gb Ethernet, UltraNav camera 6 c Li-ion Win7 Home Premium 64

    Kind regards.

  • How to get an exact match

    How do you get a SELECT statement to search for an exact match in the string comparison?

    For example, SELECT name FROM table WHERE name = 'Jim '.

    Returns the records even if the field name is "JIM." I need an exact match. IM using MS Access for the database

    MS Access has a StrComp function which may help you to do this.

    http://support.Microsoft.com/kb/209674
    http://support.Microsoft.com/kb/244693

  • How to find the exact model of the unit number

    Hello... On the back of this laptop, it has the following > HP Pavilion dv6000... s/n: CNF7131P0Q... p/n: GA218UA # ABL... It has Windows Vista Home Premium OEMAct HP.

    I hope someone can tell me the exact model number, because I noticed on the HP Web site their right to dv6000xxx more, but all I see is dv6000

    Thank you

    HP Pavilion DV6308 AMD Turion 64 X 2 TL - 50 1.6 GHz 1 GB 120 GB DVD±R 15.4 "WXGA LAN Firewire GeForce Go 6150 XP PRO sp3
    Laptop HP Pavilion dv6308ca... p/n: GA218UA #ABL

    Hello:

    No, you have a dv6308 as I posted above.

    I gave you the page for the drivers off the dv6000 CTO because there all drivers XP and your were only a couple. Yours came with Vista, I guess.

    Yes, the laptop can run a 64-bit operating system but I would install Vista or Windows 7 x 64 because it can be very difficult to find XP x 64 drivers for it.

    I do not work for HP. I like just to help people with their PC.

    It's the support page and drivers for your specific laptop:

    http://h10025.www1.HP.com/ewfrf/wc/product?product=3379135&LC=en&cc=us&DLC=en&task=&lang=en&cc=us

    One man trash is treasure of another man, I always say.  Good find!

    Paul

  • Find the exact index of maximum PNo() local and ChnFind() seem to be problematic

    Good day to all experts DIAdem!

    I am after some help and wonder if what I intend to do is possible, as much as tiara fucntions are concerned.

    I have a few cyclical data (continuous acquired as a set of data), which I am able to identify individual events. Within each of these events, I use the StatBlockCalc, so calculate the minimum and maximum local power (in the range of the specified index). I would then use the calculated maximum, a specific channel, then 'read' effective competition on other channels.

    I tried to use the ChnFind and PNo and both give results that often fall beyond the top and bottom of the index for this event. I believe that this is due to the fact that these search functions for a nearest value of the value in question and NOT the exact value for (rounding errors may also play a role). Please note this is not a criticism of the functions, because I believe that what I am asking is perhaps more by the high-performance computing (as opposed to hunting for the nearest value).

    So my question is - this feasible? To calculate a local maximum, and then use this value index reading on the remaining channels (to determine the values to the maximum).

    I hope that what I am asking is clear, if not so, feel free to ask away.

    Kind regards

    Dan

    Hi Dan,.

    If you want to attack this from the rounded side error, then I suggest to insert the ValEqual() function in your search expression - it has been designed to avoid rounding problems you seem like you're running.  My other recommendataion would be to abandon PNo() and use instead of ChnFind() with the known since your window index the starting index.  This action runs more quickly and find the extremum of right.

    Brad Turpin

    Tiara Product Support Engineer

    National Instruments

  • Try to find the exact model of the serial number. Presario 6000 series

    Have the serial number for a desktop computer compact presario 6000 series.  You will find exactly what model number, it is.  Tags are not on the computer windows only certificate.

    Hello

    Please, do not repeat your queries

    Concerning

  • I had things on my Mac for a long time and have never been able to find out exactly what I co

    I got Elements 3.0 on my Mac for a long time and have never been able to know exactly what I could do with it. It doesn't seem to be a manual in my file and I can't find anything on line.

    I have now had time to work on improving and using various features on the pictures, so want to use items.

    Can you tell me how to get a manual for this or any version.

    I have a number "about Photo Shop Elements' 1057020118662274822.

    Thank you. Jeff Sowers

    better late than never: http://home.comcast.net/~themark/PhotoshopElements/Getting%20Started%20Guide.pdf

  • R12 - how to find the exact form, report, and Web Server Version

    Hi DBAs,


    How can I find the version of web server, report and exact form in environments of R12.

    Thank you
    -Samar-

    If you're on 11i, pl see MOS Doc 466890.1 (Script to find the Apache, Java, Jinitiator, version of forms and details of the JVM for Oracle E-Business Suite 11i)

    For R12, see Doc 468311.1 (Script to find the Apache, Java, JRE, Forms for Oracle E-Business Suite R12 version)

    HTH
    Srini

Maybe you are looking for

  • I have my contacts in an Outlook pst file. How to import the address book?

    I am in the process of setting up on a new that old laptop just died. I use Thunderbird for the first time that the cost of Outlook for Windows 8 is too high. I have the Pst file restored from my backup hard drive to the new laptop back

  • Portege 3500: missing system32 - update the BIOS?

    Hello world I got a Portege 3500 PIII-M 1.33 GHz, which has been infected by a virus. I tried to reinstall Windows Xp, but the SYSTEM32 file is missing or damaged. I downloaded the BIOS driver and tried to install it via an external CD drive, but it

  • Unable to connect sony vaio E series widows 7 laptop for Wi FI.

    I might have accidentally uninstalled a program. Have not been able to connect my laptop to wireless internet. Although my ipad to connect. Can someone tell me what program is required and where I can find it? Or can there be another problem? TNX

  • USB 3.0 on desktop release

    When HP released USB 3.0 on desktop computers?

  • computer laptop 10 h 00

    When I go to my company's site. so try different curiosities here it happens that the type of browser and the version is MSIE 1 and I need SHCM to proceed.  It doesn, t except my browser windows 8 10.0, but my office works very well it?