[ 
https://issues.apache.org/jira/browse/IGNITE-20225?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan Gagarkin updated IGNITE-20225:
-----------------------------------
    Description: 
According to the Spark documentation, the function 
[weekofyear|https://spark.apache.org/docs/latest/api/sql/#weekofyear] should 
return a number based on ISO rules:
{quote}A week is considered to start on a Monday and week 1 is the first week 
with >3 days.
{quote}
The current implementation of the spark-extension uses 
[WEEK|http://www.h2database.com/html/functions.html#week[],] when translate 
Spqrk SQL to H2 SQL which returns the week-based year (locale-specific) from a 
date/time value.

The extensions should use 
[ISO_WEEK|http://www.h2database.com/html/functions.html#iso_week]

  was:
According to the Spark documentation, the function 
[weekofyear|https://spark.apache.org/docs/latest/api/sql/#weekofyear] should 
return a number based on ISO rules:
{quote}A week is considered to start on a Monday and week 1 is the first week 
with >3 days.
{quote}
The current implementation of the spark-extension uses 
[WEEK|http://www.h2database.com/html/functions.html#week[],], which returns the 
week-based year (locale-specific) from a date/time value.

The extensions should use 
[ISO_WEEK|http://www.h2database.com/html/functions.html#iso_week]


> ignite-spark-ext: 'select weekofyear' returns incorrect week number based on 
> local rules
> ----------------------------------------------------------------------------------------
>
>                 Key: IGNITE-20225
>                 URL: https://issues.apache.org/jira/browse/IGNITE-20225
>             Project: Ignite
>          Issue Type: Bug
>          Components: spark
>            Reporter: Ivan Gagarkin
>            Priority: Major
>
> According to the Spark documentation, the function 
> [weekofyear|https://spark.apache.org/docs/latest/api/sql/#weekofyear] should 
> return a number based on ISO rules:
> {quote}A week is considered to start on a Monday and week 1 is the first week 
> with >3 days.
> {quote}
> The current implementation of the spark-extension uses 
> [WEEK|http://www.h2database.com/html/functions.html#week[],] when translate 
> Spqrk SQL to H2 SQL which returns the week-based year (locale-specific) from 
> a date/time value.
> The extensions should use 
> [ISO_WEEK|http://www.h2database.com/html/functions.html#iso_week]



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to