empire-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rainer Döbele <doeb...@esteam.de>
Subject re: view generation support in codegen
Date Thu, 07 Jan 2010 17:08:10 GMT
Hi Benni,

great to hear from you.

I don't think it is necessary to retrieve the command for a view.
Implementing the createCommand on a view class in only necessary for creating a database.
And we want to go the other way.

Besides the createCommand requires a DBCommand object and hence you would need a SQL parser
that turns a SQL statement into a command object. While this would be possible for simple
statements, making it work for all kind of statements could be a too hard nut to crack.


Benjamin Venditti wrote:
> re: view generation support in codegen
> Hi there,
> i am glad to announce that I've become a committer to empire-db and i'm
> looking forward to work with the empire-db team.
> With this announcement i also submitted my first commit in svn. Here is
> a overview of my changes:
> - new feature: it is now possible to generate views, however they are
> not fully functional as the function "createCommand" is not implemented
> - bugfix: column names with whitespaces caused the generator to create
> uncompilable classes (status: fixed)
> - added mysql dependency in pom.xml
> - added new configuration options in config.xml
>    "viewClassSuffix", "tablePackageName", "recordPackageName",
> "viewPackageName"
> I tested my changes with MySQL and its sample database "sakila"
> (http://dev.mysql.com/doc/sakila/en/sakila.html).
> Does anyone know if there is a way to retrieve the SQL commands for the
> views of a database that it holds?
> Best regards,
>      Benjamin

View raw message