323: l_pval_value VARCHAR2(2000);
324: l_position NUMBER;
325: l_temp VARCHAR2(2000);
326:
327: --Cursor compares the user key word to HR_DU_COLUMN_MAPPINGS
328: --in the main header for all API's
329: CURSOR csr_dollar_key IS
330: SELECT des.VALUE
331: FROM hr_du_descriptors des,
334: AND head.upload_id = des.upload_id
335: AND des.upload_header_id IS NULL
336: AND upper(des.descriptor) = upper(l_pval_value);
337:
338: --Cursor compares the user key word to HR_DU_COLUMN_MAPPINGS
339: --in the specific API header
340: CURSOR csr_dollar_key_api IS
341: SELECT VALUE
342: FROM hr_du_descriptors
343: WHERE upload_header_id = p_upload_header_id
344: AND upper(descriptor) = upper(l_pval_value);
345:
346:
347: --Cursor compares the user key word to HR_DU_COLUMN_MAPPINGS
348: CURSOR csr_user_key IS
349: SELECT column_name
350: FROM hr_du_column_mappings col,
351: hr_du_upload_headers head
346:
347: --Cursor compares the user key word to HR_DU_COLUMN_MAPPINGS
348: CURSOR csr_user_key IS
349: SELECT column_name
350: FROM hr_du_column_mappings col,
351: hr_du_upload_headers head
352: WHERE upper(col.column_name) = upper(l_pval_value)
353: AND head.upload_header_id = p_upload_header_id
354: AND head.api_module_id = col.api_module_id;
375: l_position := INSTRB(l_pval_value, '%');
376:
377: IF l_position = 0 THEN
378: --Not quoted string so it's will be treated as a column heading
379: --checks this against the HR_DU_COLUMN_MAPPINGS
380: OPEN csr_user_key;
381: FETCH csr_user_key INTO l_temp;
382: IF csr_user_key%NOTFOUND THEN
383: l_fatal_error_message := 'Column on user key does not exist in '||
380: OPEN csr_user_key;
381: FETCH csr_user_key INTO l_temp;
382: IF csr_user_key%NOTFOUND THEN
383: l_fatal_error_message := 'Column on user key does not exist in '||
384: 'HR_DU_COLUMN_MAPPINGS';
385: RAISE e_fatal_error;
386: END IF;
387: CLOSE csr_user_key;
388: --