Yes, Job is correct: support for subquery is in-progress, but not yet implemented. In the meantime, you'll need to run this as two separate queries:
select max(time) from session;
select * from session where time = the_max;

Performance-wise, there will not be much difference for this query.

Thanks,
James


On Mon, Jun 2, 2014 at 9:30 PM, Job Thomas <jobt@suntecgroup.com> wrote:
Hi ,

The subquery feature is not supported in Phoenix.

Thanks & Regards
Job M Thomas


________________________________

From: Pham Phuong Tu [mailto:tuphamphuong@gmail.com]
Sent: Tue 6/3/2014 9:27 AM
To: user@phoenix.incubator.apache.org
Subject: How to use subquery with Phoenix


Hi guys,

I have a question is how to use this kind of query with Phoenix?


" select * from session where time = (select max(time) from session); "


Thanks a lot.