简体   繁体   中英

Reserved SQL keyword 'User' is not permitted as simple type name

When I gave the roo command

entity --class  ~.domain.User

in the roo shell, I got

Reserved SQL keyword 'User' is not permitted as simple type name

What I want to know is that, is there a way to gave alias name to the entity ? Because I do have a couple of entities which name are not permitted as above. Or is there a way to overcome this kind of problem ?

Any help will be greatly appreciated. Thank you very much.

You could try to add the --permitReservedWords option to the entity command.

https://jira.springsource.org/browse/ROO-1502

If you want to change the entity name, but keep the table name:

entity --class ~.domain.FooUser --table user

I would think there is a way to quote all sql identifiers, but I don't know that much about Roo.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM