index

Package gb_stvterm

NOTE: Please be advised that this API  is currently intended to only support internal operations.
To ensure data integrity,  this api  is not supported  when called by external applications or interfaces to manipulate data. The recommendation for external applications is to use message level integration  to integrate with this entitity in  SCT Banner.
 
This package provides the Common Business interface for the Term Code Validation API (gb_stvterm).
 
The Term Code Validation table (STVTERM) is used to define the academic term codes that are associated with numerous business processes and associated functions throughout the Banner system.  The housing start and end dates are used specifically in the Location Management module to support processing for room, meal and phone assignments.  Banner supports term-based and non-term-based processing.  Term-based processes allow for the organization of business rules and records by the term codes established in the STVTERM table.
 
Term codes must be 6 positions in length and must always be numeric. The term structure must be designated with a coding scheme that reflects ascending chronological order.  This is necessary for the system to display academic information (such as courses shown on the transcript) in the correct order and also necessary for business processes (such as determining satisfactory academic progress and performing registration pre-requisite checking) to evaluate data in the correct sequence.
 
NOTE: Create, Update and Delete API calls are not supported for the current release.

Program units
f_api_version   Returns the API version number.
f_get_description   Returns the description of the code.
f_exists   Checks to see if a record exists.
f_code_exists   Checks to see if a term code exists.
f_isequal   Compares two records for equality.
f_query_all   Selects all records for the entity.
f_query_one   Selects one record using the key.
f_query_by_rowid   Selects one record using the ROWID.
f_query_one_lock   Selects one record and locks it.
p_create   Creates a record.
p_delete   Deletes a record.
p_lock   Locks a record.
p_update   Updates a record.

Types
stvterm_rec   Business Entity record type
stvterm_ref   Entity cursor variable type
stvterm_tab   Entity table type

Constants
M_ENTITY_NAME   Business Entity Name

Cursors
stvterm_c   Cursor for the STVTERM table.


M_ENTITY_NAME

M_ENTITY_NAME    CONSTANT VARCHAR2(7) := 'STVTERM';

Business Entity Name


stvterm_rec

TYPE stvterm_rec IS RECORD (
   r_code                    stvterm.stvterm_code%TYPE,
   r_desc                    stvterm.stvterm_desc%TYPE,
   r_start_date              stvterm.stvterm_start_date%TYPE,
   r_end_date                stvterm.stvterm_end_date%TYPE,
   r_fa_proc_yr              stvterm.stvterm_fa_proc_yr%TYPE,
   r_fa_term                 stvterm.stvterm_fa_term%TYPE,
   r_fa_period               stvterm.stvterm_fa_period%TYPE,
   r_fa_end_period           stvterm.stvterm_fa_end_period%TYPE,
   r_acyr_code               stvterm.stvterm_acyr_code%TYPE,
   r_housing_start_date      stvterm.stvterm_housing_start_date%TYPE,
   r_housing_end_date        stvterm.stvterm_housing_end_date%TYPE,
   r_system_req_ind          stvterm.stvterm_system_req_ind%TYPE,
   r_trmt_code               stvterm.stvterm_trmt_code%TYPE,
   r_fa_summer_ind           stvterm.stvterm_fa_summer_ind%TYPE,                                       
   r_internal_record_id      gb_common.internal_record_id_type);

Business Entity record type


stvterm_ref

TYPE stvterm_ref IS REF CURSOR RETURN stvterm_rec;

Entity cursor variable type


stvterm_tab

TYPE stvterm_tab IS TABLE OF stvterm_rec INDEX BY BINARY_INTEGER;

Entity table type


stvterm_c

CURSOR stvterm_c(
   p_code  stvterm.stvterm_code%TYPE)
RETURN stvterm%ROWTYPE;

Cursor for the STVTERM table.


f_api_version

FUNCTION f_api_version RETURN PLS_INTEGER

Returns the API version number.

Returns
Version of the API signature. Changes only when the signature changes.


f_get_description

FUNCTION f_get_description(p_code stvterm.stvterm_code%TYPE)
  RETURN VARCHAR2

Returns the description of the code.

Parameters
p_code   999999 - End of Time. VARCHAR2(6) Required Key

Returns
Description of the term code.


f_exists

FUNCTION f_exists(p_code  stvterm.stvterm_code%TYPE,
                  p_rowid VARCHAR2 DEFAULT NULL) RETURN VARCHAR2

Checks to see if a record exists.

Parameters
p_code   999999 - End of Time. VARCHAR2(6) Required Key
p_rowid   Database ROWID of the record to be selected. VARCHAR2(18)

Returns
Y if found, otherwise N.


f_code_exists

FUNCTION f_code_exists(p_code  stvterm.stvterm_code%TYPE,
                       p_rowid VARCHAR2 DEFAULT NULL) RETURN VARCHAR2

Checks to see if a term code exists.

