It will depend on the database you're using! As you can see below, there can be quite some variations in syntax between Vertica, SQL Server, MySQL, PostgreSQL So, what's common in all these examples? In all cases, you will need: a function that gets the current date a function that extracts the year from … Continue reading How can I get the end date of a quarter with SQL?
Good question! As you'll see below, there are some different syntax options within the different database environments current_timestamp, though, will rarely disappoint Happy SQL-ing!
Hit a couple of error messages when trying to convert a string to a date? And that's totally not surprising! As you'll see below the text-to-date conversion functions within the different database environments seldom have identical syntax Why would you want to convert a string to a date? Well, it could be pretty useful if … Continue reading How do I convert string to a date with SQL?