phoenix-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "rajeshbabu@apache.org" <chrajeshbab...@gmail.com>
Subject Re: Problem using more than one user defined functions in a query
Date Thu, 20 Aug 2015 17:04:19 GMT
Hi Anchal,Rajmund

Sorry for late reply.

I have found the root cause for the issue and uploaded the patch at
PHOENIX-2151.
I have verified it's working fine. You can also try and check things are
fine or not.

Thanks Anchal for following up.

Thanks,
Rajeshbabu.

On Wed, Aug 19, 2015 at 10:32 PM, Anchal Agrawal <anchal@yahoo-inc.com>
wrote:

> Hi Rajmund,
>
> This is being tracked at the JIRA ticket -
> https://issues.apache.org/jira/browse/PHOENIX-2151. I'm also facing the
> same issue. Please add your comments/test cases to the ticket as necessary.
> Rajeshbabu could not reproduce the error, so I have sent him an email with
> my UDFs and he is investigating.
>
> Thank you,
> Anchal
>
>
>
> On Wednesday, August 19, 2015 12:13 AM, Bocsi Rajmund <rbocsi@aitia.ai>
> wrote:
>
>
> Hi,
>
> I'm using phoenix-4.4.0-HBase-1.0 with hbase-1.0.1.1 and I experienced a
> strange problem. I created a view from the existing hbase table as it is
> suggested in the FAQ. In my database the row id (PK) contains the client
> id and the timestamp of the record among other pieces of informations.
> I created two user defined functions (as described here:
> https://phoenix.apache.org/udf.html): one that returns the client id and
> an other one that returns the timestamp. They work as expected:
>
>   select mysense_clientid(PK) from "baseapp:mysense-data" LIMIT 2;
>
> +------------------------------------------+
> |          MYSENSE_CLIENTID(PK)          |
> +------------------------------------------+
> | 0488fb527a654c4f85a9c43a082b3320        |
> | 0488fb527a654c4f85a9c43a082b3320        |
> +------------------------------------------+
>
> select mysense_timestamp(PK) from "baseapp:mysense-data" LIMIT 2;
>
> +-------------------------+
> |  MYSENSE_TIMESTAMP(PK)  |
> +-------------------------+
> | 2015-08-05 15:03:20.816 |
> | 2015-08-05 15:03:20.576 |
> +-------------------------+
>
> However when I try to use both functions in one query, the result is wrong:
>
> select mysense_clientid(PK), mysense_timestamp(PK) from
> "baseapp:mysense-data" LIMIT 2;
>
>
> +------------------------------------------+------------------------------------------+
> |          MYSENSE_CLIENTID(PK)          |
> MYSENSE_CLIENTID(PK)          |
>
> +------------------------------------------+------------------------------------------+
> | 0488fb527a654c4f85a9c43a082b3320        |
> 0488fb527a654c4f85a9c43a082b3320        |
> | 0488fb527a654c4f85a9c43a082b3320        |
> 0488fb527a654c4f85a9c43a082b3320        |
>
> +------------------------------------------+------------------------------------------+
>
> It seems the phoenix uses only the first one both times. I did not
> experience this kind of behaviour when I used the built-in functions.
>
> Is this a bug in the phoenix, or am I doing something wrong?
>
> Regards,
> Rajmund Bocsi
>
>
>

Mime
View raw message