empire-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "mailinglist@j-b-s.de" <mailingl...@j-b-s.de>
Subject Re: Drop tables
Date Wed, 08 Aug 2012 14:57:14 GMT
HI Eike!

I buy this! I started with this sample and in the meantime figured out we can use "DROP SCHEMA
PUBLIC CASCADE" in the driver in case it is HSQL and dropping a database is needed.

A fix will be nice. But I can also try to write my own driver factory class...

Sent from my iPhone

On 08.08.2012, at 15:42, Eike Kettner <news@eknet.org> wrote:

> Hi,
> 
> I think that's a bug in the EmpireDriverFactory class. This class is
> part of the sample project and was created as an example on how it could
> work with spring. Well..., do you actually mean this class from the
> example-spring project?
> 
> If so, I would recommend to not depend on this jar file but rather
> create a new DriverFactory (without that bug :)) class in your project.
> But, of course, the EmpireDriverFactory class in the samples should be
> fixed. I can do that the next days.
> 
> best regards
> Eike
> 
> On [Wed, 08.08.2012 14:51], mailinglist@j-b-s.de wrote:
>> Hi Francis!
>> 
>> I digged a bit deeper: the schema name is avail as param in the EmpireDriverFactory,
but not used at all in case of HSQL (see :65 in the factory). This at least explains the IllegalArgumentEx.
Any ideas?
>> 
>> Jens
>> 
>> Sent from my iPhone
>> 
>> On 07.08.2012, at 11:44, Francis De Brabandere <francisdb@gmail.com> wrote:
>> 
>>> Hi Jens,
>>> 
>>> In DBDatabaseDriverHSqlTest this code is in use:
>>> 
>>>       script = new DBSQLScript();
>>>       db.getDriver().getDDLScript(DBCmdType.DROP, db.EMPLOYEE, script);
>>>       db.getDriver().getDDLScript(DBCmdType.DROP, db.DEPARTMENT, script);
>>>       script.run(db.getDriver(), conn, true);
>>> 
>>> As far as I know this is working correctly, would you mind providing
>>> us with some stacktrace or test to reproduce your issue? What sources
>>> are you talking about?
>>> 
>>> Cheers,
>>> Francis
>>> 
>>> On 6 August 2012 15:15, mailinglist@j-b-s.de <mailinglist@j-b-s.de> wrote:
>>>> Hi All!
>>>> 
>>>> I am working with empire 2.3.0 + spring and got everything working incl
>>>> transactions. For testing purposes I want to drop my database (hsql in
>>>> memory) between test runs. The "database" getCreateDDLScript method creates
>>>> all tables and I am looking for a DropDDLScript method but can't figure it
>>>> out. The method exists on the driver (OracleDDLGenerator for example) and
I
>>>> can call it like:
>>>> db.getDriver().getDDLScript(DBCmdType.DROP,..) but this fails with an
>>>> exception "Invalid Argument null for parameter name". From the sources a
>>>> schema name is missing so I am a little confused..,
>>>> 
>>>> Can you point me to the right direction?
>>>> Thx in advance
>>>> 
>>>> Jens
>> 
> 
> -- 
> email: eike@eknet.org   https://eknet.org  pgp: 481161A0

Mime
View raw message