# 22. Virtuoso Functions Guide - quarter

Chapter Contents | Prev | Next
Keyword Search:
www.openlinksw.com
docs.openlinksw.com
Book Home
Contents
Preface
Virtuoso Functions Guide
Administration
Aggregate Functions
Array Manipulation
BPEL APIs
Backup
Compression
Cursor
Date & Time Manipulation
Debug
Dictionary Manipulation
Encoding & Decoding
File Manipulation
Free Text
Hashing / Cryptographic
LDAP
Locale
Mail
Miscellaneous
Number
Remote SQL Data Source
Replication
SOAP
SQL
String
Transaction
Type Mapping
UDDI
User Defined Types & The CLR
Virtuoso Java PL API
Virtuoso Server Extension Interface (VSEI)
Web Server & Internet
XML
XPATH & XQUERY
Functions Index

## quarter

get number of quarter of year from a datetime
quarter (in dt datetime);
Description

quarter takes a datetime and returns an integer containing a number representing the quarter of year of the datetime.

Parameters
dt – A datetime.
Return Values

An INTEGER containing number of the quarter of year.

Examples
Simple example

Get current quarter of year.

    SQL> select quarter (now ());
    callret
    INTEGER
    _______________________________________________________________________________

    4

See Also

dayname, monthname, dayofmonth, dayofweek, dayofyear, week, month, year, hour, minute, second, timezone