Hello Andy

1. "Is there a list somewhere of reserved keywords that I can access so
that I
prohibit a user entering such a column name?" ->
http://www.datastax.com/documentation/cql/3.0/cql/cql_reference/keywords_r.html

2. you may propose a pull request ?




On Tue, Mar 4, 2014 at 10:52 AM, Andy <li...@persistability.plus.com> wrote:

> Hi,
>
> while adding support for Cassandra into DataNucleus I came across the
> following
> CREATE TABLE schema1.mapfkvalueitem (desc varchar,key varchar,name
> varchar,mapfkvalueitem_id bigint, PRIMARY KEY (mapfkvalueitem_id));
>
> which fails with the delightfully informative message
> Bad Request: line 1:37 no viable alternative at input 'desc'
>
>
> Simple trial and error leads me to the conclusion that this is due to
> "desc"
> being a reserved keyword that cannot be used for column identifiers.
>
> 1. Is there a list somewhere of reserved keywords that I can access so
> that I
> prohibit a user entering such a column name? a method on the DataStax Java
> driver would be great, but otherwise a web page somewhere would do.
>
> 2. Wouldn't it be better to have that error message updated to be a bit
> more
> descriptive such as "'desc' is a reserved keyword, so cannot be used as a
> table/column identifier" or even just "'desc' is a reserved keyword" ?
>
>
> TIA
> --
> Andy
>

Reply via email to