Skip Headers
Oracle® Health Sciences Life Sciences Warehouse Application Programming Interface Guide
Release 2.4

E53659-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
PDF · Mobi · ePub

10 Programs

This is a public interface for Program-related functions, including creating, modifying, and removing Programs. It also includes functions for checking Programs in and out, and undoing a Program checkout.

10.1 Create and Modify Programs

This section contains the following topics:

10.1.1 Create a Program

Use this API to create a new Program definition, a new instance of an existing Program definition, or a new definition and an instance of it.

Name CDR_PUB_DF_PROGRAM.CreateProgram

Signature 

PROCEDURE CREATEPROGRAM( 
  P_API_VERSION  IN    NUMBER, 
  P_INIT_MSG_LIST  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_COMMIT  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_VALIDATION_LEVEL  IN    NUMBER := CDR_PUB_DEF_CONSTANTS.G_VALID_LEVEL_FULL, 
  X_RETURN_STATUS  OUT    VARCHAR2, 
  X_MSG_COUNT  OUT    NUMBER, 
  X_MSG_DATA  OUT    VARCHAR2, 
  PIO_SOURCECDRNAMING  IN OUT    CDR_NAMING_VERSION_OBJ_TYPE, 
  PI_CDRPRGOBJTYPE  IN    CDR_PROGRAM_OBJ_TYPE, 
  PI_CREATEOBJECT  IN    VARCHAR2, 
  PI_INSTANCE_SUBTYPE_ID  IN    CDR_NAMINGS.OBJECT_SUBTYPE_ID%TYPE, 
  PI_DEFCLASSIFICATIONCOLL  IN    CDR_CLASSIFICATIONS_COLL, 
  PI_INSTCLASSIFICATIONCOLL  IN    CDR_CLASSIFICATIONS_COLL 
);

Parameters This API has standard parameters (see "Standard Parameters") and the following parameters:

  • PIO_SOURCECDRNAMING (Mandatory) This is a parameter of table type CDR_NAMING_VERSIONS_OBJ_TYPE that contains CDR Naming Version attributes.

    If you are creating a new definition only or a new definition and an instance of it, enter values for the new definition.

    If you are creating an instance of an existing definition, enter values to identify the definition.

    The required attributes are: OBJECT_TYPE_RC,NAME,NAMESPACE_OBJ_ID,NAMESPACE_OBJ_VER,NAMESPACE_START_OBJ_VER,NAMESPACE_END_OBJ_VER,OWNING_LOCATION_RC,OBJECT_SUBTYPE_ID.

    For OBJECT_TYPE_RC enter $OBJTYPES$PROGRAM if you are creating a definition only; $OBJTYPES$PROGRAMINST if you are creating an instance of an existing definition; and NULL if you are creating a new definition and an instance of it.

  • PI_CDRPRGOBJTYPE (Optional) This is a parameter of table type CDR_DATA_MART_OBJ_TYPE that contains object attributes specific to Programs.

    If you are creating a new definition, enter values for the new Program. The following attributes are required: CDR_PROGRAM_OBJ_TYPE,TECH_TYPE_ID.

    If you are creating an instance of an existing Program, do not enter any values here.

  • PI_CREATEOBJECT (Mandatory) Enter DEFN to create a definition only; INST to create a instance of an existing definition; or BOTH to create a new definition and an instance of it.

  • PI_INSTANCE_SUBTYPE_ID (Optional) If you are creating a new instance, enter the ID for the subtype you want to give the instance.

    If you are creating a definition only, do not enter a value for this parameter. Definition and Instance are to be created in the same call.

  • PI_DEFCLASSIFICATIONCOLL (Optional) By default the new definition is classified according to the subtype you assigned it in the CDR_NAMING_VERSION_OBJ_TYPE.

    If you want to override the default classifications for one or more classification levels, use this parameter. This is a collection of CDR_CLA_OBJ_TYPEs, which have five attributes, including CLA_LEVEL_ID and CLASSIFICATION_ID.

    If you want the definition to inherit its classifications for a particular level from its parent, enter the classification level ID and, for the CLASSIFICATION_ID, enter 0 (zero).

    If you want to explicitly assign one or more terms for a particular level, initialize a CDR_CLA_OBJ_TYPE for each term, entering the classification level ID and, for the CLASSIFICATION_ID, the term ID. Do not enter any values for them.

    If you are not creating a new definition, do not enter values here.

  • PI_INSTCLASSIFICATIONCOLL (Optional) By default the new instance is classified according to the subtype you assigned it in the CDR_NAMING_VERSION_OBJ_TYPE.

    If you want to override the default classifications for one or more classification levels, use this parameter. This is a collection of CDR_CLA_OBJ_TYPEs, which have 5 attributes, including CLA_LEVEL_ID and CLASSIFICATION_ID.

    If you want the instance to inherit its classifications for a particular level from its parent Work Area, enter the classification level ID and, for the CLASSIFICATION_ID, enter 0 (zero).

    If you want to explicitly assign one or more terms for a particular level, initialize a CDR_CLA_OBJ_TYPE for each term, entering the classification level ID and, for the CLASSIFICATION_ID, the term ID. The PAR_ attributes are not relevant to Programs. Do not enter any values for them.

    If you are not creating a new instance, do not enter values here.

