The following lines contain the word 'select', 'insert', 'update' or 'delete':
X_Price_Update_Tolerance NUMBER,
X_Global_Attribute_Category VARCHAR2,
X_Global_Attribute1 VARCHAR2,
X_Global_Attribute2 VARCHAR2,
X_Global_Attribute3 VARCHAR2,
X_Global_Attribute4 VARCHAR2,
X_Global_Attribute5 VARCHAR2,
X_Global_Attribute6 VARCHAR2,
X_Global_Attribute7 VARCHAR2,
X_Global_Attribute8 VARCHAR2,
X_Global_Attribute9 VARCHAR2,
X_Global_Attribute10 VARCHAR2,
X_Global_Attribute11 VARCHAR2,
X_Global_Attribute12 VARCHAR2,
X_Global_Attribute13 VARCHAR2,
X_Global_Attribute14 VARCHAR2,
X_Global_Attribute15 VARCHAR2,
X_Global_Attribute16 VARCHAR2,
X_Global_Attribute17 VARCHAR2,
X_Global_Attribute18 VARCHAR2,
X_Global_Attribute19 VARCHAR2,
X_Global_Attribute20 VARCHAR2,
x_new_print_count OUT NOCOPY NUMBER,
x_new_printed_date OUT NOCOPY DATE,
p_shipping_control IN VARCHAR2 --
,p_conterms_exist_flag IN VARCHAR2 --
,p_encumbrance_required_flag IN VARCHAR2 --
) IS
CURSOR C IS
SELECT *
FROM PO_HEADERS
WHERE rowid = X_Rowid
FOR UPDATE of Po_Header_Id NOWAIT;
FND_MESSAGE.Set_Name('FND', 'FORM_RECORD_DELETED');
AND ( (Recinfo.Price_Update_Tolerance = X_Price_Update_Tolerance)
OR ( (Recinfo.Price_Update_Tolerance IS NULL)
AND (X_Price_Update_Tolerance IS NULL)))
AND ( (Recinfo.global_attribute_category = X_Global_Attribute_Category)
OR ( (Recinfo.global_attribute_category IS NULL)
AND (X_Global_Attribute_Category IS NULL)))
AND ( (Recinfo.global_attribute1 = X_Global_Attribute1)
OR ( (Recinfo.global_attribute1 IS NULL)
AND (X_Global_Attribute1 IS NULL)))
AND ( (Recinfo.global_attribute2 = X_Global_Attribute2)
OR ( (Recinfo.global_attribute2 IS NULL)
AND (X_Global_Attribute2 IS NULL)))
AND ( (Recinfo.global_attribute3 = X_Global_Attribute3)
OR ( (Recinfo.global_attribute3 IS NULL)
AND (X_Global_Attribute3 IS NULL)))
AND ( (Recinfo.global_attribute4 = X_Global_Attribute4)
OR ( (Recinfo.global_attribute4 IS NULL)
AND (X_Global_Attribute4 IS NULL)))
AND ( (Recinfo.global_attribute5 = X_Global_Attribute5)
OR ( (Recinfo.global_attribute5 IS NULL)
AND (X_Global_Attribute5 IS NULL)))
AND ( (Recinfo.global_attribute6 = X_Global_Attribute6)
OR ( (Recinfo.global_attribute6 IS NULL)
AND (X_Global_Attribute6 IS NULL)))
AND ( (Recinfo.global_attribute7 = X_Global_Attribute7)
OR ( (Recinfo.global_attribute7 IS NULL)
AND (X_Global_Attribute7 IS NULL)))
AND ( (Recinfo.global_attribute8 = X_Global_Attribute8)
OR ( (Recinfo.global_attribute8 IS NULL)
AND (X_Global_Attribute8 IS NULL)))
AND ( (Recinfo.global_attribute9 = X_Global_Attribute9)
OR ( (Recinfo.global_attribute9 IS NULL)
AND (X_Global_Attribute9 IS NULL)))
AND ( (Recinfo.global_attribute10 = X_Global_Attribute10)
OR ( (Recinfo.global_attribute10 IS NULL)
AND (X_Global_Attribute10 IS NULL)))
AND ( (Recinfo.global_attribute11 = X_Global_Attribute11)
OR ( (Recinfo.global_attribute11 IS NULL)
AND (X_Global_Attribute11 IS NULL)))
AND ( (Recinfo.global_attribute12 = X_Global_Attribute12)
OR ( (Recinfo.global_attribute12 IS NULL)
AND (X_Global_Attribute12 IS NULL)))
AND ( (Recinfo.global_attribute13 = X_Global_Attribute13)
OR ( (Recinfo.global_attribute13 IS NULL)
AND (X_Global_Attribute13 IS NULL)))
AND ( (Recinfo.global_attribute14 = X_Global_Attribute14)
OR ( (Recinfo.global_attribute14 IS NULL)
AND (X_Global_Attribute14 IS NULL)))
AND ( (Recinfo.global_attribute15 = X_Global_Attribute15)
OR ( (Recinfo.global_attribute15 IS NULL)
AND (X_Global_Attribute15 IS NULL)))
AND ( (Recinfo.global_attribute16 = X_Global_Attribute16)
OR ( (Recinfo.global_attribute16 IS NULL)
AND (X_Global_Attribute16 IS NULL)))
AND ( (Recinfo.global_attribute17 = X_Global_Attribute17)
OR ( (Recinfo.global_attribute17 IS NULL)
AND (X_Global_Attribute17 IS NULL)))
AND ( (Recinfo.global_attribute18 = X_Global_Attribute18)
OR ( (Recinfo.global_attribute18 IS NULL)
AND (X_Global_Attribute18 IS NULL)))
AND ( (Recinfo.global_attribute19 = X_Global_Attribute19)
OR ( (Recinfo.global_attribute19 IS NULL)
AND (X_Global_Attribute19 IS NULL)))
AND ( (Recinfo.global_attribute20 = X_Global_Attribute20)
OR ( (Recinfo.global_attribute20 IS NULL)
AND (X_Global_Attribute20 IS NULL)))
) then
-- Bug 2701425. If print_count and printed_date are different, then
-- update the new parameters with the values from the database.
IF (nvl(recinfo.print_count,-99) <> nvl(x_print_count,-99)) THEN
x_new_print_count := recinfo.print_count;