Open qoega opened 1 year ago
Hi, I am new to open source contribution and it could be a good first issue for me, can you please assign it to me ?
Regards, Utkarsh
Hi @qoega Can I work on this issue??
Hi @qoega Can I work on this issue??
Sure !
Hi @qoega can you mention the file in which the error is?
This error is just an error when I run this query from client.
@qoega I'm sorry, I meant to ask in which file do I need to add the year() function.
@ishaan9006 Please check src/Functions/toYear.cpp
andsrc/Functions/FunctionDateOrDateTimeToSomething.h
is it still open?
is it still open?
It's still open.
Hey @ucasfl I'm working on it..I will raise pr asap.
is it still open?
It's still open.
Hey @ucasfl I'm working on it..I will raise pr asap.
is it still open?
It's still open.
@PrathyushaModala OK.
@ucasfl Hi, Maybe we should write a new function like thisYear(). It seems that toYear(which alias is year), toDayOfYear() belong to the same kind of function whichboth take arguments,but thisYear(), today(), now() belong to a different kind of function, neither of which takes arguments.
@ucasfl Hi, Maybe we should write a new function like thisYear(). It seems that toYear(which alias is year), toDayOfYear() belong to the same kind of function whichboth take arguments,but thisYear(), today(), now() belong to a different kind of function, neither of which takes arguments.
@2063436123 I don't agree, functions in ClickHouse can be variadic, which means it can take different number of arguments, so this feature can be implemented inside toYear
function, instead create a new function.
@ucasfl thanks, Could I work on this issue? I will realize year()
function.
@ucasfl thanks, Could I work on this issue? I will realize
year()
function.
Sure!
@ucasfl #48321 Here is my pr, please check it.
Hi, I am new to open source, could you please assign This task to me, if it is still open?
Use case
Similar logic as in now() and today() it returns current year.
Describe the solution you'd like
year() = year(now()) = year(today())
Currently year() fails:
Code: 42. DB::Exception: Number of arguments for function toYear doesn't match: passed 0, should be 1 or 2: While processing toYear(). (NUMBER_OF_ARGUMENTS_DOESNT_MATCH) (version 22.13.1.294 (official build))