10.1.2 Copy Objects Into a Program

Use this API to copy objects into a Program.

Name CDR_PUB_DF_PROGRAM.CopyObjectIntoProgram

Signature 

PROCEDURE COPYOBJECTINTOPROGRAM( 
  P_API_VERSION  IN    NUMBER, 
  P_INIT_MSG_LIST  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_COMMIT  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_VALIDATION_LEVEL  IN    NUMBER := CDR_PUB_DEF_CONSTANTS.G_VALID_LEVEL_FULL, 
  X_RETURN_STATUS  OUT    VARCHAR2, 
  X_MSG_COUNT  OUT    NUMBER, 
  X_MSG_DATA  OUT    VARCHAR2, 
  PI_CDRBASEOBJCOLL  IN    CDR_BASE_OBJ_COLL, 
  PI_CDRTARGETCONTAINEROBJECT  IN OUT    CDR_BASE_OBJ_TYPE, 
  PI_CHECKINFLAG  IN    VARCHAR2 
); 

Parameters This API has standard parameters (see "Standard Parameters") and the following parameters:

  • PI_CDRBASEOBJCOLL Collection of objects to be copied.

  • PI_CDRTARGETCONTAINEROBJECT The target container object.

  • PI_CHECKINFLAG Flag to indicate if the copied objects are to be checked in.

10.1.3 Modify a Program

Use this API to modify a Program definition or instance. You can modify the name and description.

If you are modifying an instance object, you can also change the 3 REF attribute values to select a different source definition.

Note:

Note: If you are modifying a definition, you must first check it out.

Name CDR_PUB_DF_PROGRAM.ModifyProgramDetails

Signature 

PROCEDURE MODIFYPROGRAMDETAILS( 
  P_API_VERSION  IN    NUMBER, 
  P_INIT_MSG_LIST  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_COMMIT  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_VALIDATION_LEVEL  IN    NUMBER := CDR_PUB_DEF_CONSTANTS.G_VALID_LEVEL_FULL, 
  X_RETURN_STATUS  OUT    VARCHAR2, 
  X_MSG_COUNT  OUT    NUMBER, 
  X_MSG_DATA  OUT    VARCHAR2, 
  PIO_CDRNAMING  IN OUT    CDR_NAMING_VERSION_OBJ_TYPE 
); 

Parameters This API has standard parameters (see "Standard Parameters") and the following parameter:

PIO_CDRNAMING (Mandatory) This is an IN OUT parameter of table type CDR_NAMING_VERSIONS_OBJ_TYPE that contains CDR Naming Version attributes.

10.1.4 Check In a Program Definition

Use this API to check in a Program definition.

Name CDR_PUB_DF_PROGRAM.CheckInProgramDefinition

Signature 

PROCEDURE CHECKINPROGRAMDEFINITION( 
  P_API_VERSION  IN    NUMBER, 
  P_INIT_MSG_LIST  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_COMMIT  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_VALIDATION_LEVEL  IN    NUMBER := CDR_PUB_DEF_CONSTANTS.G_VALID_LEVEL_FULL, 
  X_RETURN_STATUS  OUT    VARCHAR2, 
  X_MSG_COUNT  OUT    NUMBER, 
  X_MSG_DATA  OUT    VARCHAR2, 
  PIO_BASEOBJECT  IN OUT    CDR_BASE_OBJ_TYPE, 
  PI_COMMENT  IN    VARCHAR2 
); 

Parameters This API has standard parameters (see "Standard Parameters") and the following parameters:

  • PIO_BASEOBJECT (Mandatory) This is a parameter of table type CDR_BASE_OBJ_TYPE. Enter values to identify the Program definition that you want to check in.

    The following attributes are required: COMPANY_ID,OBJ_ID,OBJ_VER,OBJECT_VERSION_NUMBER,NAMESPACE_OBJ_ID,NAMESPACE_OBJ_VER.

  • PI_COMMENT (Optional) Enter the reason you are checking in the Program.

