On Thu, Aug 11, 2016 at 9:00 AM, ankit beohar <ankitbeoha...@gmail.com> wrote:
> I want to implement If null in apache phoenix like mysql. > > select ifnull(rowkey,myvalue),ifnull(col1,mycolvalue) from table where > rowkey='abc'; > > I tried below query but did not work:- > > select case when APP_KEY is null then 'nullvalue' else APP_KEY end from > "CheckDump"; > The standard SQL function for this is coalesce(col, 'nullvalue'). https://phoenix.apache.org/language/functions.html#coalesce Lukas