﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc	db_engine	os_version
1195	Consider making DISCARD code DISCARDED in INVENTORY_AVAILABILITY_STATUS group	Mark J. Millard	dbmuqs	"The code DISCARDED is missing in the code table and is used by GSOR in the Availability Status field on 320 records.  The code DISCARD meaning Discarded is used by 14,340 inventory records.  Can these records use the same code.  Is DISCARDED more appropriate.  The administrator tool can change all records using DISCARD to DISCARDED without much effort.

The records using these codes can be found in the search tool on the inventory dataview:

@inventory.availability_status_code = 'DISCARD'

@inventory.availability_status_code = 'DISCARDED'

The missing code was found using this SQL:

SELECT inventory.availability_status_code, last_name, COUNT(inventory.availability_status_code) reccount FROM inventory JOIN cooperator on cooperator.cooperator_id = inventory.owned_by WHERE inventory.availability_status_code NOT IN (SELECT value FROM code_value WHERE group_name = 'INVENTORY_AVAILABILITY_STATUS') GROUP BY inventory.availability_status_code, last_name ORDER BY inventory.availability_status_code, last_name

"	defect	closed	critical	Post-NPGS Prod'n	Database, Custom Reports	1.9.4 Server		fixed	codes	lisa.burke@…	SQL Server	Windows 7 Ultimate 64 bit
