Difference between revisions of "Manuals/calci/WEEKDAY"
Jump to navigation
Jump to search
(Created page with "<div id="16SpaceContent" align="left"><div class="ZEditBox" align="justify"> Syntax </div></div> ---- <div id="2SpaceContent" align="left"><div class="ZEditBox" align=...") |
|||
Line 1: | Line 1: | ||
− | + | =WEEKDAY(SN, Type)= | |
− | + | where, | |
+ | *<math>SN</math> represents a date for which day has to be displayed, | ||
+ | *<math>Type</math> represents the type of return value. | ||
− | + | WEEKDAY() displays the day of the week corresponding to a date. | |
− | |||
− | |||
− | + | == Description == | |
− | + | WEEKDAY(SN, Type) | |
− | |||
− | |||
− | |||
− | |||
− | < | + | *<math>SN</math> is a date value to be entered either in 'date format' or 'dates returned using formulas'. |
+ | *If <math>SN</math> values are invalid, Calci displays #N/A error message. | ||
+ | *<math>Type</math> is the type of return value. It can be from the following - | ||
− | + | {| class="wikitable" | |
− | + | |- | |
− | + | ! Type !! Description | |
− | + | |- | |
− | + | | 0 or 1 or omitted || Number from 1(Sunday) to 7(Saturday) | |
− | + | |- | |
− | + | | 2 || Number from 1(Monday) to 7(Sunday) | |
− | + | |- | |
− | + | | 3 || Number from 0(Monday) to 6(Sunday) | |
− | + | |} | |
− | |||
− | < | + | *If <math>Type</math> values are invalid, Calci displays #N/A error message. |
− | + | == Examples == | |
− | + | Consider the following example that explains the use of WEEKDAY function: | |
− | < | + | <div id="2SpaceContent" class="zcontent" align="left"> |
− | + | {| id="TABLE3" class="SpreadSheet blue" | |
− | |||
− | |||
− | |||
− | {| id=" | ||
|- class="even" | |- class="even" | ||
+ | | class=" " | 10/8/2014 | ||
+ | | class=" " | | ||
| class=" " | | | class=" " | | ||
− | + | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
|- class="odd" | |- class="odd" | ||
− | | class=" | + | | class="sshl_f" | |
− | + | | class=" " | | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | | class=" " | | ||
| class=" " | | | class=" " | | ||
|} | |} | ||
− | + | =WEEKDAY(A1): Calculates the day of the week from date mentioned in A1. Displays '''4''' (i.e. Wednesday) as a result. | |
− | + | =WEEKDAY(A1,2): Calculates the day of the week from date mentioned in A1 and return type '2'. Displays '''3''' (i.e. Wednesday) as a result. | |
− | + | =WEEKDAY(DATE(2013,10,28),3) : Calculates the day of the week from date mentioned and return type '3'. Displays '''0''' (i.e. Monday) as a result. | |
+ | |||
+ | == See Also == | ||
+ | |||
+ | *[[Manuals/calci/NETWORKDAYS | NETWORKDAYS]] | ||
+ | *[[Manuals/calci/WORKDAY | WORKDAY]] | ||
− | + | == References == | |
− | + | *[http://en.wikipedia.org/wiki/Date_format_by_country Date Formats] | |
− | + | *[http://en.wikipedia.org/wiki/Calendar_date Date] |
Revision as of 14:43, 5 February 2014
WEEKDAY(SN, Type)
where,
- represents a date for which day has to be displayed,
- represents the type of return value.
WEEKDAY() displays the day of the week corresponding to a date.
Description
WEEKDAY(SN, Type)
- is a date value to be entered either in 'date format' or 'dates returned using formulas'.
- If values are invalid, Calci displays #N/A error message.
- is the type of return value. It can be from the following -
Type | Description |
---|---|
0 or 1 or omitted | Number from 1(Sunday) to 7(Saturday) |
2 | Number from 1(Monday) to 7(Sunday) |
3 | Number from 0(Monday) to 6(Sunday) |
- If values are invalid, Calci displays #N/A error message.
Examples
Consider the following example that explains the use of WEEKDAY function:
10/8/2014 | ||
=WEEKDAY(A1): Calculates the day of the week from date mentioned in A1. Displays 4 (i.e. Wednesday) as a result. =WEEKDAY(A1,2): Calculates the day of the week from date mentioned in A1 and return type '2'. Displays 3 (i.e. Wednesday) as a result. =WEEKDAY(DATE(2013,10,28),3) : Calculates the day of the week from date mentioned and return type '3'. Displays 0 (i.e. Monday) as a result.