SQL View Name:part_used_view
SQL View Number:6029
Group:Logistics
Base Table:part_used
Description:Display parts used
Flags:VIEW_OPTIMIZED 
Baseline/Custom:Baseline

Fields:

Field NameCommon TypeDatabase TypeGeneric Field IDArray SizeDefaultFlagsComment
case_id_numberCHARvarchar 255  Case number for transaction 
detail_numberCHARvarchar420  The part request number for the part used action. Same as the part request, detail number 
dom_at_domainLONGint   DIRECT Bin must be included in another domain? 0=no, 1=yes 
dom_at_partsLONGint   DIRECT Domain allows parts to be installed under other parts in the Site Configuration Manager; i.e., 0=no, 1=yes 
dom_at_siteLONGint   DIRECT Part may be installed at either site or under another part. 0=no, 1=yes 
dom_bomsLONGint   DIRECT Allow part to be included in BOMs; i.e., 0=no, 1=yes 
dom_catalogsLONGint   DIRECT Allow part to be included in BOMs; i.e., 0=no, 1=yes 
dom_is_serviceLONGint   DIRECT Indicates the part is a service part, if selected, sit_prt_role will be set when installed; i.e., 0=not a service, 1=a service, default=0 
dom_pt_used_bomLONGint   DIRECT During parts-used transactions, force part installation to conform to BOM; i.e., 0=no, 1=yes 
dom_pt_used_domLONGint   DIRECT Apply domain rules during parts-used transactions; i.e., 0=no, 1=yes 
dom_pt_used_warnLONGint   DIRECT Warning for parts used 
dom_serialnoLONGint   DIRECT Serial number's degree of uniqueness; i.e., 0=no serial numbers, tracked only by quantity, 1=unique across all part numbers, 2=unique within a part number, 3=not unique 
dom_uniquesnLONGint   DIRECT For any given site, serial number must be unique for all part numbers; i.e., 0=no, 1=yes 
dtl_condtnCHARvarchar 80  Used for temporary storage of the related part request's condition 
failure_statusCHARvarchar 40  Failure code for the removed part 
incl_domainCHARvarchar 40  Domain of the part under which the current part must be installed. If empty, part may be installed directly under the site 
ins_trans_typeLONGsmallint   DIRECT Install directly at site or not 
inst_activeCHARvarchar 10  Installed part state; i.e., active/inactive/obsolete 
inst_mod_levelCHARvarchar 10  Installed part revision 
inst_model_numCHARvarchar 20  Installed part marketing model number of the part; within family and line 
inst_nameCHARvarchar 255  Installed part maps to sales and mfg systems 
inst_part_numberCHARvarchar 30  Installed part number/name 
inst_part_typeCHARvarchar 40  Installed part domain name 
inst_pmh_objidLONGint   DIRECT Installed part number internal record number 
inst_pmlobjidLONGint   DIRECT Installed part revision internal record number 
install_qtyLONGint   DIRECT Number of parts installed 
install_serialCHARvarchar 30  Serial number of the installed part 
inv_statusCHARvarchar 20  Status of the inventory update for the part used activity; i.e., new=not attempted, failed=attempted and failed, complete=completed successfully 
invoice_noCHARvarchar 30  Installed part invoice number 
is_sppt_progLONGtinyint   DIRECT Indicates application category of the part: i.e., 0=physical part, 1=service part, 2=product literature 
login_nameCHARvarchar 30  User login name 
objidLONGint3  DIRECT Part used internal record number 
parent_part_objidLONGint   DIRECT Parent part internal record number 
part_priceDECIMALdecimal (19,4)    The price from the part request 
part_used_dateCLK_TIMEdatetime    Date/time of transaction 
pinst_objidLONGint   DIRECT Installed part internal record number 
prd_inst_nameCHARvarchar 80  Installed part name 
priceCHARvarchar 20  Price of the part 
remove_modCHARvarchar 10  Revision level of the removed part 
remove_prt_nameCHARvarchar 255  Part description of removed part 
remove_prt_numCHARvarchar 30  Part number of removed part 
remove_qtyLONGint   DIRECT Number of parts removed 
remove_serialCHARvarchar 30  Serial number of the removed part 
serial_noCHARvarchar 30  Installed part serial number 
sn_trackLONGint   DIRECT Track part for serialization; i.e., 0=by quantity, 1=by serial number 
statusCHARvarchar 10  Status of the transaction 
trans_typeCHARvarchar 20  Transaction type; i.e., exchange/consume 
user_objidLONGint   DIRECT User internal record number 

SQL:

(
select objid, inst_pmlobjid, inst_name, inst_part_type, prd_inst_name, inst_active,
inst_pmh_objid, serial_no, invoice_no, pinst_objid, inst_part_number, inst_mod_level, inst_model_num,
price, install_serial, remove_serial, status, failure_status, install_qty, remove_qty, part_used_date, trans_type, remove_prt_num,
remove_prt_name, remove_mod, case_id_number, detail_number, inv_status, dtl_condtn,
ins_trans_type, part_price, parent_part_objid, login_name, user_objid,
sn_track, dom_serialno, dom_uniquesn, dom_catalogs, dom_boms, dom_at_site, dom_at_parts,
dom_at_domain, dom_pt_used_bom, dom_pt_used_dom, dom_pt_used_warn, incl_domain, is_sppt_prog, dom_is_service
from table_prtuse_view1
union
select objid, inst_pmlobjid, '' as inst_name, '' as inst_part_type, prd_inst_name, '' as inst_active,
0 as inst_pmh_objid, serial_no, invoice_no, pinst_objid, '' as inst_part_number, '' as inst_mod_level, '' as inst_model_num,
price, install_serial, remove_serial, status, failure_status, install_qty, remove_qty, part_used_date, trans_type, remove_prt_num,
remove_prt_name, remove_mod, case_id_number, detail_number, inv_status, dtl_condtn,
ins_trans_type, part_price, parent_part_objid, login_name, user_objid,
0 as sn_track, 0 as dom_serialno, 0 as dom_uniquesn, 0 as dom_catalogs, 0 as dom_boms, 0 as dom_at_site, 0 as dom_at_parts,
0 as dom_at_domain, 0 as dom_pt_used_bom, 0 as dom_pt_used_dom, 0 as dom_pt_used_warn, '' as incl_domain, 0 as is_sppt_prog, 0 as dom_is_service
from table_prtuse_view2
where inst_pmlobjid is null
)
My Recent Objects
part_used_view