Rollback in a Package specification

Hello

Is there any logical situation when point rollback of record is used in the package specification? If so, please explain the situation with examples.

I0'ts as:

create or replace package pckg as

procedure (sth);

Service (sth);

Restore to the point of backup svpnt;

Procedure (smth);

end;

3065482 wrote:

Hello

Is there any logical situation when point rollback of record is used in the package specification? If so, please explain the situation with examples.

I0'ts as:

create or replace package pckg as

procedure (sth);

Service (sth);

Restore to the point of backup svpnt;

Procedure (smth);

end;

A package specification defines public types, variables, cursors and procedures available in the package etc.

The package specification itself does not contain executable code, that belongs in the package body.

Therefore, any logic to try to include a rollback statement in a package specification such that it will never be executed, even if you can get it to compile (that you won't)

Tags: Database

Similar Questions

  • Variable grouping in package specifications Initialiazing

    Hi Experts,

    I know this might be a basic question, here is my piece of code

    I have a variable declared as type data number and initialized to 10 g_number

    I have EMP_SAL_TAB which is a kind of data EMP_SAL that is defined on line 6.

    but am getting error when I try to initialize it in line 11.

    now, my query is why am getting error of initialization of the collection on line 11?  Sorry for a very basic question, but it is always good to clear a query.

    create or replace PACKAGE emp_sal AS
    g_salary_spec number;
       PROCEDURE find_sal(c_id emp.empno%type);
       FUNCTION CONCATE_NAMES (C_ID EMP.EMPNO%TYPE) RETURN VARCHAR2;
       
       type emp_sal is table of char(2) index by binary_integer;
       emp_sal_tab emp_sal;
       
       g_number number:=10;
       
       emp_sal_tab(1):= 100;
       
    END emp_sal;
    

    You can't write code in the package specification. An assignment statement is code.

    And associative arrays have NO constructors. See Oracle documentation on how the collections initialized.

    http://docs.Oracle.com/CD/E11882_01/AppDev.112/e25519/composites.htm#LNPLS00506

    This example shows that you can initialize a VARRAY

    Why you use a package for this variable?

    If you need to initialize an associative array it during initialization block the package body.

    http://docs.Oracle.com/CD/E11882_01/AppDev.112/e25519/packages.htm#LNPLS99926

  • How to put facilities in the trade and specifications of materials package specification?


    Hi support them.

    When BOM is imported in the ERP, one or more facilities are needed to define in the LES. Currently, only the specification of Formulation contains information of facilities. If the BOM contains information of Formulation, trade and specification of package of materials, how to define these facilities in trade and material package specifications? What is the best practice?

    Thank you.

    Terry

    You should use approvals of sourcing for the use case.   Facilitated the formulation information section is here so you can specify (x) manufacturing what is intended for the recipe for the site.

  • pls-00323: subprogram or cursor "Dec" is declared in the package specification

    Hello

    How to fix the error below
    pls-00323: subprogram or cursor 'Drec' is declared in package specification and must be defined in the package body
    in fact, my code is here

    Spec
    create or replace package x is
    
      type typ_x277  is record (
      rcncd fin_rcn_grp_mas.rcn_cd%type,
      icode item_master.item_code%type,
      idesc item_master.short_desc%type,
      ob_qty Number,
      rcpt_qty number,
      issue_qty number,
      incr_qty number,
      Rate number,
      incr_value number);
      
      type ref_x277 is ref cursor return typ_x277; 
      
      Procedure drec(x277_rec in out ref_x277,rcncd varchar,fdate date,tdate date);
    
    end x;
    body
    create or replace package body x is
    
    Procedure drec(x277_rec in out ref_x277,rcncd varchar2,fdate date,tdate date) as
    Begin
    open x277_rec for 
    Select rcn_cd,item_code,short_desc,op,rcpt,issu,incrqty,month_rate,incrqty*month_rate incrvalue
    from(
    Select rcn_cd,item_code,short_desc,find_item_opening(item_code,fdate) op,rcpt,issu,(find_item_opening(item_code,fdate)+rcpt) - issu incrqty,month_rate
    from(
    select rcn_cd,a.item_code,short_desc,month_rate,sum(nvl(mrir_qty,0)) Rcpt,sum(nvl(issue_qty,0)) issu
    from(
      select item_key,b.rcn_cd,mrir_ccn(a.po_no,a.item_code) as ccn,a.item_code,sum(a.quantity) as mrir_qty, null issue_qty 
        from kar a,fin b
        where trunc(a.document_date,'DD') between fdate and tdate and
              b.rcn_cd=rcncd and
              mrir_ccn(a.po_no,a.item_code)=b.ccn_cd and
              nvl(a.quantity,0) > 0 and
              a.card_code = '50'
        group by item_key,b.rcn_cd,mrir_ccn(a.po_no,a.item_code),a.item_code
        having sum(a.quantity) > 0
    union    
         select item_key,b.rcn_cd,a.ccn,a.item_code,null mrir_qty, sum(a.quantity) as issue_qty 
        from kardex a,fin_rcn_grp_mas b
        where trunc(a.document_date,'DD') between fdate and tdate and
              b.rcn_cd=rcncd and
              a.ccn=b.ccn_cd and
              nvl(a.quantity,0) > 0 and
              a.card_code in ('70','71','72')
        group by item_key,b.rcn_cd,a.ccn,a.item_code)a,
    item_master b,item_quantity c
    where a.item_code = b.item_code
    and a.item_key = b.item_key
    and a.item_key = c.item_key
    and b.item_key = c.item_key
    group by rcn_cd,a.item_code,short_desc,month_rate
    having sum(nvl(mrir_qty,0)) > 0
    order by rcpt desc,a.item_code));
    end;
    
    
    end x277;
    my spec is perfectly compiled where the body becomes the error said above.

    How to recover this question.

    Iqbal

    In spec you have this

    Procedure gillison (x277_rec in ref_x277, rcncd varchar, date, date of tdate fdate);

    In the body, you have this

    Procedure gillison (x277_rec in ref_x277, rcncd varchar2, date, date of tdate fdate) as

    for rcncd in spec its VARCHAR and the body its VARCHAR2. Change both to VARCHAR2

  • PLS-00323: subprogram or cursor is declared in a package specification and must be defined in the package body

    Hi all

    Please help me understand why I receive PLS-00323 error when my function exists in the header and body of the package.

    Please find below the source code.

    Maybe I should post more details here, please tell me what else should I show to get help.

    I tried to compile my drawing

    EXEC DBMS_UTILITY.compile_schema (pattern = > 'ZVIT');

    but still

    Select * from user_errors

    Returns

    NAME TYPE SEQUENCE LINE (LINE)

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

    TEXT

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

    ATTRIBUTE MESSAGE_NUMBER

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

    PACKAGE 2 8 12 PKG_PK8842_ACCNOTMOVE BODY

    PLS-00323: subprogram or cursor "ACCNOTMOVEFIZ" is declared in a specific package

    cation and must be defined in the package body

    ERROR 323

    PACKAGE 1 3 12 PKG_PK8842_ACCNOTMOVE BODY

    PLS-00323: subprogram or cursor "ACCNOTMOVEJUR" is declared in a specific package

    cation and must be defined in the package body

    ERROR 323

    2 selected lines.

    source code:

    CREATE OR REPLACE PACKAGE ZVIT. PKG_PK8842_AccNotMove

    AS

    FUNCTION AccNotMoveJUR)

    p_contragentId dwh_CR_contragent.ID%TYPE,

    p_date Date)

    RETURN number;

    FUNCTION AccNotMoveFIZ)

    p_contragentId dwh_CR_contragent.ID%TYPE,

    p_date Date)

    RETURN number;

    FUNCTION DtLastMove)

    p_Id B2_OLAP. DIMAACCOUNT_ALL.ID%TYPE)

    Date of RETURN;

    END;

    /

    CREATE OR REPLACE PACKAGE BODY ZVIT. PKG_PK8842_AccNotMove

    AS

    FUNCTION AccNotMoveJUR)

    p_contragentId zvit.dwh_CR_contragent.ID%TYPE,

    p_date Date)

    RETURN number

    IS

    l_Result Number (1);

    l_contragentId zvit.dwh_CR_contragent.ID%TYPE;

    l_dateopen Date;

    Date of l_dtMove1;

    Date of l_dtMove2;

    BEGIN

    l_Result: = 0;

    BEGIN

    Select Distinct a.contragentid

    In l_contragentId

    OF B2_OLAP. DIMAACCOUNT_ALL one

    where a.contragentid = p_contragentId

    and a.BACCOUNTID in (2600,2650)

    and a.ACCOUNTSTATEID not in (1,2);

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_contragentId: = NULL;

    END;

    IF l_contragentId IS NOT NULL THEN

    l_Result: = 0;

    ON THE OTHER

    BEGIN

    Select MAX (a.dateopen)

    In l_DateOpen

    OF B2_OLAP. DIMAACCOUNT_ALL one

    where a.contragentid = p_contragentId

    and a.BACCOUNTID in (2600,2650)

    and a.ACCOUNTSTATEID <>2

    and a.DateOpen > p_date;

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_DateOpen: = NULL;

    END;

    IF l_DateOpen IS NOT NULL THEN

    l_Result: = 0;

    ON THE OTHER

    BEGIN

    SELECT MAX (d.arcdate)

    In l_dtMove1

    OF B2_OLAP. DIMAACCOUNT_ALL has,

    B2_OLAP.AR_DOCUMENT d,

    B2_OLAP. DIMDOCUMENTTYPE dt

    WHERE a.contragentid = p_contragentId

    and a.BACCOUNTID in (2600,2650)

    and d.ACCOUNTBID = a.Id

    and d.arcdate > = p_date

    and d.DOCUMENTTYPEID = dt.id

    and dt. OPERATIONTYPEBYSUMMAID not to (2,3)

    and not in Substr (d.accountano, 1, 4) ('2608 ', ' 2658');

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_dtMove1: = NULL;

    END;

    IF l_dtMove1 IS NULL THEN

    BEGIN

    SELECT MAX (d.arcdate)

    In l_dtMove1

    OF B2_OLAP. DIMAACCOUNT_ALL has,

    B2_OLAP.AR_DOCUMENT d,

    B2_OLAP. DIMDOCUMENTTYPE dt

    WHERE a.contragentid = p_contragentId

    and a.BACCOUNTID in (2600,2650)

    and d.ACCOUNTBID = a.Id

    and d.arcdate > = p_date

    and d.DOCUMENTTYPEID = dt.id

    and dt. OPERATIONTYPEBYSUMMAID not to (2,3)

    and not in Substr (d.accountano, 1, 4) ('2608 ', ' 2658');

    - and d.DOCUMENTSTATEID = 2

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_dtMove1: = NULL;

    END;

    END IF;

    IF l_dtMove1 IS NULL THEN

    BEGIN

    SELECT MAX (d.arcdate)

    In l_dtMove1

    OF B2_OLAP. DIMAACCOUNT_ALL has,

    B2_OLAP.AR_DOCUMENT d,

    B2_OLAP. DIMDOCUMENTTYPE dt

    WHERE a.contragentid = p_contragentId

    and a.BACCOUNTID in (2600,2650)

    and d.ACCOUNTAID = a.Id

    and d.arcdate > = p_date

    and d.DOCUMENTTYPEID = dt.id

    and dt. OPERATIONTYPEBYSUMMAID not to (2,3);

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_dtMove1: = NULL;

    END;

    END IF;

    IF l_dtMove1 IS NULL THEN

    BEGIN

    SELECT MAX (d.arcdate)

    In l_dtMove1

    OF B2_OLAP. DIMAACCOUNT_ALL has,

    B2_OLAP.AR_DOCUMENT d,

    B2_OLAP. DIMDOCUMENTTYPE dt

    WHERE a.contragentid = p_contragentId

    and a.BACCOUNTID in (2600,2650)

    and d.arcdate > = p_date

    and d.ACCOUNTAID = a.Id

    and d.DOCUMENTTYPEID = dt.id

    and dt. OPERATIONTYPEBYSUMMAID not to (2,3);

    - and d.DOCUMENTSTATEID = 2

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_dtMove1: = NULL;

    END;

    END IF;

    IF l_dtMove1 IS NULL THEN

    l_Result: = 1;

    On the other

    l_Result: = 0;

    End If;

    END IF;

    END IF;

    RETURN l_Result;

    END AccNotMoveJUR;

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

    FUNCTION AccNotMoveFIZ)

    p_contragentId zvit.dwh_CR_contragent.ID%TYPE,

    p_date Date)

    RETURN number

    IS

    l_Result Number (1);

    l_contragentId zvit.dwh_CR_contragent.ID%TYPE;

    l_dateopen Date;

    Date of l_dtMove1;

    BEGIN

    l_Result: = 0;

    BEGIN

    Select Distinct a.contragentid

    In l_contragentId

    OF B2_OLAP. DIMAACCOUNT_ALL one

    where a.contragentid = p_contragentId

    and a.BACCOUNTID in (2620,2625)

    and a.ACCOUNTSTATEID not in (1,2);

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_contragentId: = NULL;

    END;

    IF l_contragentId IS NOT NULL THEN

    l_Result: = 0;

    ON THE OTHER

    BEGIN

    Select MAX (a.dateopen)

    In l_DateOpen

    OF B2_OLAP. DIMAACCOUNT_ALL one

    where a.contragentid = p_contragentId

    and a.BACCOUNTID in (2620,2625)

    and a.ACCOUNTSTATEID <>2

    and a.DateOpen > p_date;

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_DateOpen: = NULL;

    END;

    IF l_DateOpen IS NOT NULL THEN

    l_Result: = 0;

    ON THE OTHER

    BEGIN

    SELECT MAX (d.arcdate)

    In l_dtMove1

    OF B2_OLAP. DIMAACCOUNT_ALL has,

    B2_OLAP.AR_DOCUMENT d,

    B2_OLAP. DIMDOCUMENTTYPE dt

    WHERE a.contragentid = p_contragentId

    and a.BACCOUNTID in (2620,2625)

    and d.ACCOUNTBID = a.Id

    and d.arcdate > = p_date

    and d.DOCUMENTTYPEID = dt.id

    and dt. OPERATIONTYPEBYSUMMAID not to (2,3)

    and Substr(d.accountano,1,4) <>'2628';

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_dtMove1: = NULL;

    END;

    IF l_dtMove1 IS NULL THEN

    BEGIN

    SELECT MAX (d.arcdate)

    In l_dtMove1

    OF B2_OLAP. DIMAACCOUNT_ALL has,

    B2_OLAP.AR_DOCUMENT d,

    B2_OLAP. DIMDOCUMENTTYPE dt

    WHERE a.contragentid = p_contragentId

    and a.BACCOUNTID in (2620,2625)

    and d.arcdate > = p_date

    and d.ACCOUNTBID = a.Id

    and d.DOCUMENTTYPEID = dt.id

    and dt. OPERATIONTYPEBYSUMMAID not to (2,3)

    and Substr(d.accountano,1,4) <>'2628';

    - and d.DOCUMENTSTATEID = 2

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_dtMove1: = NULL;

    END;

    END IF;

    IF l_dtMove1 IS NULL THEN

    BEGIN

    SELECT MAX (d.arcdate)

    In l_dtMove1

    OF B2_OLAP. DIMAACCOUNT_ALL has,

    B2_OLAP.AR_DOCUMENT d,

    B2_OLAP. DIMDOCUMENTTYPE dt

    WHERE a.contragentid = p_contragentId

    and a.BACCOUNTID in (2620,2625)

    and d.ACCOUNTAID = a.Id

    and d.arcdate > = p_date

    and d.DOCUMENTTYPEID = dt.id

    and dt. OPERATIONTYPEBYSUMMAID not to (2,3);

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_dtMove1: = NULL;

    END;

    END IF;

    IF l_dtMove1 IS NULL THEN

    BEGIN

    SELECT MAX (d.arcdate)

    In l_dtMove1

    OF B2_OLAP. DIMAACCOUNT_ALL has,

    B2_OLAP.AR_DOCUMENT d,

    B2_OLAP. DIMDOCUMENTTYPE dt

    WHERE a.contragentid = p_contragentId

    and a.BACCOUNTID in (2620,2625)

    and d.arcdate > = p_date

    and d.ACCOUNTAID = a.Id

    and d.DOCUMENTTYPEID = dt.id

    and dt. OPERATIONTYPEBYSUMMAID not to (2,3);

    - and d.DOCUMENTSTATEID = 2

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_dtMove1: = NULL;

    END;

    END IF;

    IF l_dtMove1 IS NULL THEN

    l_Result: = 1;

    On the other

    l_Result: = 0;

    End If;

    END IF;

    END IF;

    RETURN l_Result;

    END AccNotMoveFIZ;

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

    FUNCTION DtLastMove)

    p_Id B2_OLAP. DIMAACCOUNT_ALL.ID%TYPE)

    Date of RETURN

    IS

    l_Result Date;

    Date of l_DtLast1;

    Date of l_DtLast2;

    Date of l_DtLast3;

    Date of l_DtLast4;

    BEGIN

    l_Result: = NULL;

    BEGIN

    SELECT MAX (d.arcdate)

    In l_DtLast1

    B2_OLAP.AR_DOCUMENT d,

    B2_OLAP. DIMDOCUMENTTYPE dt

    WHERE d.ACCOUNTBID = p_Id

    - and d.arcdate > = p_date

    and d.DOCUMENTTYPEID = dt.id

    and dt. OPERATIONTYPEBYSUMMAID not to (2,3)

    and Substr (d.accountano, 1, 4) not in ('2608', ' 2658 ', ' 2628');

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_DtLast1: = NULL;

    END;

    BEGIN

    SELECT MAX (d.arcdate)

    In l_DtLast2

    B2_OLAP.AR_DOCUMENT d,

    B2_OLAP. DIMDOCUMENTTYPE dt

    WHERE d.ACCOUNTBID = p_Id

    and d.DOCUMENTTYPEID = dt.id

    and dt. OPERATIONTYPEBYSUMMAID not to (2,3)

    and Substr (d.accountano, 1, 4) not in ('2608', ' 2658 ', ' 2628');

    - and d.DOCUMENTSTATEID = 2

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_DtLast2: = NULL;

    END;

    BEGIN

    SELECT MAX (d.arcdate)

    In l_DtLast3

    B2_OLAP.AR_DOCUMENT d,

    B2_OLAP. DIMDOCUMENTTYPE dt

    WHERE d.ACCOUNTAID = p_Id

    and d.DOCUMENTTYPEID = dt.id

    and dt. OPERATIONTYPEBYSUMMAID not to (2,3);

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_DtLast3: = NULL;

    END;

    BEGIN

    SELECT MAX (d.arcdate)

    In l_DtLast4

    B2_OLAP.AR_DOCUMENT d,

    B2_OLAP. DIMDOCUMENTTYPE dt

    WHERE d.ACCOUNTAID = p_Id

    and d.DOCUMENTTYPEID = dt.id

    and dt. OPERATIONTYPEBYSUMMAID not to (2,3);

    - and d.DOCUMENTSTATEID = 2

    EXCEPTION

    WHEN NO_DATA_FOUND THEN

    l_DtLast4: = NULL;

    END;

    l_DtLast1:=NVL(l_DtLast1,to_date('01.01.1900','dd.mm.yyyy'));

    l_DtLast2:=NVL(l_DtLast2,to_date('01.01.1900','dd.mm.yyyy'));

    l_DtLast3:=NVL(l_DtLast3,to_date('01.01.1900','dd.mm.yyyy'));

    l_DtLast4:=NVL(l_DtLast4,to_date('01.01.1900','dd.mm.yyyy'));

    l_Result: = Greatest (l_DtLast1, l_DtLast2, l_DtLast3, l_DtLast4);

    IF l_Result = TO_DATE('01.01.1900','dd.mm.yyyy') THEN

    l_Result: = NULL;

    END IF;

    RETURN l_Result;

    END DtLastMove;

    ---////////////////////////////////////////////////////

    END;

    /

    You declare your parameter with a different type between the specification and body, your statements must match.

  • 30EA2 save the package specification and body - safe only spec?

    It seems that the "save the body and spec package' in the menu contextual on the specifications in the object tree discovered records actually only the spec (.pls).

    Is this true?

    Is safe spec and body in a single file.

  • PLS-00304: cannot compile &lt; package &gt; body without its specification

    Hi all
    When compiling the below pasted together, I got the following error msg.
    PL/SQL: Compilation unit analysis terminated
    PLS-00304: cannot compile body of 'EDR_RPT_CLASS_BY_TAWT_PACKAGE'
    without its specification
    
    PLS-00905: object HDOT.EDR_RPT_CLASS_BY_TAWT_PACKAGE is invalid
    But me, which forfeit and ppackage specification of the body properly. Please could someone help me find the error

    CREATE OR REPLACE PACKAGE edr_rpt_class_by_tawt_package AS
    
    
    PROCEDURE edr_rpt_gen_class_by_tawt (
      in_report_parameter_id   IN      report_tasks.report_task_id%TYPE,
      report_data              OUT     SYS_REFCURSOR,
      chart_data               OUT     SYS_REFCURSOR,
      footer_data              OUT     SYS_REFCURSOR
    );
    
    PROCEDURE edr_rpt_gen_class_by_fawt (
      in_report_parameter_id   IN      report_tasks.report_task_id%TYPE,
      report_data              OUT     SYS_REFCURSOR,
      chart_data               OUT     SYS_REFCURSOR,
      footer_data              OUT     SYS_REFCURSOR
    );
    
    PROCEDURE edr_rpt_gen_class_by_sawt (
      in_report_parameter_id   IN      report_tasks.report_task_id%TYPE,
      report_data              OUT     SYS_REFCURSOR,
      chart_data               OUT     SYS_REFCURSOR,
      footer_data              OUT     SYS_REFCURSOR
    );
    
    
    PROCEDURE edr_rpt_gen_class_by_triawt (
      in_report_parameter_id   IN      report_tasks.report_task_id%TYPE,
      report_data              OUT     SYS_REFCURSOR,
      chart_data               OUT     SYS_REFCURSOR,
      footer_data              OUT     SYS_REFCURSOR
    );
    
    PROCEDURE edr_rpt_gen_class_by_qawt (
      in_report_parameter_id   IN      report_tasks.report_task_id%TYPE,
      report_data              OUT     SYS_REFCURSOR,
      chart_data               OUT     SYS_REFCURSOR,
      footer_data              OUT     SYS_REFCURSOR
    );
    
    FUNCTION  class_count
    (
      in_lane_id                  edr_rpt_by_ranges_output.lane_id%TYPE,
      in_direction_id             edr_rpt_by_ranges_output.direction_id%TYPE,
      in_interval_start_date_time edr_rpt_by_ranges_output.interval_start_date_time%TYPE,
      in_interval_end_date_time   edr_rpt_by_ranges_output.interval_start_date_time%TYPE,
      in_axle_wt_min              edr_cls_by_tawt_report_data.group_weight%TYPE,
      iin_axle_wt_max             edr_cls_by_tawt_report_data.group_weight%TYPE,
      in_class_min                edr_cls_by_tawt_report_data.vehicle_class%TYPE,
      in_class_max                edr_cls_by_tawt_report_data.vehicle_class%TYPE
    )
    RETURN VARCHAR2;
    
    
    END edr_rpt_class_by_tawt_package;
    /
    
    CREATE OR REPLACE PACKAGE BODY edr_rpt_class_by_tawt_package AS
    
       c_front_axle_only         CONSTANT axle_class.group_type%TYPE := -1;
       c_axle_single_group_type  CONSTANT axle_class.group_type%TYPE := 1;
       c_axle_tandem_group_type  CONSTANT axle_class.group_type%TYPE := 2;
       c_axle_tridem_group_type  CONSTANT axle_class.group_type%TYPE := 3;
       c_axle_quadrem_group_type CONSTANT axle_class.group_type%TYPE := 4;
       c_kips_conversion_unit_id CONSTANT units.unit_id%TYPE         := 8;
    
       v_report_axle_group_type  axle_class.group_type%TYPE := 0;
    
    
    FUNCTION  class_count
    (
      in_lane_id                  edr_rpt_by_ranges_output.lane_id%TYPE,
      in_direction_id             edr_rpt_by_ranges_output.direction_id%TYPE,
      in_interval_start_date_time edr_rpt_by_ranges_output.interval_start_date_time%TYPE,
      in_interval_end_date_time   edr_rpt_by_ranges_output.interval_start_date_time%TYPE,
      in_axle_wt_min              edr_cls_by_tawt_report_data.group_weight%TYPE,
      in_axle_wt_max              edr_cls_by_tawt_report_data.group_weight%TYPE,
      in_class_min                edr_cls_by_tawt_report_data.vehicle_class%TYPE,
      in_class_max                edr_cls_by_tawt_report_data.vehicle_class%TYPE
    )
    RETURN NUMBER
    IS
      my_count_result NUMBER(18);
    BEGIN
    
       SELECT NVL(SUM(vehicle_count), 0 )
       INTO my_count_result
       FROM
           (
            SELECT site_lane_id
            FROM   edr_rpt_tmp_report_lanes
            WHERE  edr_rpt_tmp_report_lanes.output_lane_id        = in_lane_id
              AND  edr_rpt_tmp_report_lanes.output_direction_id   = in_direction_id
           ) report_lanes
       JOIN edr_cls_by_tawt_report_data
         ON edr_cls_by_tawt_report_data.site_lane_id          = report_lanes.site_lane_id
       WHERE edr_cls_by_tawt_report_data.bin_start_date_time >= in_interval_start_date_time
         AND edr_cls_by_tawt_report_data.bin_start_date_time <  in_interval_end_date_time
         AND edr_cls_by_tawt_report_data.group_weight >= in_axle_wt_min
         AND edr_cls_by_tawt_report_data.group_weight  < in_axle_wt_max  
         AND edr_cls_by_tawt_report_data.vehicle_class >= in_class_min
         AND edr_cls_by_tawt_report_data.vehicle_class <= in_class_max
         ;
    
       RETURN my_count_result;
    END;
    
    
    FUNCTION get_row_class_counts_text
    RETURN VARCHAR2
    IS
       my_row_counts_text  VARCHAR2(10000);
       my_row_counts_entry  VARCHAR2(10000);
    
       CURSOR row_counts_text IS
         SELECT 'edr_rpt_class_by_tawt_package.class_count('
                           ||'lane_id, '
                           ||'direction_id, '
                           ||'interval_start_date_time, '
                           ||'interval_end_date_time, '
                           ||'range_low, '
                           ||'range_high, '
                           || class_id || ', '
                           || class_id || ') "'|| class_id || '"'
         FROM edr_rpt_tmp_report_classes
         ORDER BY class_id;
    
    BEGIN
    
      my_row_counts_text   := '';
      my_row_counts_entry  := '';
    
      -- generate the speed ranges function calls
      OPEN row_counts_text;
      LOOP
    
        FETCH row_counts_text INTO my_row_counts_entry;
    
        EXIT WHEN row_counts_text%NOTFOUND;
    
        my_row_counts_text := my_row_counts_text || ', ' || my_row_counts_entry;
    
      END LOOP;
      CLOSE row_counts_text;
    
      RETURN my_row_counts_text;
    
    END;
    
    
    
    FUNCTION get_row_totals_text
    RETURN VARCHAR2
    IS
       my_row_count_total_text  VARCHAR2(10000);
    BEGIN
    
      my_row_count_total_text := '';
    
      -- generate the 'total' column function call
      SELECT 'edr_rpt_class_by_tawt_package.class_count('
                           ||'lane_id, '
                           ||'direction_id, '
                           ||'interval_start_date_time, '
                           ||'interval_end_date_time, '
                           ||'range_low, '
                           ||'range_high, '
                           || MIN(class_id) || ', '
                           || MAX(class_id) || ') " "'
      INTO my_row_count_total_text
      FROM edr_rpt_tmp_report_classes;
    
      RETURN ', ' || my_row_count_total_text;
    
    END;
    
    
    
    PROCEDURE apply_default_awt_ranges(in_report_parameter_id   IN   NUMBER)
    IS
    
      my_awt_ranges_count NUMBER(4);
    
    BEGIN
    
     SELECT nvl(count(1),0)
     INTO my_awt_ranges_count
     FROM report_range_parameters
     WHERE REPORT_PARAMETER_ID = in_report_parameter_id
       AND REPORT_PARAMETER_GROUP = 'AXLE_GROUP'
       AND REPORT_PARAMETER_NAME = 'AXLE_NAME';
    
     IF  ( my_awt_ranges_count = 0 )
     THEN
      INSERT INTO report_range_parameters (REPORT_PARAMETER_ID, REPORT_PARAMETER_GROUP, REPORT_PARAMETER_NAME, REPORT_PARAMETER_MIN_VALUE, REPORT_PARAMETER_MAX_VALUE)
        VALUES (in_report_parameter_id, 'AXLE_GROUP', 'AXLE_NAME', '0', '2'); 
        VALUES (in_report_parameter_id, 'AXLE_GROUP', 'AXLE_NAME', '30', '32');
     END IF;
    
    END;
    
    
    PROCEDURE edr_class_by_tawt_use_per_veh
    (
       in_report_parameter_id   IN      report_tasks.report_task_id%TYPE,
       in_good_status_mask      IN      NUMBER
    )
    IS
    
     max_axle_group_value NUMBER(12);
    
    BEGIN
    
      DELETE FROM edr_cls_by_tawt_report_data;
     
      COMMIT;
    
      INSERT INTO edr_cls_by_tawt_report_data
                    (
                      site_id,
                      site_lane_id,
                      site_direction_id,
                      site_direction_name,
                      bin_start_date_time,
                      group_weight,
                      bin_id,
                      bin_value
                     )
      SELECT site_id,
             site_lane_id,
             site_direction_id,
             site_direction_name,
             date_time,
             group_weight,
             vehicle_class,
             COUNT(vehicle_class)
      FROM
             (
               SELECT edr_cls_by_tawt_per_veh_data.*
                 FROM edr_cls_by_tawt_per_veh_data           
         GROUP BY date_time,
               site_lane_id,
               group_weight,
               vehicle_class,
               site_id,
               site_direction_id,
               site_direction_name;
    
    END edr_class_by_tawt_use_per_veh;
    
    
    PROCEDURE edr_class_by_tawt_data_type
    (
      in_report_parameter_id   IN      report_tasks.report_task_id%TYPE,
      in_good_status_mask      IN      NUMBER,
      in_data_type             IN      VARCHAR2,
      out_data_type_used          OUT  VARCHAR2
    )
    IS
      my_bin_entry_count   NUMBER(12,0);
      my_veh_entry_count   NUMBER(12,0);
    BEGIN
    
      IF(UPPER(in_data_type) = 'BINNED') THEN
    
        --  Axle information can only be read from Per Vehicle data records
        --   - using bins-only is not a supported option
        RAISE_APPLICATION_ERROR(-20101,'Binned data cannot be used for this report.');
    
    
      ELSIF    (UPPER(in_data_type) = 'PERVEHICLE')
            OR (UPPER(in_data_type) = 'COMBINED')
      THEN
    
        out_data_type_used := 'Per Vehicle (All Vehicles)';
    
        edr_class_by_tawt_use_per_veh( in_report_parameter_id, in_good_status_mask );
    
      ELSE
         RAISE_APPLICATION_ERROR(-20101,'The data type specified is not recognized.');
      END IF;
    
    END edr_class_by_tawt_data_type;
    
    
    PROCEDURE edr_class_by_tawt_get_veh_data
    (
      in_report_parameter_id   IN   NUMBER,
      in_site_id               IN   NUMBER,
      in_start_date_time       IN   TIMESTAMP,
      in_end_date_time         IN   TIMESTAMP,
      in_report_level_min      IN   NUMBER,
      in_report_level_max      IN   NUMBER
    )
    IS
    
    BEGIN
     
      DELETE FROM edr_cls_by_tawt_per_veh_data;
    
      INSERT INTO edr_cls_by_tawt_per_veh_data
            (
              site_id,
              site_lane_id,
              site_direction_id,
              site_direction_name,
              record_id,
              date_time,
              group_weight,
              vehicle_class,
              group_number,
              vehicle_status,
              vehicle_error_count,
              axle_violations_count,
              group_type          
            )
      SELECT axle_info.site_id,
             axle_info.site_lane_id,
             axle_info.site_direction_id,
             axle_info.site_direction_name,
             axle_info.record_id,
             axle_info.datetime,
             axle_info.group_weight,
             axle_info.v_class,
             axle_info.group_number,
             NVL((SELECT SUM(status_code)
                    FROM traffic_status
                   WHERE traffic_status.record_id = axle_info.record_id), 0) vehicle_status,
             NVL((SELECT COUNT(error_code)
                    FROM traffic_error
                   WHERE traffic_error.record_id = axle_info.record_id), 0) vehicle_error_count,
             NVL((SELECT COUNT(1)
                    FROM axle_weight_violation
                   WHERE axle_weight_violation.record_id = axle_info.record_id), 0) axle_violations_count,
             axle_info.group_type            
        FROM (SELECT site_to_data_source_lane_v.site_id,
                     site_to_data_source_lane_v.site_lane_id,
                     site_to_data_source_lane_v.site_direction_id,
                     site_to_data_source_lane_v.site_direction_name,
                     traffic_record.record_id,
                     traffic_record.datetime,
                     NVL(traffic_class.v_class, 0)   v_class,
                     NVL(axle_class.group_type, 0)   group_type,
                     NVL(axle_class.group_number, 0) group_number,                
                     NVL(TRUNC(sum(convert_units(axle.weight_unit_id,
                                             c_kips_conversion_unit_id,
                                             axle.axle_weight
                                            )
                               )
                           ),
                           0
                         ) group_weight
               FROM  traffic_record
               JOIN  site_to_data_source_lane_v
                 ON  traffic_record.data_source_id = site_to_data_source_lane_v.data_source_id
                AND  traffic_record.lane = site_to_data_source_lane_v.data_source_lane_id                    
           GROUP BY site_to_data_source_lane_v.site_id,
                     site_to_data_source_lane_v.site_lane_id,
                     site_to_data_source_lane_v.site_direction_id,
                     site_to_data_source_lane_v.site_direction_name,
                     traffic_record.record_id,
                     traffic_record.datetime,
                     traffic_class.v_class,                 
                     axle_class.group_type,
                     axle_class.group_number
            ) axle_info
       
    
    END edr_class_by_tawt_get_veh_data;
    
    
    PROCEDURE gen_class_by_axle_type
    (
      in_report_parameter_id   IN      report_tasks.report_task_id%TYPE,
      report_data              OUT     SYS_REFCURSOR,
      chart_data               OUT     SYS_REFCURSOR,
      footer_data              OUT     SYS_REFCURSOR
    )
    AS
    
     
    BEGIN
     
      apply_default_awt_ranges(in_report_parameter_id);
    
      my_date_format_mask   := edr_rpt_generic_package.edr_rpt_get_date_format_mask(in_report_parameter_id);
      my_start_date_time    := edr_rpt_generic_package.edr_rpt_get_start_date_time(in_report_parameter_id, my_date_format_mask);
      my_end_date_time      := edr_rpt_generic_package.edr_rpt_get_end_date_time(in_report_parameter_id, my_date_format_mask);
      my_lane_grouping      := edr_rpt_generic_package.edr_rpt_get_lane_grouping(in_report_parameter_id);
      my_site_id            := edr_rpt_generic_package.edr_rpt_get_site_id(in_report_parameter_id);
      my_selected_data_type := edr_rpt_generic_package.edr_rpt_get_data_type(in_report_parameter_id);
    
      -- ensure selected classes and lanes temp tables have been populated
      edr_rpt_generic_package.edr_rpt_gen_tmp_lanes(in_report_parameter_id);
      edr_rpt_generic_package.edr_rpt_gen_tmp_classes(in_report_parameter_id);
      edr_rpt_generic_package.edr_rpt_gen_tmp_speed_ranges(in_report_parameter_id);
    
      my_good_weight_statuses_mask   := edr_rpt_generic_package.get_good_weight_status_mask(in_report_parameter_id);
    
    
      edr_rpt_generic_package.edr_rpt_gen_inclusion_table
      (
        in_report_parameter_id,
        my_date_format_mask,
        my_start_date_time,
        my_end_date_time
      );
    
      edr_rpt_generic_package.edr_rpt_gen_grouping_table
      (
        in_report_parameter_id,
        my_date_format_mask,
        my_start_date_time,
        my_end_date_time
      );
    
      edr_class_by_tawt_get_veh_data
      (
        in_report_parameter_id,
        my_site_id,
        my_start_date_time,
        my_end_date_time,
        0,                          --Hardcoded until reclassification is supported.
        0                           --Hardcoded until reclassification is supported.
      );
    
      edr_class_by_tawt_data_type
      (
        in_report_parameter_id,
        my_good_weight_statuses_mask,
        my_selected_data_type,
        my_used_data_type
      );
    
    
      edr_rpt_generic_package.gen_rpt_by_ranges_output_table
      (
        in_report_parameter_id,
        'AXLE_GROUP',
        'AXLE_NAME'
      );
    
      COMMIT;
      my_report_data_statement :=
          ' SELECT rank "Rank", '
        ||       ' row_type "Row Type", '
        ||       ' interval_start_date_time "Date", '
        ||       ' interval_start_date_time, '
        ||       ' range_label "Chart X-Axis", '
        ||       ' lane_id "Group Id" , '
        ||       ' ''None'' "Group Name", '
        ||       ' range_label "Speed (mph)" '
        ||         get_row_class_counts_text
        ||         get_row_totals_text
        ||       ' FROM edr_rpt_by_ranges_output '
        ||       ' ORDER BY lane_id, '
        ||                ' direction_id, '
        ||                ' interval_start_date_time, '
        ||                ' range_high, '
        ||                ' rank, '
        ||                ' range_low'
        ;
    
      dbms_output.put_line('SQL start------------------------');
      dbms_output.put_line(my_report_data_statement);
      dbms_output.put_line('SQL end--------------------------');
    
    
      my_chart_data_statement :=
           ' SELECT range_low "X Axis", '
        ||        ' lane_id "Group" '
        ||         get_row_class_counts_text
        || ' FROM '
        || ' ( '
        || ' SELECT lane_id, '
        ||        ' direction_id, '
        ||        ' range_low, '
        ||        ' range_high, '
        ||        ' min(interval_start_date_time) interval_start_date_time, '
        ||        ' max(interval_end_date_time) interval_end_date_time '
        || ' FROM edr_rpt_by_ranges_output '
        || ' WHERE rank = 1 '
        || ' GROUP BY lane_id, direction_id, range_low,  range_high '
        || ' ) '
        || ' order by "Group", range_low '
        ;
    
      dbms_output.put_line('SQL start------------------------');
      dbms_output.put_line(my_chart_data_statement);
      dbms_output.put_line('SQL end--------------------------');
    
    
    
      SELECT my_used_data_type
        INTO my_data_type_used
        FROM SYS.DUAL;
    
      SELECT NVL(COUNT(DISTINCT record_id), 0)
        INTO my_per_vehicle_total
        FROM edr_cls_by_tawt_per_veh_data;
    
      SELECT NVL(COUNT(DISTINCT record_id), 0)
        INTO my_status_vehicle_total
        FROM edr_cls_by_tawt_per_veh_data
       WHERE vehicle_status > 0
         AND vehicle_error_count = 0;
    
    
      SELECT NVL(COUNT(DISTINCT record_id), 0)
        INTO my_error_vehicle_total
        FROM edr_cls_by_tawt_per_veh_data
       WHERE vehicle_error_count > 0;
    
    
      SELECT NVL(COUNT(DISTINCT record_id), 0)
        INTO my_status_clear_total
        FROM edr_cls_by_tawt_per_veh_data
       WHERE vehicle_status = 0
         AND vehicle_error_count = 0;
    
    
      SELECT NVL(COUNT(1), 0)
        INTO my_binned_vehicle_total
        FROM edr_cls_by_tawt_per_veh_data;
    
      SELECT NVL(COUNT(1), 0)
        INTO my_good_weight_total
        FROM edr_cls_by_tawt_per_veh_data
       WHERE vehicle_error_count = 0
         AND BITAND(vehicle_status, my_good_weight_statuses_mask) = 0;
    
      -- insert vehicle totals into the temporary table
      DELETE FROM edr_rpt_tmp_veh_totals_table;
    
      INSERT INTO edr_rpt_tmp_veh_totals_table
      SELECT my_data_type_used,
             my_per_vehicle_total,
             my_binned_vehicle_total,
             my_error_vehicle_total,
             my_status_vehicle_total,
             my_good_weight_total,
             my_status_clear_total
        FROM SYS.DUAL;
    
      -- execute the query into the output refcursor
      OPEN report_data FOR
        my_report_data_statement;
    
      OPEN chart_data FOR
        my_chart_data_statement;
    
      OPEN footer_data FOR
        SELECT data_type_used,
               per_vehicle_total,
               binned_vehicle_total,
               error_vehicle_total,
               status_vehicle_total,
               good_weight_total,
               status_clear_total
          FROM edr_rpt_tmp_veh_totals_table;
    
    END gen_class_by_axle_type;
    
    PROCEDURE edr_rpt_gen_class_by_sawt (
      in_report_parameter_id   IN      report_tasks.report_task_id%TYPE,
      report_data              OUT     SYS_REFCURSOR,
      chart_data               OUT     SYS_REFCURSOR,
      footer_data              OUT     SYS_REFCURSOR
    )
    AS
    BEGIN
      v_report_axle_group_type := c_axle_single_group_type;
      gen_class_by_axle_type(in_report_parameter_id, report_data, chart_data, footer_data);
    END;
    
    PROCEDURE edr_rpt_gen_class_by_fawt (
      in_report_parameter_id   IN      report_tasks.report_task_id%TYPE,
      report_data              OUT     SYS_REFCURSOR,
      chart_data               OUT     SYS_REFCURSOR,
      footer_data              OUT     SYS_REFCURSOR
    )
    AS
    BEGIN
      v_report_axle_group_type := c_front_axle_only ;
      gen_class_by_axle_type(in_report_parameter_id, report_data, chart_data, footer_data);
    END;
    
    PROCEDURE edr_rpt_gen_class_by_tawt (
      in_report_parameter_id   IN      report_tasks.report_task_id%TYPE,
      report_data              OUT     SYS_REFCURSOR,
      chart_data               OUT     SYS_REFCURSOR,
      footer_data              OUT     SYS_REFCURSOR
    )
    AS
    BEGIN
      v_report_axle_group_type := c_axle_tandem_group_type;
      gen_class_by_axle_type(in_report_parameter_id, report_data, chart_data, footer_data);
    END;
    
    PROCEDURE edr_rpt_gen_class_by_triawt (
      in_report_parameter_id   IN      report_tasks.report_task_id%TYPE,
      report_data              OUT     SYS_REFCURSOR,
      chart_data               OUT     SYS_REFCURSOR,
      footer_data              OUT     SYS_REFCURSOR
    )
    AS
    BEGIN
      v_report_axle_group_type := c_axle_tridem_group_type;
      gen_class_by_axle_type(in_report_parameter_id, report_data, chart_data, footer_data);
    END;
    
    PROCEDURE edr_rpt_gen_class_by_qawt (
      in_report_parameter_id   IN      report_tasks.report_task_id%TYPE,
      report_data              OUT     SYS_REFCURSOR,
      chart_data               OUT     SYS_REFCURSOR,
      footer_data              OUT     SYS_REFCURSOR
    )
    AS
    BEGIN
      v_report_axle_group_type :=  c_axle_quadrem_group_type;
      gen_class_by_axle_type(in_report_parameter_id, report_data, chart_data, footer_data);
    END;
    
    END edr_rpt_class_by_tawt_package;
    /
    
    
    LIST
    
    SHOW ERROR

    FUNCTION RETURN VARCHAR2 class_count in package specifications and
    FUNCTION RETURN NUMBER class_count in the package body.
    change the type of data SERVICE class_count

  • Void Header conversion package


    Hello

    I'm updating subheader for specification packaging "Specification of packaging" in the local translation table (subheader under the technical name)

    TESTS-SPE (123456-001)

    Packaging

    but I'm not able to find the common translation item id,

    Note: I am able to change header sub for other specification value types as subheader, but the value of default translation is not available for subheader packaging


    NOT EXISTS ( select * from INFORMATION_SCHEMA. TABLES where table_name = 'DataAdminToolkit_VersionHist' ( )

    TABLE DataAdminToolkit_VersionHist

    char (36) PRIMARY KEY,

    DATETIME ,

    DATETIME

    () Choose count(*) of DataAdminToolkit_VersionHist where pkid = '1dadfb5c-9018-4675-a9ff-0119cffd741f' ) = 0

    DECLARE @err int

    START TRANSACTION

    INSERT in DataAdminToolkit_VersionHist values ( ) '1dadfb5c-9018-4675-a9ff-0119cffd741f' may 5, 2014 14:50:46 ', GetDate() );

    IF () CHOOSE count(*) FROM localTranslationItemValues WHERE ()fkTranslationItem = ' 21669a6da471-e6b9-46dd-ae94-a8e67dea4e29 ' AND langID = 0( ) ( ) = 0

    INSERT IN localTranslationItemValues ()pkid fkTranslationItem langValue langID() CHOOSE ' 2167edf46361-2bc5-461 a-a790-fafe0826dbd1 ' ' 21669a6da471-e6b9-46dd-ae94-a8e67dea4e29 ' updated-SPEC', 0 FROM DUAL

    ON THE OTHER

    UPDATE localTranslationItemValues The VALUE langValue = Updated-SPEC' WHERE ()fkTranslationItem = ' 21669a6da471-e6b9-46dd-ae94-a8e67dea4e29 ' AND langID = 0);

    SELECT @err = @@error;

    IF @err <> 0

    START

    Print ' Statement caused an error during execution:

    Print 'Roll back... ". »

    ROLLBACK

    RETURN

    END

    IF () CHOOSE count(*) FROM localTranslationItemValues WHERE ()fkTranslationItem = ' 21660a7d24dd-2ade-4374-9ec8-203acebc2a09 ' AND langID = 0( ) ( ) = 0

    INSERT IN localTranslationItemValues ()pkid fkTranslationItem langValue langID() CHOOSE ' 2167be71b744-a79f-4aaf-b972-526b0432a13a ' ' 21660a7d24dd-2ade-4374-9ec8-203acebc2a09 ' do PKG-Spec', 0 FROM DUAL

    ON THE OTHER

    UPDATE localTranslationItemValues The VALUE langValue = Do PKG-Spec' WHERE ()fkTranslationItem = ' 21660a7d24dd-2ade-4374-9ec8-203acebc2a09 ' AND langID = 0);

    SELECT @err = @@error;

    IF @err <> 0

    START

    Print ' Statement caused an error during execution:

    Print 'Roll back... ". »

    ROLLBACK

    RETURN

    END

    Print 'Success...'

    ENGAGE


    Kind regards
    Kumar

    In point 6.1.1 the header shows the packaging item type that is selected on the specifications.  You can change the name of the element in ADMN.

  • I am curious about OEM vs. retail and retail sales are expensive but OEM work on any pc or only specific PC

    I have a question for OEM, my computer is a HP pavilion ze2000 since 2004 there windows 10 pro about it right now but it has not enabled which means no product key so im going to buy sp1 windows 7 pro 32 bit from a seller on amazon called MC OUTLETS:

    http://www.Amazon.com/GP/AW/d/B014E4FBCO/ref=mp_s_a_1_13?QID=1461169711&SR=8-13&PI=AC_SX236_SY340_QL65&keywords=Windows+7

    and I don't know if I should buy the OEM because one seller sells me is maybe not for my brand of pc and I want to be sure what im buy so I don't waste money, buy windows 7 which can be for lets say dell and I have a hp so I don't get stuck with the purchase of this product just to get the product key , so I can reinstall windows 10 must be enabled. And please don't tell me to buy the commercial version because I do a lot of cash right now I can only which means that ONLY afford OEM please tell if this seller is legitimate and if this product would work on my brand of pc which is a HP pavilion ze2000

    I wouldn't recommend that you buy from a dealer, especially the amazon market place.

    Because Windows 7 is in limited stock because Microsoft ended sales in October 2013, this created demand due to its rarity. This means the retail boxed copies request a bonus, while the OEM System Builder copies remain affordable.

    Full version (retail):

    -Includes the rights of transfer to another computer.

    -Does not require a qualifying earlier version of Windows.

    -Expensive

    Upgrade version (detail):

    -Includes the rights of transfer to another computer.

    -require a qualifying earlier version of Windows.

    -Expensive, but less expensive full version

    OEM System Builder version:

    The OEM of Windows 7 versions are identical to the versions commercial full license with the following exception:

    -OEM versions don't offer any free direct support from Microsoft technical support Microsoft

    -OEM Licenses are tied to the computer first you install and activate it on

    -OEM versions allow all hardware upgrades except for an upgrade to a different model motherboard

    -OEM versions does not move directly from an older Windows operating system

    There is nothing wrong to use it too, especially that all future versions of Windows will be full versions.

    You can find software OEM System Builder of dozens of online merchants. The current price for OEM Windows 7 Professional Newegg, for example, is $ 140. When I checked a few minutes ago, Amazon offered packages OEM Windows 7 Professional from several vendors at prices ranging from $ 101 to $ 150. When I checked earlier, a package specifically designed for reconditioned PCs cost only $ 50 for a 64-bit copy.

    There is no technical limitation to prevent you from using OEM software on your computer, although this software only works for a clean install, not an upgrade. In the past, Microsoft has been remarkably inconsistent in his advice to clients on the question of whether this practice is allowed. (See "is allowed to use Windows OEM on your own PC? Don't ask Microsoft. »)

  • Package body is not VALID

    Hi friends,

    Could you help me understand this behavior in oracle.

    SQL > create or replace package mypkg is

    2 number of v_statevar: = 40;

    3 procedure MyProc;

    4 end mypkg;

    5.

    Package created.

    SQL > create or replace package body is mypkg

    2 procedure MyProc is

    3 myval number;

    4 start

    5. Select x

    6 in myval

    7 of dependonme;

    8

    9 - myval: = myval * mypkg.v_statevar;

    10 DBMS_OUTPUT. Put_line (' my result is: ' | myVal);

    11 end;

    12 end mypkg;

    13.

    Package body created.

    SQL > select object_name, object_type, status from user_objects where object_name = 'MYPKG ';

    OBJECT_NAME OBJECT_TYPE STATUS

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

    PACKAGE VALID MYPKG

    VALID PACKAGE BODY MYPKG

    SQL > set serveroutput on

    SQL > exec mypkg.myproc;

    My result is: 5

    PL/SQL procedure successfully completed.

    SQL > create or replace package mypkg is

    2 number of v_statevar: = 150;

    3 procedure MyProc;

    4 end mypkg;

    5.

    Package created.

    SQL > select object_name, object_type, status from user_objects where object_name = 'MYPKG ';

    OBJECT_NAME OBJECT_TYPE STATUS

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

    PACKAGE VALID MYPKG

    INVALID BODY PACKAGE MYPKG

    SQL > set serveroutput on

    SQL > exec mypkg.myproc;

    My result is: 5

    PL/SQL procedure successfully completed.

    SQL > select object_name, object_type, status from user_objects where object_name = 'MYPKG ';

    OBJECT_NAME OBJECT_TYPE STATUS

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

    PACKAGE VALID MYPKG

    VALID PACKAGE BODY MYPKG

    SQL >

    How did change the value of the variable in the package specification makes the invalid package body.

    How execution of the procedure of the package is once again the VALID State.

    Kimmy says:

    Hello carine,.

    I'm just setting the variable in the notebook, that variable was not referred to the procedure in the package body, also I'm not change any signature/details of the procedure described in the package specification, then what do the package body are invalid.

    There are two parts to this.

    (a) by recompiling package specifications, you then automatically invalidates all objects in the database that dependent on it.  In this case, the package body is dependent on, so get marked as invalid.  When you try and run something in the package Oracle try to compile the package, if it succeeds, it will mark it as valid again (as in your case).

    (b) the variables and declarations of a package (public and private) are what constitutes the 'State '.  By calling the package, you instantiate a copy in memory to create this state of package for this instantiation of the entire session.  By recompiling package specifications (it's not fair that you change the value of the variable, you recompile the spec), you can invalidate the State in memory and therefore potentially invalidate the package body.  It depends on your version of the database.  In 10g, by invalidating state you will get an exception "State package rejected" when you try to run the package after the change, and then it will automatically compile and validate the package, so that it eventually works ok.  From 11 g, there is more fine grain dependencies on the State, so if the change you have made has no effect on what you run, it can validate and run without causing the exception 'package State scrapped ';. He would only do that if it's something that you used.

  • Package / procedure dba_procedure

    Hello

    I have a package with two procedures and I will try to find procedures by querying DBA_PROCEDURES.

    Could not find the procedure, but I can see them in the package.

    Should all procedures be not in dba_procedures or dba_objects?

    Thank you

    Hello

    DBA_PROCEDURES will show you only the procedures/functions which are not deprived of the packaging (that is to say, they are declared in the package specification).

  • [4.1] links of the object to the package bodies does not

    Steps to reproduce:

    (1) find a PL/SQL Package that is used in the body of another package

    2) go to the "Références" tab

    (3) see how records in the column 'Name' are blue and underlined-click, which implies an object binding, alias "click to open".

    (4) try to actually go to any object that has the 'PACKAGE BODY' in his column "TYPE". It does not work. Clicking on does nothing, neither does ctrl + click.

    Links to other types of objects appear to work correctly, including links with type = 'PACKAGE', i.e. the package specifications. It's pretty weird.

    Known, fixed problem in 4.1.1 patch (forthcoming).

  • Package compilation error

    Version of database

    Oracle Database 11g Express Edition Release 11.2.0.2.0 - Production

    PL/SQL Release 11.2.0.2.0 - Production

    "CORE 11.2.0.2.0 Production."

    AMT for 32-bit Windows: Version 11.2.0.2.0 - Production

    NLSRTL Version 11.2.0.2.0 - Production

    Hi gurus

    I like to read Oracle PL/SQL Programming, 6th edition - O'Reilly Media by Steven Feuerstein and there, I can see the following code:

    Package specifications

    CREATE OR REPLACE

    PACKAGE restaurant_pkg

    IS

    TYPE item_list_t

    IS

    TABLE OF THE VARCHAR2 (30);

    PROCEDURE eat_that)

    items_in IN item_list_t,

    IN BOOLEAN make_it_spicy);

    END;

    /

    Package body

    CREATE OR REPLACE

    Restaurant_pkg body PACKAGE

    IS

    PROCEDURE eat_that)

    items_in IN item_list_t,

    IN BOOLEAN make_it_spicy_in_in)

    IS

    BEGIN

    FOR indx IN 1... items_in. COUNTY

    LOOP

    Dbms_output.put_line

    (

    CASE

    WHEN make_it_spicy_in_in THEN

    "Spicy."

    END | items_in (indx));

    END LOOP;

    END;

    END restaurant_pkg;

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

    but the problem is I get the error at compile time, please advice:

    Error

    Error (5.13): PLS-00323: subprogram or cursor "EAT_THAT" is declared in a package specification and must be defined in the package body

    Thanks in advance

    Concerning

    Shu

    The second parameter in the package body is make_it_spicy_in_in, while in the specifications, it is called make_it_spicy

  • Difference of procedure package Vs

    In addition to an overload and private subprogrammes, what is the advantage of the procedure/function created within a packet on Stand Alone procedures in terms of performance.

    What will be the difference in the behavior of stand-alone procedure/function and procedure/function inside the package if both are called by 100 different user one by one. Will the charge procedure 100 times for each call or not?

    Can someone give me more clearity on these points:

    Best performance - packages can be compiled and are loaded into memory in full and not piecemeal as other methods. This advantage if at all there is minimal compared to other services.

    Invalidation reduced - change a package body does not invalidate the dependencies to change a function or procedure.

    Hello

    Kimmy says:

    Thanks for the links that I read the post before and then I posted this discussion for more clearity...

    Any code that is executed is loaded into the Cache of the bookstores and remain in the library Cache until it is aged by the LRU algorithm. So if there are a 100 calls to a stand alone procedures be there in the Cache/memory?

    If not why not?

    If Yes... So how this behavior differs from the behavior of charge of the public procedure within a package?

    There is nothing special about 100 calls.  A procedure (or package) might be aged after 1 call or after 100 calls, or it can remain in cache after 1 call or after 100 calls.

    The difference between stand-alone procedures and packages in this regard is that all remains in the cache, or gets old, together.  So if you have requested that a procedure in the package, as this package is cached, then the 1st time you call another procedure in this package it will already be in memory.

    Other differences between packages and stand-alone procedures:

    A package can have variables and types defined in package specifications and so can be used by other users.  (With the help of ouutside of package variables to the package, instead of using functions, maybe not a good idea, however.)

    Change a package body is invisible to dependent objects.  If you change just the package body, no other packages or views will be become disabled or need to be recompiled.

  • Error in the package

    Hi gurus

    Need your help to solve one of the error, I have the following code:

    Code

    CREATE or REPLACE PACKAGE ppplch_pkg

    IS

    g_names plch_names_t;

    END ppplch_pkg;

    ----------

    CREATE or REPLACE PACKAGE ppplch_pkg BODY
    IS
    -g_names plch_names_t;
    g_names plch_names_t: = plch_names_t ('Blueberry', 'Raspberry');
    BEGIN

    BECAUSE me IN 1.g_names.count
    loop
    dbms_output.put_line (g_names (i));
    END loop;
    end ppplch_pkg;

    Error

    Error (7,13): PLS-00371: more than a declaration for "G_NAMES" is allowed.

    Grateful if someone explain why I get this error message. Thank you

    Concerning

    Shu

    You cannot declare a global variable of package in the package specification and package body. Declare once in the specification of the package if you want it to be a global variable or in the package body if you like private global variable.

    SY.

Maybe you are looking for

  • Pavilion 17z: death error screen

    Sorry if I put this in the wrong category, but it's the third time, I get this message on my computuer: I got this message about three times during the past two weeks. What happens is that I will work on my computer, and it appears on the entire scre

  • transformed of Fourier of the sine and square wave return is not the frequency of the wave.

    Hi all I did a few programs to determine the Fourier Transforms of the sine waves and square waves. I understand that square wave harmonics when FTed but the Harmons of the square wave is not out at the right frequency and neither is the sine wave. A

  • How can I print from the samsung galaxy tab 10.1?

    I have a samsung galaxy tab 10.1 and I recently bought a printer Photosmart HP 6510. Both are in the wireless network but I can't print from my tablet. Anyone have any suggestions?

  • wrong name of artist/musician

    I have a lot of documents to different musicians on my 8 GB fuze, and all these musicians names are correct. But something must be wrong with the name "Julian Bream" on one of my two records of him. When you look at the record that the two records ar

  • Phone number for Microsoft Vista Support

    Does anyone know if there is a phone number I can call to speak with a representative of the Vista Support? I am having some problems with my laptop which can be easier to explain verbally in a forum. Thank you very much!