On which version of Cassandra are you? I can't reproduce the
NullPointerException on Cassandra 1.2.3.

That being said, that query is not valid, so you will get an error message.
There is 2 reasons why it's not valid:
  1) in token(deep), deep is not a valid term. So you should have something
like: token('deep').
  2) the name column is not the partition key so the token method cannot be
applied to it.

A valid query with that schema would be for instance:
  select * from "CQLUSER" where token(id) > token(4)
though I don't know if that help in any way for what you aimed to do.

--
Sylvain


On Wed, Apr 10, 2013 at 9:42 AM, Kuldeep Mishra <kuld.cs.mis...@gmail.com>wrote:

> Hi ,
>      TABLE -
> CREATE TABLE "CQLUSER" (
>   id int PRIMARY KEY,
>   age int,
>   name text
> )
>     Query -
>       select * from "CQLUSER" where token(name) > token(deep);
>
>     ERROR -
> Bad Request: Failed parsing statement: [select * from "CQLUSER" where
> token(name) > token(deep);] reason: NullPointerException null
> text could not be lexed at line 1, char 15
>
> --
> Thanks and Regards
> Kuldeep Kumar Mishra
> +919540965199
>

Reply via email to