10.1.5 Check Out a Program Definition

Use this API to check out a Program definition either directly or through an instance of it.

Name CDR_PUB_DF_PROGRAM.CheckOutProgram

Signature 

PROCEDURE CHECKOUTPROGRAM( 
  P_API_VERSION  IN    NUMBER, 
  P_INIT_MSG_LIST  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_COMMIT  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_VALIDATION_LEVEL  IN    NUMBER := CDR_PUB_DEF_CONSTANTS.G_VALID_LEVEL_FULL, 
  X_RETURN_STATUS  OUT    VARCHAR2, 
  X_MSG_COUNT  OUT    NUMBER, 
  X_MSG_DATA  OUT    VARCHAR2, 
  PIO_BASEOBJECT  IN OUT    CDR_BASE_OBJ_TYPE, 
  PI_COMMENT  IN    VARCHAR2, 
  PI_ISINSTONLY  IN    VARCHAR2 
); 

Parameters This API has standard parameters (see "Standard Parameters") and the following parameters:

  • PIO_BASEOBJECT (Mandatory) This is a parameter of table type CDR_BASE_OBJ_TYPE. Enter values to identify the Program that you want to check out.

    If you are checking out the Program definition directly, enter values to identify the definition.

    If you are checking out a Program definition through an instance of it, enter values to identify the instance.

    The following attributes are required: COMPANY_ID,OBJ_ID,OBJ_VER,OBJECT_VERSION_NUMBER,NAMESPACE_OBJ_ID,NAMESPACE_OBJ_VER.

  • PI_COMMENT (Optional) Enter the reason you are checking out the Program.

  • PI_ISINSTONLY Enter $YESNO$NO.

10.1.6 Remove a Program

Use this API to remove one or more Program definitions or instances.

Name CDR_PUB_DF_PROGRAM.RemoveProgram

Signature 

PROCEDURE REMOVEPROGRAM( 
  P_API_VERSION  IN    NUMBER, 
  P_INIT_MSG_LIST  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_COMMIT  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_VALIDATION_LEVEL  IN    NUMBER := CDR_PUB_DEF_CONSTANTS.G_VALID_LEVEL_FULL, 
  X_RETURN_STATUS  OUT    VARCHAR2, 
  X_MSG_COUNT  OUT    NUMBER, 
  X_MSG_DATA  OUT    VARCHAR2, 
  PIO_CDRBASEOBJCOLL  IN OUT    CDR_BASE_OBJ_COLL 
); 

Parameters This API has standard parameters (see "Standard Parameters") and the following parameter:

PIO_CDRBASEOBJCOLL (Mandatory) This is a collection of CDR_BASE_OBJ_TYPEs. For each Program that you want to remove, initialize a CDR_BASE_OBJ_TYPE and then extend the collection.

The following attributes are required: COMPANY_ID,OBJ_ID,OBJ_VER,OBJECT_VERSION_NUMBER,NAMESPACE_OBJ_ID,NAMESPACE_OBJ_VER.

10.1.7 Create a Planned Output for a Log File

Use this API to create a log file Planned Output for a Program.

Note:

You must define a log file Planned Output, which is part of the Program definition, through an instance of the Program.

Name CDR_PUB_DF_PROGRAM.CreateLogFilePlannedOutput

Signature 

PROCEDURE CREATELOGFILEPLANNEDOUTPUT( 
  P_API_VERSION  IN    NUMBER, 
  P_INIT_MSG_LIST  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_COMMIT  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_VALIDATION_LEVEL  IN    NUMBER := CDR_PUB_DEF_CONSTANTS.G_VALID_LEVEL_FULL, 
  X_RETURN_STATUS  OUT    VARCHAR2, 
  X_MSG_COUNT  OUT    NUMBER, 
  X_MSG_DATA  OUT    VARCHAR2, 
  PIO_SOURCECODENAMING  IN OUT    CDR_NAMING_VERSION_OBJ_TYPE 
); 

Parameters This API has standard parameters (see "Standard Parameters") and the following parameter:

PIO_SOURCECODENAMING (Mandatory) This is a parameter of type cdr_naming_version_obj_type.

The required attributes are: COMPANY_ID,NAME,NAMESPACE_OBJ_ID,NAMESPACE_OBJ_VER.

10.1.8 Assign a Planned Output

Use this API to assign a Planned Output to a Report Set Entry (RSE). If the Planned Output is already assigned to a different RSE, you must identify that RSE. This API then unassigns the Planned Output from the original RSE and reassigns it to the RSE you specify.

