Re: maxvalue in select statement not allowed

Tobias Downer <[email protected]>
Newsgroups gmane.comp.db.mckoi
Message-ID <[email protected]>
You can use the query;

  select max("parameter_id") as "maxvalue" from "APP"."parameter"

and it will work as expected.  'maxvalue' is a reserved token as defined 
by the Mckoi SQL grammar.  It is a good idea to quote all identifiers.

Toby.

John Zoetebier wrote:
> Select statement is:
> select max("parameter_id") as maxvalue from "APP"."parameter"
> 
> McKoi does not allow "maxvalue" in statement.
> Following statement is ok:
> select max("parameter_id") as _maxvalue from "APP"."parameter"
> 
> The documentation says:
> =>
> 7. CREATE SEQUENCE syntax
> 
> CREATE SEQUENCE name
>   [ INCREMENT increment_value ]
>   [ MINVALUE minimum_value ]
>   [ MAXVALUE maximum_value ]
>   [ START start_value ]
>   [ CACHE cache_value ]
>   [ CYCLE ]
> 
> Creates a new sequence generator that can be used to generate an iterative 
> sequence of values. Sequence generators have a number of uses including the 
> creation of primary keys for a table. The INCREMENT, MINVALUE, MAXVALUE, 
> START, and CACHE values are all optional.
> =>
> 
> Does this mean that maxvalue is a reserved word ?
> 



---------------------------------------------------------------
Mckoi SQL Database mailing list  http://www.mckoi.com/database/
To unsubscribe, send a message to [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.