OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

office message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: [OASIS Issue Tracker] Updated: (OFFICE-2913) 6.10.14 NETWORKDAYSand 6.10.22 WORKDAY inconsistency



     [ http://tools.oasis-open.org/issues/browse/OFFICE-2913?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andreas Guelzow  updated OFFICE-2913:
-------------------------------------

    Resolution: 
Rewrite:

6.10.14 NETWORKDAYS
Summary: Returns the whole number of work days between two dates.
Syntax: NETWORKDAYS( DateParam Date1 ; DateParam Date2 [ ; [ DateSequence Holidays ] [ ; NumberSequence Workdays ] ] )
Returns: Number
Constraints: None
Semantics: Returns the whole number of days between two dates, ignoring weekends.
Work days are defined as non-weekend, non-holiday days. By default, weekends are Saturdays
and Sundays and there are no holidays.
The optional 3rd parameter Holidays can be used to specify a list of dates to be treated as
holidays. Note that this parameter can be omitted as an empty parameter (two consecutive ;;
semicolons) to be able to pass the set of Workdays without Holidays.
The optional 4th parameter Workdays can be used to specify a different definition for the standard
work week by passing in a list of numbers which define which days of the week are
workdays (indicated by 0) or not (indicated by non-zero) in order Sunday, Monday,...,Saturday. 
So, the default definition of the work week excludes Saturday and Sunday and is:
{1;0;0;0;0;0;1}. To define the work week as excluding Friday and Saturday, the third parameter
would be: {0;0;0;0;0;1;1}.

6.10.22 WORKDAY
Summary: Returns the date serial number which is a specified number of work days before or after an
input date.
Syntax: WORKDAY( DateParam Date ; Number Offset [ ; [ DateSequence Holidays ] [ ; NumberSequence Workdays ] ] )
Returns: DateTime
Constraints: None
Semantics: Returns the date serial number for the day that is offset from the input Date parameter
by the number of work days specified in the Offset parameter. If Offset is negative, the offset will
return a date prior to Date. If Offset is positive, a date later Date is returned. If Offset is zero, then
Date is returned.
Work days are defined as non-weekend, non-holiday days. By default, weekends are Saturdays
and Sundays and there are no holidays.
The optional 3rd parameter Holidays can be used to specify a list of dates to be treated as holidays.
Note that this parameter can be omitted as an empty parameter (two consecutive ;; semicolons) to
be able to pass the set of Workdays without Holidays.
The optional 4th parameter Workdays can be used to specify a different definition for the standard
work week by passing in a list of numbers which define which days of the week are workdays (indicated by 0) 
or not (indicated by non-zero) in order Sunday, Monday,...,Saturday.
If all seven numbers in Workdays are non-zero and Offset is also non-zero, WORKDAY returns an error.
Note: The default definition of the work week that excludes Saturday and Sunday and is:
{1;0;0;0;0;0;1}. To define the work week as excluding Friday and Saturday, the third parameter
would be: {0;0;0;0;0;1;1}.



I think it is uncontroversial to have "If all seven numbers in Workdays are non-zero and Offset is also non-zero, WORKDAY returns an error."

> 6.10.14 NETWORKDAYS and 6.10.22 WORKDAY inconsistency
> -----------------------------------------------------
>
>                 Key: OFFICE-2913
>                 URL: http://tools.oasis-open.org/issues/browse/OFFICE-2913
>             Project: OASIS Open Document Format for Office Applications (OpenDocument) TC
>          Issue Type: Bug
>          Components: OpenFormula
>    Affects Versions: ODF 1.2 CD 05
>            Reporter: Andreas Guelzow 
>            Assignee: Robert Weir 
>             Fix For: ODF 1.2 CD 06
>
>
> In 6.10.14 NETWORKDAYS and 6.10.22 WORKDAY the last argument is specified as  [ ;LogicalSequence workdays ] .
> In 6.10.14 it states that {1;0;0;0;0;0;1} is the default and an explanatory example gives {0;0;0;0;0;1;1}. The same is stated in 6.10.22 in a Note.
> {1;0;0;0;0;0;1} and  {0;0;0;0;0;1;1} are not LogicalSequences. We should give Logical sequences here, ie. {TRUE();FALSE();FALSE();FALSE();FALSE();FALSE();TRUE()} and {FALSE();FALSE();FALSE();FALSE();FALSE();TRUE();TRUE()}.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://tools.oasis-open.org/issues/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]