Parameters
p_code   999999 - End of Time. VARCHAR2(6) Required Key
p_rowid   Database ROWID of the record to be selected. VARCHAR2(18)

Returns
Y if found, otherwise N.


f_isequal

FUNCTION f_isequal(rec_one stvterm_rec,
                   rec_two stvterm_rec) RETURN VARCHAR2

Compares two records for equality.
Tests each field of rec_one against the corresponding field of rec_two. Two null values are considered equal.

Parameters
rec_one   First record to compare. Type stvterm_rec. Required
rec_two   Second record to compare. Type stvterm_rec. Required

Returns
Y if all values in the records are equal, otherwise N. Nulls match Nulls.


f_query_all

FUNCTION f_query_all(p_code               stvterm.stvterm_code%TYPE,
                     p_desc               stvterm.stvterm_desc%TYPE DEFAULT NULL,
                     p_start_date         stvterm.stvterm_start_date%TYPE DEFAULT NULL,
                     p_end_date           stvterm.stvterm_end_date%TYPE DEFAULT NULL,
                     p_fa_proc_yr         stvterm.stvterm_fa_proc_yr%TYPE DEFAULT NULL,
                     p_fa_term            stvterm.stvterm_fa_term%TYPE DEFAULT NULL,
                     p_fa_period          stvterm.stvterm_fa_period%TYPE DEFAULT NULL,
                     p_fa_end_period      stvterm.stvterm_fa_end_period%TYPE DEFAULT NULL,
                     p_acyr_code          stvterm.stvterm_acyr_code%TYPE DEFAULT NULL,
                     p_housing_start_date stvterm.stvterm_housing_start_date%TYPE DEFAULT NULL,
                     p_housing_end_date   stvterm.stvterm_housing_end_date%TYPE DEFAULT NULL,
                     p_system_req_ind     stvterm.stvterm_system_req_ind%TYPE DEFAULT NULL,
                     p_trmt_code          stvterm.stvterm_trmt_code%TYPE DEFAULT NULL)
  RETURN stvterm_ref

Selects all records for the entity.

Parameters
p_code   999999 - End of Time. VARCHAR2(6) Required Key
ALL other @params are Default NULL.

Returns
A cursor variable that will fetch the set of records.


f_query_one

FUNCTION f_query_one(p_code stvterm.stvterm_code%TYPE) RETURN stvterm_ref

Selects one record using the key.

Parameters
p_code   999999 - End of Time. VARCHAR2(6) Required Key

Returns
A cursor variable that will fetch exactly one record.


f_query_by_rowid

FUNCTION f_query_by_rowid(p_rowid VARCHAR2) RETURN stvterm_ref

Selects one record using the ROWID.

Parameters
p_rowid   Database ROWID of the record to be selected. VARCHAR2(18) Required

Returns
A cursor variable that will fetch exactly one record.


f_query_one_lock

FUNCTION f_query_one_lock(p_code  stvterm.stvterm_code%TYPE,
                          p_rowid VARCHAR2 DEFAULT NULL) RETURN stvterm_ref

Selects one record and locks it.

Parameters
p_code   999999 - End of Time. VARCHAR2(6) Required Key
p_rowid   Database ROWID of the record to be selected. VARCHAR2(18)

Returns
A cursor variable for one record, locking the record.


p_create

PROCEDURE p_create(p_code               stvterm.stvterm_code%TYPE,
                   p_desc               stvterm.stvterm_desc%TYPE,
                   p_start_date         stvterm.stvterm_start_date%TYPE,
                   p_end_date           stvterm.stvterm_end_date%TYPE,
                   p_fa_proc_yr         stvterm.stvterm_fa_proc_yr%TYPE DEFAULT NULL,
                   p_fa_term            stvterm.stvterm_fa_term%TYPE DEFAULT NULL,
                   p_fa_period          stvterm.stvterm_fa_period%TYPE DEFAULT NULL,
                   p_fa_end_period      stvterm.stvterm_fa_end_period%TYPE DEFAULT NULL,
                   p_acyr_code          stvterm.stvterm_acyr_code%TYPE,
                   p_housing_start_date stvterm.stvterm_housing_start_date%TYPE,
                   p_housing_end_date   stvterm.stvterm_housing_end_date%TYPE,
                   p_system_req_ind     stvterm.stvterm_system_req_ind%TYPE DEFAULT NULL,
                   p_trmt_code          stvterm.stvterm_trmt_code%TYPE DEFAULT NULL,
                   p_rowid_out          OUT VARCHAR2)

Creates a record.
 
NOTE: The Create API call is not supported for the current release.

