- Decide whether to set up a cron job for automatic execution.
- Provide a cron schedule:
- Format: * * * * * (minute, hour, day-of-month, month, day-of-week).
- Example for daily execution at 2 AM: 0 2 * * *
- To check scheduling logs, the file 'procore_scheduling.log' will be created as soon as scheduling is set up.
You can also check scheduling by running in terminal command:
For Linux and MacOs:
To edit/delete - edit scheduling cron by using:
```bash
EDITOR=nano crontab -e
```
- After running the command above, you should see something similar to:
- 2 * * * * /Users/your_user/snowflake/venv/bin/python /Users/your_user/snowflake/sql_server_python/connection_config.py 2>&1 | while read line; do echo "$(date) - $line"; done >> /Users/your_user/snowflake/sql_server_python/procore_scheduling.log # procore-data-import
- You also can adjust schedule cron or delete the whole line to stop it running by schedule.
For Windows:
- Check the schedule task is created:
```powershell
schtasks /query /tn "ProcoreDeltaShareScheduling" /fo LIST /v
```
- To edit/delete - scheduling task:
Open the Task Scheduler:
- Press Win + R, type taskschd.msc, and press Enter.
- Navigate to the scheduled tasks.
- In the left pane, expand the Task Scheduler Library.
- Look for the folder where your task is saved (e.g., Task Scheduler Library or a custom folder).
- Find your task:
- Look for the task name ProcoreDeltaShareScheduling.
- Click on it to view its details in the bottom pane.
- Verify its schedule:
- Check the Triggers tab to see when the task is set to run.
- Check the History tab to confirm recent runs.
- To delete task:
- Delete task from the GUI.
Immediate Execution question:
- Option to run script for copying data immediately after configuration.
- After generating the config.yaml, the CLI is ready to be run anytime independently, by running script for copying data, depending on your package. See examples below:
python delta_share_to_azure_panda.py
OR
python delta_share_to_sql_spark.py
OR
python delta_share_to_azure_dfs_spark.py