在时钟更改时提交 dba_job
快速查询一下,我正在通过 dbms_job.submit() 提交一个 oracle 作业。然而,我正处于时钟更改 BST->GMT 期间,我希望我的工作在 1:30 GMT 执行。鉴于 DBA 作业倾向于处理日期,那么我的作业实际上会在什么时间运行?
1:30 BST(早了一小时)
或
1:30 GMT(正好谢谢)
,如果是前者,有没有办法让它按照我的预期工作?
谢谢
CJC
A quick query, I'm submitting an oracle job via dbms_job.submit(). However I am in the middle of a clock change BST->GMT and I want my job to execute at 1:30 GMT. Given that DBA Jobs tends to deal with dates, at what time would my job actually run?
1:30 BST (an hour too early)
or
1:30 GMT (just right thanks)
and if it's the former, is there a way to make it work as I'm expecting?
Thanks
CJC
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
DBMS_JOB 不支持计划运行的时区或夏令时。
时钟更改发生在 02:00,此时 02:00 变为 03:00(但在这种情况下,02:00 GMT 变为 02:00 BST)。这意味着您的作业将在 01:30 GMT 运行,因为时钟直到 02:00 才会更改,但是在夏令时更改之后(因此从第二天早上开始),您的作业将在 01:30 BST (00:30 GMT) 运行,因为 DBMS_JOB 不知道任何时间更好,比你想要的早一个小时。
如果您希望计划始终以 GMT 运行或希望获得 DST 支持,请转至 DBA_SCHEDULER,您可以将时间指定为 01h30 GMT +0 并使其始终执行,而不管其他情况。
DBMS_JOB doesn't support time zones or daylight savings time for scheduled runs.
The clock change happens at 02h00 when 02h00 becomes 03h00 (but also in this case 02h00 GMT becomes 02h00 BST). This means your job will run at 01h30 GMT because the clocks won't change until 02h00, however following the daylight saving change (so from the next morning) your job will run at 01h30 BST (00h30 GMT) since DBMS_JOB doesn't know any better, an hour earlier than you might want.
Move to DBA_SCHEDULER instead if you want schedules that always run in GMT or want to have DST support, where the you can specify the time as 01h30 GMT +0 and have it always execute then regardless of anything else.