Tips for handling timezones in Postgres

  Рет қаралды 5,146

Aaron Francis

Aaron Francis

Күн бұрын

Пікірлер: 35
@mehdi_sadeghi
@mehdi_sadeghi 2 күн бұрын
Dude, when you were teaching MySQL back then, I really wished you’d do Postgres. Now that it’s happening, I’m really happy!
@aarondfrancis
@aarondfrancis 2 күн бұрын
❤️ the universe conspired
@MrZax-kl5si
@MrZax-kl5si 2 күн бұрын
These videos are the best. Keep pumping this content Aaron
@saryakan
@saryakan 2 күн бұрын
Best tip on handling time zones? Don't.
@additionaddict5524
@additionaddict5524 2 күн бұрын
aaron is the godfather
@jrheaberlin
@jrheaberlin 2 күн бұрын
What client are you using?
@aarondfrancis
@aarondfrancis 2 күн бұрын
TablePlus!
@Voltra_
@Voltra_ 2 күн бұрын
My personal go-to is to store dates as UTC timestamps in the database, and parse the UTC timestamp on the client side (sometimes directly, or with Date.UTC). Oh, and to never manipulate timezones (or worse, offsets)
@CodingWithTaaxo
@CodingWithTaaxo 2 күн бұрын
Hey Aaron, If you're still putting together that course, I'd be down if you could throw in a section on cron jobs. I'm learning Postgres, and your teaching style is the bomb. Can't wait to grab your course!
@aarondfrancis
@aarondfrancis 2 күн бұрын
Oh nice, added to my list!
@dalcod
@dalcod 2 күн бұрын
That is a good suggestion.
@nolocobralink
@nolocobralink 20 сағат бұрын
is there a way to show the offset on the final date without having to change the time zone on the session? for example, I'm in the America/Santiago timezone (currently on daylight saving time), and a former colleague made a small application using Postgres as the db and set UTC as the overall time zone (not just in the db), if I use the REST API of the app to check the records, all the dates will be on UTC with the offset "+00", if I ever added a query parameter that allowed me to show all the dates on a specific time zone (in this case America/Santiago), how can I implement that without changing the time zone on the session and still get the offset? ("-04" or "-03" depending on daylight saving)
@HashimWarren
@HashimWarren Күн бұрын
Is the course project based? Looking forward to it
@codedusting
@codedusting 2 күн бұрын
Timezones of all things should have been a physics problem, not politics. How did that even happen?
@aarondfrancis
@aarondfrancis 2 күн бұрын
Geeze, I dunno. It sucks though
@codedusting
@codedusting 2 күн бұрын
@@aarondfrancis yes. I had to make a real estate auction site for Dubai UAE but international buyers. It was quite hell back in 2020.
@melvillespence6768
@melvillespence6768 Күн бұрын
Where do you set the origin? Greenwich was chosen in 1884 at the Meridian Conference, when the UK was the preeminent power. GMT was adopted within the UK in 1847 because of the railways. BST came in WW1 to make best use of the working day, in WW2 we had double summer time for the same reason. In an ideal world we would use 15 degrees of longitude = 1 hour, but 🤣
@gilesbbb
@gilesbbb Күн бұрын
This is set up for covering special relativity in the next video, yes?
@jricardoprog
@jricardoprog Күн бұрын
Comparing timestamp is also annoying in pg, I need to remove 1ms to find the same record
@djasnive
@djasnive 2 күн бұрын
Since when did you use Postgres
@aarondfrancis
@aarondfrancis 2 күн бұрын
I'm a free agent now!
@FrankGehann
@FrankGehann 2 күн бұрын
This was a really great sum up. Thank you very much!
@sahaj.r
@sahaj.r 2 күн бұрын
Time stone 😄
@dalcod
@dalcod 2 күн бұрын
October 15 is too far for me lol.
@quintenkamphuis
@quintenkamphuis 2 күн бұрын
8:30 base because Docker haha
@aarondfrancis
@aarondfrancis 2 күн бұрын
haha I dont know what I was thinking
@jrdnrc
@jrdnrc 2 күн бұрын
thanks i hate timezones
@dnukeranged
@dnukeranged 2 күн бұрын
full course hype
@aarondfrancis
@aarondfrancis 2 күн бұрын
😮‍💨 it's coming so soon! I gotta hurry!
@coffeeowl86
@coffeeowl86 2 күн бұрын
Amazing content as always! I'm glad you're also covering Postgres. Best wishes 🤗 Update: I joined the wait list for the course :D
@estebanmurcia8451
@estebanmurcia8451 2 күн бұрын
6:42 guilty as charged
@aarondfrancis
@aarondfrancis 2 күн бұрын
gottem
@luca4479
@luca4479 2 күн бұрын
What kind of camera do you use to film your videos? Your camera quality is on par with MKBHD and LTT, I’m in awe!
@aarondfrancis
@aarondfrancis Күн бұрын
Canon R6!
@kirayamato6128
@kirayamato6128 2 күн бұрын
Aaron ❤️🧡💛💚🩵💙💜🤎🖤🩶🤍🩷
My browser got hacked and it cost me $2,000
21:40
Theo - t3․gg
Рет қаралды 80 М.
Introduction of SQL Server | SQL Server Tutorial
25:46
Naresh i Technologies
Рет қаралды 866 М.
Man Mocks Wife's Exercise Routine, Faces Embarrassment at Work #shorts
00:32
Fabiosa Best Lifehacks
Рет қаралды 6 МЛН
Стойкость Фёдора поразила всех!
00:58
МИНУС БАЛЛ
Рет қаралды 3,6 МЛН
The day of the sea 😂 #shorts by Leisi Crazy
00:22
Leisi Crazy
Рет қаралды 2,1 МЛН
DHH discusses SQLite (and Stoicism)
54:00
Aaron Francis
Рет қаралды 76 М.
Migrating from Postgres to SQLite with Kent C. Dodds
57:02
Aaron Francis
Рет қаралды 11 М.
Why I don't change SSH from port 22
13:31
Dreams of Code
Рет қаралды 16 М.
How to make a thousand plots look good
20:22
R for the Rest of Us
Рет қаралды 525
Postgres just got even faster
26:42
Hussein Nasser
Рет қаралды 30 М.
A math GENIUS taught me how to LEARN ANYTHING in 3 months (it's easy)
8:52
Python Programmer
Рет қаралды 180 М.
The Cloudflare Stack
13:26
Cloudflare Developers
Рет қаралды 9 М.
Web Dev The Right Way
12:35
Awesome
Рет қаралды 32 М.
40 Years Of Software Engineering Experience In 19 Minutes
19:10
Continuous Delivery
Рет қаралды 81 М.
Man Mocks Wife's Exercise Routine, Faces Embarrassment at Work #shorts
00:32
Fabiosa Best Lifehacks
Рет қаралды 6 МЛН