PHYSICAL_ASSIGNMENT_TS
Package PHYSICAL_ASSIGNMENT_TS
physical_assignment_ts.pks
Copyright by Donald J. Bales on 12/15/2006
Table PHYSICAL_ASSIGNMENT_T's methods
Global Constants and Variables
Keep track of the number of inserts and updates to made by set_row().
n_inserted number := 0;
n_updated number := 0;
Method Summary
get_id
Returns a new primary key id value for a row
get_physical_workplace
Returns a the PHYSICAL_WORKPLACE row for the specified worker_id and on the specified date
get_physical_workplace
Returns a the current PHYSICAL_WORKPLACE row for the specified worker_id
get_row
Returns a PHYSICAL_ASSIGNMENT row for the specified criteria
help
Test-based help for this package
is_active
Returns TRUE if the worker has a physical assignment on the specified date, otherwise FALSE
is_active
Returns TRUE if the worker currently has a physical assignment, otherwise FALSE
set_row
Updates or inserts a row matching the passed row into table PHYSICAL_WORKPLACE_T
test
The test unit for this package
Method Detail
get_id
FUNCTION get_id
return PHYSICAL_ASSIGNMENT_T.id%TYPE
Returns a new primary key id value for a row.
get_physical_workplace
FUNCTION get_physical_workplace(
ain_worker_id in PHYSICAL_ASSIGNMENT_T.worker_id%TYPE,
aid_on in PHYSICAL_ASSIGNMENT_T.active_date%TYPE)
return PHYSICAL_WORKPLACE_T%ROWTYPE
Returns a the PHYSICAL_WORKPLACE row for the specified worker_id and on the specified date.
get_physical_workplace
FUNCTION get_physical_workplace(
ain_worker_id in PHYSICAL_ASSIGNMENT_T.worker_id%TYPE)
return PHYSICAL_WORKPLACE_T%ROWTYPE
Returns a the current PHYSICAL_WORKPLACE row for the specified worker_id.
get_row
FUNCTION get_row(
air_physical_assignment in PHYSICAL_ASSIGNMENT_T%ROWTYPE)
return PHYSICAL_ASSIGNMENT_T%ROWTYPE
Returns a PHYSICAL_ASSIGNMENT row for the specified criteria.
There are two sets of criteria. You can retrieve a row by specifying:
1. the primary key: id
2. the woker_id and active_date
If a match is found the function returns the corresponding row, otherwise
it returns NULL. It will raise any exceptions except NO_DATA_FOUND.
help
PROCEDURE help
Test-based help for this package. "set serveroutput on" in SQL*Plus.
is_active
FUNCTION is_active(
ain_worker_id in PHYSICAL_ASSIGNMENT_T.worker_id%TYPE,
aid_on in date)
return boolean
Returns TRUE if the worker has a physical assignment on the specified date, otherwise FALSE.
is_active
FUNCTION is_active(
ain_worker_id in PHYSICAL_ASSIGNMENT_T.worker_id%TYPE)
return boolean
Returns TRUE if the worker currently has a physical assignment, otherwise FALSE.
set_row
PROCEDURE set_row(
aior_physical_assignment in out PHYSICAL_ASSIGNMENT_T%ROWTYPE)
Updates or inserts a row matching the passed row into table PHYSICAL_WORKPLACE_T.
First, set_row( ) calls get_row( ) to try to find a matching row that already
exists in the database. So you need to set the id, or worked_id
and active_date appropriately in order to properly detect an existing row.
Next, if an existing row is found, any non-key data items are updated to match
the passed row. Otherwise a new row is inserted, including the allocation of
a new primary key value. Upon inserting a new value, the id
value is updated in the passed row.
See PROCEDURE get_row( );
test
PROCEDURE test
The test unit for this package.
Wyszukiwarka
Podobne podstrony:
physical workplace tswork assignment tslogical assignment tslo orm2 tsAlbert Einstein Principles Of Theoretical PhysicsAnaxagoras # Vlastos (The Physical Theory Of Anaxagoras) BbZielony Szerszeń 2010 TS XViD IMAGiNEschedule and assign workcD7C4DFCisco2 AssignmentsFanuc 3TF Tak TS LTM L263 82 2Physical Constants 2001Feynman Lectures on Physics Volume 1 ChapterUlotka postępowanie przed TS, procedura i dokumentyassignmenttypeassignmenttypeassignments view done textassignablewięcej podobnych podstron