Table DistUnqTstEvent

Description of table DistUnqTstEvent

This table relates each district the Regional Warehouse Provider (RWP) supports to the specific test events those districts are allowed to access. This table makes it easy for the RWP to limit access to the appropriate set of tests for each of their districts. The RWP should replace the contents of this table on each extract. The RWP can use either the FIRS table or the DistUnqTstEvent table to limit the access to the data. This table can be directly joined to and does not need to be evaluated against the TstDt, EndDt and UpdtDt columns to be applied as the FIRS table does.


Code preview of table DistUnqTstEvent

use StudentCentered
go

if exists (select 1
from sysindexes
where id = object_id('DistUnqTstEvent')
and name = 'UnqTstEvent_FK'
and indid > 0
and indid < 255)
drop index DistUnqTstEvent.UnqTstEvent_FK
go

if exists (select 1
from sysindexes
where id = object_id('DistUnqTstEvent')
and name = 'DistInstID_IDX'
and indid > 0
and indid < 255)
drop index DistUnqTstEvent.DistInstID_IDX
go

if exists (select 1
from sysindexes
where id = object_id('DistUnqTstEvent')
and name = 'UnqDistUnqTstEvent_IDX'
and indid > 0
and indid < 255)
drop index DistUnqTstEvent.UnqDistUnqTstEvent_IDX
go

if exists (select 1
from sysobjects
where id = object_id('DistUnqTstEvent')
and type = 'U')
drop table DistUnqTstEvent
go

/*==============================================================*/
/* Table: DistUnqTstEvent */
/*==============================================================*/
create table DistUnqTstEvent (
DistInstID int not null,
UnqTstEvent_ID int not null
)
go

/*==============================================================*/
/* Index: UnqDistUnqTstEvent_IDX */
/*==============================================================*/
create unique index UnqDistUnqTstEvent_IDX on DistUnqTstEvent (
DistInstID,
UnqTstEvent_ID
)
go

/*==============================================================*/
/* Index: DistInstID_IDX */
/*==============================================================*/
create index DistInstID_IDX on DistUnqTstEvent (
DistInstID
)
go

/*==============================================================*/
/* Index: UnqTstEvent_FK */
/*==============================================================*/
create index UnqTstEvent_FK on DistUnqTstEvent (
UnqTstEvent_ID
)
go


List of columns of the table DistUnqTstEvent

Name

Code

District Institution Identifier

DistInstID

Unique Test Event Identifier

UnqTstEvent_ID


Column DistInstID of the table DistUnqTstEvent

Card of the column DistInstID of the table DistUnqTstEvent

Name

District Institution Identifier

Code

DistInstID

Data Type

int

Mandatory

TRUE


Description of the column DistInstID of the table DistUnqTstEvent

ID assigned and maintained by the Institution database.


Column UnqTstEvent_ID of the table DistUnqTstEvent

Card of the column UnqTstEvent_ID of the table DistUnqTstEvent

Name

Unique Test Event Identifier

Code

UnqTstEvent_ID

Data Type

int

Mandatory

TRUE


Description of the column UnqTstEvent_ID of the table DistUnqTstEvent

Foreign key from the Unique Test Event (UnqTstEvent) table. This identifier is used to locate all versions of a given test in tables throughout the StudentCentered database.