Parameters
p_code   999999 - End of Time. VARCHAR2(6) Required Key
p_desc   Term associated with the term code. The term is identified by the academic year and term number in YYYYTT format. VARCHAR2(30) Required
p_start_date   Term start date in '||G$_DATE.GET_NLS_DATE_FORMAT||' format. DATE Required
p_end_date   Term end date in '||G$_DATE.GET_NLS_DATE_FORMAT||' format. DATE Required
p_fa_proc_yr   Financial aid processing start and end years (e.g., the financial aid processing year 2005 - 2006 is formatted 0506.). VARCHAR2(4)
p_fa_term   Financial aid award term. VARCHAR2(1)
p_fa_period   Financial aid award beginning period. NUMBER(2)
p_fa_end_period   Financial aid award ending period. NUMBER(2)
p_acyr_code   This column is not currently in use. VARCHAR2(4) Required
p_housing_start_date   Housing Start Date. DATE Required
p_housing_end_date   Housing End Date. DATE Required
p_system_req_ind   System Required Indicator. VARCHAR2(1)
p_trmt_code   Term type for this term. Will default from SHBCGPA_TRMT_CODE. VARCHAR2(1)
p_rowid_out   Database ROWID of the record to be created. VARCHAR2(18) Required


p_delete

PROCEDURE p_delete(p_code  stvterm.stvterm_code%TYPE,
                   p_rowid VARCHAR2 DEFAULT NULL)

Deletes a record.
 
NOTE: The Delete API call is not supported for the current release.

Parameters
p_code   999999 - End of Time. VARCHAR2(6) Required Key
p_rowid   Database ROWID of the record to be deleted. VARCHAR2(18)


p_lock

PROCEDURE p_lock(p_code        stvterm.stvterm_code%TYPE,
                 p_rowid_inout IN OUT VARCHAR2)

Locks a record.
If the ROWID is not passed in, the record is located using the key values and the ROWID of the locked row is passed in p_rowid_inout.

Parameters
p_code   999999 - End of Time. VARCHAR2(6) Required Key
p_rowid_inout   Database ROWID of the record to be locked. VARCHAR2(18) Required


p_update

PROCEDURE p_update(p_code               stvterm.stvterm_code%TYPE,
                   p_desc               stvterm.stvterm_desc%TYPE DEFAULT dml_common.f_unspecified_string,
                   p_start_date         stvterm.stvterm_start_date%TYPE DEFAULT dml_common.f_unspecified_date,
                   p_end_date           stvterm.stvterm_end_date%TYPE DEFAULT dml_common.f_unspecified_date,
                   p_fa_proc_yr         stvterm.stvterm_fa_proc_yr%TYPE DEFAULT dml_common.f_unspecified_string,
                   p_fa_term            stvterm.stvterm_fa_term%TYPE DEFAULT dml_common.f_unspecified_string,
                   p_fa_period          stvterm.stvterm_fa_period%TYPE DEFAULT dml_common.f_unspecified_number,
                   p_fa_end_period      stvterm.stvterm_fa_end_period%TYPE DEFAULT dml_common.f_unspecified_number,
                   p_acyr_code          stvterm.stvterm_acyr_code%TYPE DEFAULT dml_common.f_unspecified_string,
                   p_housing_start_date stvterm.stvterm_housing_start_date%TYPE DEFAULT dml_common.f_unspecified_date,
                   p_housing_end_date   stvterm.stvterm_housing_end_date%TYPE DEFAULT dml_common.f_unspecified_date,
                   p_system_req_ind     stvterm.stvterm_system_req_ind%TYPE DEFAULT dml_common.f_unspecified_string,
                   p_trmt_code          stvterm.stvterm_trmt_code%TYPE DEFAULT dml_common.f_unspecified_string,
                   p_rowid              VARCHAR2 DEFAULT NULL)

Updates a record.
 
NOTE: The Update API call is not supported for the current release.

Parameters
p_code   999999 - End of Time. VARCHAR2(6) Required Key
p_desc   Term associated with the term code. The term is identified by the academic year and term number in YYYYTT format. VARCHAR2(30) Required
p_start_date   Term start in '||G$_DATE.GET_NLS_DATE_FORMAT||' format. DATE Required
p_end_date   Term end date in '||G$_DATE.GET_NLS_DATE_FORMAT||' format. DATE Required
p_fa_proc_yr   Financial aid processing start and end years (e.g., the financial aid processing year 2005 - 2006 is formatted 0506.). VARCHAR2(4)
p_fa_term   Financial aid award term. VARCHAR2(1)
p_fa_period   Financial aid award beginning period. NUMBER(2)
p_fa_end_period   Financial aid award ending period. NUMBER(2)
p_acyr_code   This column is not currently in use. VARCHAR2(4) Required
p_housing_start_date   Housing Start Date. DATE Required
p_housing_end_date   Housing End Date. DATE Required
p_system_req_ind   System Required Indicator. VARCHAR2(1)
p_trmt_code   Term type for this term. Will default from SHBCGPA_TRMT_CODE. VARCHAR2(1)
p_rowid   Database ROWID of the record to be updated. VARCHAR2(18)