+2712 88 00 258
KB20200519/01: Sage X3 Tip & Trick – How To Setup Job In Microsoft SQL to email recipients when journals have been on hold for longer than 10 minutes
Prerequisites:
- SQL Server Agent Service must be running at all times
- SMTP Relay account needs to be setup on the SQL Server
Step 1: Create new SQL Server Job
- General Tab Name the Task etc. “Accouting Tasks not running”
- Category: Data Collector
- Add description
- Ensure the Job is enabled
Step 2: Create the Email Step
- Input the Step name etc. Email
- Type: Transact-SQL script (T-SQL)
- Leave the Database on master then just the declared db in the ‘Command’
- In the Command box input like below, update the Database and Shema name
- Replace everything highlighted in Red (the @profile_name will be your Database mail profile)
Step 3: Adding the Schedule
- Set the Frequency to Daily and set Recurs to 1
- Then set Occurs to any amount of time you wish to check
- Once done just press Ok and Ok again in order to Save the Job
- You will see the new Job has been added to the SQL Server Agent