If a defect has been created in error, it can only be "undone" through SQL. These are the statements required:

BEGIN
  delete from nxslink where related_topic = 'DFCT' and related_id = :defectnum;
  delete from nxslink where related_topic = 'CASE' and id = :defectnum;
  delete from nxsnotes where topic = 'DFCT' and id = :defectnum;
  delete from nxsdfct where defect_num = :defectnum;
  update nxstar_e set udf2 = NULL, priority=decode(udf4,'1 - A+',10,'2 - A',20,'3 - B',30,'4 - C',50,60) where udf2 = :defectnum;
  commit;
end;

HighLine.Standard Operating Procedures