- Notifications
You must be signed in to change notification settings - Fork4.9k
Commit380dad2
committed
Don't require dynamic timezone abbreviations to match underlying time zone.
Previously, we threw an error if a dynamic timezone abbreviation did notmatch any abbreviation recorded in the referenced IANA time zone entry.That seemed like a good consistency check at the time, but it turns outthat a number of the abbreviations in the IANA database are things thatOlson and crew made up out of whole cloth. Their current policy is toremove such names in favor of using simple numeric offsets. Perhapsunsurprisingly, a lot of these made-up abbreviations have varied in meaningover time, which meant that our commitb2cbced and later changes madethem into dynamic abbreviations. So with newer IANA database versionsthat don't mention these abbreviations at all, we fail, as reported in bug#14307 from Neil Anderson. It's worse than just a few unused-in-the-wildabbreviations not working, because the pg_timezone_abbrevs view stopsworking altogether (since its underlying function tries to compute thewhole view result in one call).We considered deleting these abbreviations from our abbreviations list, butthe problem with that is that we can't stay ahead of possible future IANAchanges. Instead, let's leave the abbreviations list alone, and treat any"orphaned" dynamic abbreviation as just meaning the referenced time zone.It will behave a bit differently than it used to, in that you can't anylonger override the zone's standard vs. daylight rule by using the "wrong"abbreviation of a pair, but that's better than failing entirely. (Also,this solution can be interpreted as adding a small new feature, which isthat any abbreviation a user wants can be defined as referencing a timezone name.)Back-patch to all supported branches, since this problem affects allof them when using tzdata 2016f or newer.Report: <20160902031551.15674.67337@wrigleys.postgresql.org>Discussion: <6189.1472820913@sss.pgh.pa.us>1 parente3439a4 commit380dad2
File tree
5 files changed
+132
-32
lines changed- doc/src/sgml
- src
- backend/utils/adt
- test/regress
- expected
- sql
5 files changed
+132
-32
lines changedLines changed: 7 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
8225 | 8225 |
| |
8226 | 8226 |
| |
8227 | 8227 |
| |
| 8228 | + | |
| 8229 | + | |
| 8230 | + | |
| 8231 | + | |
| 8232 | + | |
| 8233 | + | |
| 8234 | + | |
8228 | 8235 |
| |
8229 | 8236 |
| |
8230 | 8237 |
| |
|
Lines changed: 30 additions & 11 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
384 | 384 |
| |
385 | 385 |
| |
386 | 386 |
| |
387 |
| - | |
388 |
| - | |
389 |
| - | |
390 |
| - | |
391 |
| - | |
392 |
| - | |
393 |
| - | |
394 |
| - | |
395 |
| - | |
396 |
| - | |
397 |
| - | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
398 | 393 |
| |
399 | 394 |
| |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
400 | 419 |
| |
401 | 420 |
| |
402 | 421 |
| |
|
Lines changed: 64 additions & 21 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
53 | 53 |
| |
54 | 54 |
| |
55 | 55 |
| |
56 |
| - | |
57 |
| - | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
58 | 59 |
| |
59 | 60 |
| |
60 | 61 |
| |
| |||
1602 | 1603 |
| |
1603 | 1604 |
| |
1604 | 1605 |
| |
| 1606 | + | |
| 1607 | + | |
| 1608 | + | |
1605 | 1609 |
| |
1606 | 1610 |
| |
1607 | 1611 |
| |
1608 | 1612 |
| |
1609 | 1613 |
| |
| 1614 | + | |
| 1615 | + | |
| 1616 | + | |
1610 | 1617 |
| |
1611 | 1618 |
| |
1612 | 1619 |
| |
1613 | 1620 |
| |
1614 | 1621 |
| |
1615 |
| - | |
| 1622 | + | |
1616 | 1623 |
| |
1617 |
| - | |
| 1624 | + | |
| 1625 | + | |
| 1626 | + | |
| 1627 | + | |
| 1628 | + | |
| 1629 | + | |
| 1630 | + | |
| 1631 | + | |
| 1632 | + | |
| 1633 | + | |
| 1634 | + | |
| 1635 | + | |
| 1636 | + | |
| 1637 | + | |
| 1638 | + | |
| 1639 | + | |
1618 | 1640 |
| |
1619 | 1641 |
| |
1620 | 1642 |
| |
| |||
1628 | 1650 |
| |
1629 | 1651 |
| |
1630 | 1652 |
| |
| 1653 | + | |
| 1654 | + | |
| 1655 | + | |
| 1656 | + | |
| 1657 | + | |
1631 | 1658 |
| |
1632 |
| - | |
| 1659 | + | |
| 1660 | + | |
| 1661 | + | |
| 1662 | + | |
| 1663 | + | |
| 1664 | + | |
| 1665 | + | |
| 1666 | + | |
| 1667 | + | |
| 1668 | + | |
| 1669 | + | |
| 1670 | + | |
| 1671 | + | |
| 1672 | + | |
| 1673 | + | |
| 1674 | + | |
| 1675 | + | |
| 1676 | + | |
1633 | 1677 |
| |
1634 | 1678 |
| |
1635 | 1679 |
| |
1636 | 1680 |
| |
1637 | 1681 |
| |
1638 | 1682 |
| |
1639 |
| - | |
| 1683 | + | |
1640 | 1684 |
| |
1641 |
| - | |
1642 |
| - | |
1643 |
| - | |
| 1685 | + | |
| 1686 | + | |
| 1687 | + | |
1644 | 1688 |
| |
1645 | 1689 |
| |
1646 | 1690 |
| |
| |||
1652 | 1696 |
| |
1653 | 1697 |
| |
1654 | 1698 |
| |
1655 |
| - | |
1656 |
| - | |
1657 |
| - | |
1658 |
| - | |
1659 |
| - | |
1660 |
| - | |
1661 |
| - | |
1662 |
| - | |
1663 |
| - | |
1664 |
| - | |
1665 |
| - | |
1666 |
| - | |
| 1699 | + | |
| 1700 | + | |
| 1701 | + | |
| 1702 | + | |
| 1703 | + | |
| 1704 | + | |
| 1705 | + | |
| 1706 | + | |
| 1707 | + | |
| 1708 | + | |
| 1709 | + | |
1667 | 1710 |
| |
1668 | 1711 |
| |
1669 | 1712 |
| |
|
Lines changed: 20 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2345 | 2345 |
| |
2346 | 2346 |
| |
2347 | 2347 |
| |
| 2348 | + | |
| 2349 | + | |
| 2350 | + | |
| 2351 | + | |
| 2352 | + | |
| 2353 | + | |
| 2354 | + | |
| 2355 | + | |
| 2356 | + | |
| 2357 | + | |
| 2358 | + | |
| 2359 | + | |
| 2360 | + | |
| 2361 | + | |
| 2362 | + | |
| 2363 | + | |
| 2364 | + | |
| 2365 | + | |
| 2366 | + | |
| 2367 | + |
Lines changed: 11 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
379 | 379 |
| |
380 | 380 |
| |
381 | 381 |
| |
| 382 | + | |
| 383 | + | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + |
0 commit comments
Comments
(0)