You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The `cron.schedule_in_database` function runs jobs as the user who created them. Therefore, you need to connect as said user to execute the job. This function does not allow specifying a different user, as it would require superuser privileges.
156
+
</Message>
159
157
160
-
Note that cron.schedule_in_database runs jobs as the user who created them, so you'll need to connect as that user to execute the job.
161
-
Additionally, this function doesn't allow specifying a different user, as it would require superuser privileges.
162
158
163
-
**Editing Jobs**
159
+
## Editing Jobs
164
160
165
-
To edit a job, you can use the `alter_job` function:
161
+
To edit a job, you can use the `alter_job` function.
Schedules in `pgcron` use the standard Cron syntax:
176
172
177
173
```
178
174
┌───────────── min (0 - 59)
@@ -186,6 +182,20 @@ The schedule uses the standard cron syntax:
186
182
* * * * *
187
183
```
188
184
189
-
**Time Zone**
185
+
<Messagetype="tip">
186
+
Refer to the [Cron schedules reference](/serverless-jobs/reference-content/cron-schedules/) for a detailed explanation of the cron format and examples.
187
+
</Message>
188
+
189
+
### How to configure your schedule timezone
190
+
191
+
The time zone of the `pg_cron` extension can be changed in the advanced settings of the Database Instance. By default, the time zone is set to GMT.
190
192
191
-
The time zone of the pg_cron extension can be changed in the advanced settings of the instance: `cron.timezone`. By default, the time zone is set to GMT.
193
+
1. Go to the **Advanced settings** of your Database Instance in the Scaleway console.
194
+
2. Click <Iconname="edit" />.
195
+
3. Click **+ Add parameters**.
196
+
4. Select `cron.timezone` in the drop-down.
197
+
5. Enter the time zone of your choice.
198
+
6. Click <Iconname="validate" /> to validate.
199
+
<Messagetype="note">
200
+
The configuration takes a few seconds to be applied. During this time the Database Instance connection remains uninterrupted. However, you must wait until the new configuration is applied to edit your advanced settings again.
0 commit comments