Skip to content

Tag Archives: PostgreSQL-Date-function

In PostgreSQL the age() function is used to calculate ages. Syntax: age(timestamp, timestamp); Let’s analyze the above syntax: The age() function accepts two TIMESTAMP values… Read More
In PostgreSQL, the DATE_PART() function is used to query for subfields from a date or time value.  Syntax: DATE_PART(field, source) In the above syntax the… Read More
The PostgreSQL CURRENT_DATE function returns the current date. Syntax: CURRENT_DATE Return value: The CURRENT_DATE function returns a DATE value that represents the current date. Example… Read More
The PostgreSQL EXTRACT() function is used to query for field associated with date and time such as a year, month, and day from a date/time… Read More
In PostgreSQL, DATE_TRUNC Function is used to truncate a timestamp type or interval type with specific and high level of precision. Syntax: date_trunc('datepart', field) The… Read More
The PostgreSQL CURRENT_TIMESTAMP() function returns the current date and time with time zone. It is important to note that the time and time zone returned… Read More
The PostgreSQL CURRENT_TIME function returns the current time and the currentthe time zone. Syntax: CURRENT_TIME(precision) Let’s analyze the above syntax: The precision argument is used to… Read More

Start Your Coding Journey Now!