Name CDR_PUB_DF_PROGRAM.AssignPIandPOtoRSEntry

Signature 

PROCEDURE ASSIGNPIANDPOTORSENTRY( 
  P_API_VERSION  IN    NUMBER, 
  P_INIT_MSG_LIST  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_COMMIT  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_VALIDATION_LEVEL  IN    NUMBER := CDR_PUB_DEF_CONSTANTS.G_VALID_LEVEL_FULL, 
  X_RETURN_STATUS  OUT    VARCHAR2, 
  X_MSG_COUNT  OUT    NUMBER, 
  X_MSG_DATA  OUT    VARCHAR2, 
  PI_RSECOMPANYID  IN    CDR_NAMINGS.COMPANY_ID%TYPE, 
  PI_RSEOBJID  IN    CDR_NAMINGS.OBJ_ID%TYPE, 
  PI_RSEOBJVER  IN    CDR_NAMING_VERSIONS.OBJ_VER%TYPE, 
  PI_PIOBJID  IN    CDR_NAMINGS.OBJ_ID%TYPE, 
  PI_POCOMPANYID  IN    CDR_NAMINGS.COMPANY_ID%TYPE, 
  PI_POOBJID  IN    CDR_NAMINGS.OBJ_ID%TYPE, 
  PI_ASGRSEOBJID  IN    CDR_NAMINGS.OBJ_ID%TYPE, 
  PI_ASGRSEOBJVER  IN    CDR_NAMING_VERSIONS.OBJ_VER%TYPE 
);

Parameters This API has standard parameters (see "Standard Parameters") and the following parameters:

  • PI_RSECOMPANYID (Mandatory) Enter the Company ID of the Report Set Entry to which you want to assign the Planned Output. To get your company ID, use CDR_DF_PUB_DEF_CONSTANTS.Current_Company_ID.

  • PI_RSEOBJID (Mandatory) Enter the object ID of the Report Set Entry to which you want to assign the Planned Output.

  • PI_RSEOBJVER (Mandatory) Enter the object version of the Report Set Entry to which you want to assign the Planned Output.

  • PI_PIOBJID (Mandatory) Enter the object ID of the Program instance to which the Planned Output belongs.

  • PI_POCOMPANYID (Mandatory) Enter the Company ID of the Planned Output.

  • PI_POOBJID (Mandatory) Enter the object ID of the Planned Output.

  • PI_ASGRSEOBJID (Optional) If the Planned Output is already assigned to another RSE, enter the object ID of the other Report Set Entry.

  • PI_ASGRSEOBJVER (Optional) If the Planned Output is already assigned to another RSE, enter the object version of the other Report Set Entry.

10.1.9 Modify a Manual Validation Flag Value

Use this API to change the value of the Program's manual validation (Force Validation Status to Development) flag.

Name CDR_PUB_DF_PROGRAM. ModifyProgramDetails

Signature 

PROCEDURE MODIFYPROGRAMDETAILS( 
  P_API_VERSION  IN    NUMBER, 
  P_INIT_MSG_LIST  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_COMMIT  IN    VARCHAR2 := CDR_PUB_DEF_CONSTANTS.G_FALSE, 
  P_VALIDATION_LEVEL  IN    NUMBER := CDR_PUB_DEF_CONSTANTS.G_VALID_LEVEL_FULL, 
  X_RETURN_STATUS  OUT    VARCHAR2, 
  X_MSG_COUNT  OUT    NUMBER, 
  X_MSG_DATA  OUT    VARCHAR2, 
  PIO_CDRNAMING  IN OUT    CDR_NAMING_VERSION_OBJ_TYPE, 
  PI_PROGRAMOBJTYPE  IN OUT    CDR_PROGRAM_OBJ_TYPE 
); 

Parameters This API has standard parameters (see "Standard Parameters") and the following parameters:

  • PIO_CDRNAMING (Mandatory) This is a parameter of table type CDR_NAMING_VERSION_OBJ_TYPE. Enter values to identify the Program definition whose flag value you want to change.

    The following attributes are required: OBJ_ID, OBJ_VER, COMPANY_ID, NS_OBJ_ID, NS_OBJ_VER.

  • PI_PROGRAMOBJTYPE (Mandatory) This is a parameter of table type CDR_PROGRAM_OBJ_TYPE that contains Program definition attributes.

    The required attributes are OBJ_ID, OBJ_VER, COMPANY_ID. Enter values to identify the Program definition whose flag value you want to change and enter the new flag value in the attribute MANUAL_VALIDATION_FLAG_RC. Enter $yesno$yes for yes, and $yesno$no for no.