Siebel HelpDesk Guide > Setting Up Employee Self-Service > Designing Employee Self-Service Requestor Forms >
Preventing Duplicate Record Creation
When the form is submitted, field values mapped to a business component field are automatically written to the actual fields by SmartScript. To prevent the Siebel application from writing to the business component field and creating duplicate records, include the Cancel() function within the script_finish program.
To prevent duplicate record creation
- Navigate to the Site Map > Administration - SmartScript > Scripts view.
- In the Scripts list, select the script, and then click the Programs view tab.
- In the Programs list, select Script_Finish.
- In the Program Language field, select eScript, and then click Save.
- In the eScript field, include the
For example, the following statement runs the entire SmartScript, but no updates are saved to the database, even after the user chooses Submit.
function Script_Finish ()
// Cancel saving everything to the database
- To make sure that data entries are always saved, whether the form is complete or incomplete, select Always in the Save Session field.
When the form is complete, choose Finished to save data entries.
NOTE: Selecting Finished or Always from the Save Session field forces your Siebel application to write the values to the SmartScript session tables.
- Click Check Syntax to locate syntax issues, and save the record.