data-dictionary

FPSAPP.GEN_REF_DATA_DATE

Data Dictionary

>

FPSAPP Views

> FPSAPP.WIP_WAFER_HIST_LOOP

View FPSBASE.GEN_REF_DATA_DATE

This caches DATA_DATE into a table for faster querying since DATA_DATE used so frequently. It also includes the shift and week information associated with DATA_DATE. See comments in CURR_DATE function for more information. Using (end_shift - start_shift) allows this view to work for any length shift. Same for (end_week - start_week) although if a customer has weeks of lengths other than 7 days that would be rather interesting. We use max in this view for two reasons. First to tell the compiler there is only one row. Second to we will always get a row returned even if data_date_value is not in CAL_SHIFTS or cal_work_weeks which will result in a not null error. Also for some strange reason this version is much faster with max(inst) from WIP_EVENT_HIST repeated three times rather than in a with clause. Sailboat racing! Finally we use data_date_value as to avoid confusion with the function data_date.

Column

Comment

DATA_DATE_VALUE

This column is unusually named DATA_DATE_VALUE to avoid confusion with the frequently used DATA_DATE function. Normally we just use the function but occasionally we might want to get the column from the table rather than the function and this allows us to do this. (* inherited from FPSBASE.GEN_DATA_DATE)