You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-user@db.apache.org by Oleg Lebedev <ol...@waterford.org> on 2004/03/04 23:01:43 UTC

column name is a reserved keyword

Hi, 
 
I am changing an existing application to use OJB.
The problem that I ran into is that some of the column names are
reserved keywords, e.g. 'print'. I need to configure OJB to put all
column names in brackets, e.g. [print], when retrieving values from the
database. Otherwise, SQL Server throws a "Reserved keyword" exception.
 
How do I do this?
 
Thanks.
 
Oleg 
  
************************************* 
This e-mail may contain privileged or confidential material intended for the named recipient only. 
If you are not the named recipient, delete this message and all attachments. 
Unauthorized reviewing, copying, printing, disclosing, or otherwise using information in this e-mail is prohibited. 
We reserve the right to monitor e-mail sent through our network.  
************************************* 

Re: column name is a reserved keyword

Posted by Jakob Braeuchi <jb...@gmx.ch>.
hi oleg,

have you tried to change column names in repository.xml ?
ojb would the use :

select A0.[name], A0.firstName from person A0

jakob

Oleg Lebedev wrote:

> Hi, 
>  
> I am changing an existing application to use OJB.
> The problem that I ran into is that some of the column names are
> reserved keywords, e.g. 'print'. I need to configure OJB to put all
> column names in brackets, e.g. [print], when retrieving values from the
> database. Otherwise, SQL Server throws a "Reserved keyword" exception.
>  
> How do I do this?
>  
> Thanks.
>  
> Oleg 
>   
> ************************************* 
> This e-mail may contain privileged or confidential material intended for the named recipient only. 
> If you are not the named recipient, delete this message and all attachments. 
> Unauthorized reviewing, copying, printing, disclosing, or otherwise using information in this e-mail is prohibited. 
> We reserve the right to monitor e-mail sent through our network.  
> ************************************* 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org