You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user-java@ibatis.apache.org by Stefano Emilio Campanini <st...@gmail.com> on 2009/09/18 18:13:05 UTC
Postgresql java.lang.NullPointerException migrate status
Hi,
I'have started using the new migrations today on a starting project.
(migrations verison is 3.0 Beta 3 )
We are using Postgresql 8.3.7 and at the beginning (creating the first
table ) we meet a problem, after the launch of the first "migrate up".
In fact using migrate status we have ...the follow error:
batis-migration$ ./migrate status
ID Applied At Description
================================================================================
Exception in thread "main" java.lang.NullPointerException
at java.math.BigDecimal.<init>(BigDecimal.java:724)
at org.apache.ibatis.migration.commands.BaseCommand.getChangelog(BaseCommand.java:64)
at org.apache.ibatis.migration.commands.StatusCommand.execute(StatusCommand.java:20)
at org.apache.ibatis.migration.CommandLine.runCommand(CommandLine.java:77)
at org.apache.ibatis.migration.CommandLine.execute(CommandLine.java:56)
at org.apache.ibatis.migration.Migrator.main(Migrator.java:6)
The follow is the unique script we have in our scripts dir, executed
by the migrate up.
--// Create Cliente Table
-- Migration SQL that makes the change goes here.
CREATE TABLE cliente
(
id serial PRIMARY KEY,
codice varchar(50) UNIQUE NOT NULL,
rag_sociale varchar(50),
service_manager varchar(100),
email varchar(50),
certificato_pgp text
);
ALTER TABLE cliente OWNER TO gsd;
--//@UNDO
-- SQL to undo the change goes here.
DROP TABLE cliente;
Any ideas ?
Thank you in advance
Stefano
--
Tinvention - Ingegneria Informatica -
http://tinvention.net/
ing. Stefano E. Campanini
---------------------------------------------------------------------
To unsubscribe, e-mail: user-java-unsubscribe@ibatis.apache.org
For additional commands, e-mail: user-java-help@ibatis.apache.org
Re: Postgresql java.lang.NullPointerException migrate status
Posted by Clinton Begin <cl...@gmail.com>.
Awesome! Patches really are helpful.
You can attach the modified file(s) to the Jira ticket. Don't worry about
including everything, just the modified files and the unit test if you have
one.
cheers,
Clinton
On Mon, Sep 21, 2009 at 3:49 AM, Stefano Emilio Campanini <
stefano.campanini@gmail.com> wrote:
> On Sat, Sep 19, 2009 at 1:57 AM, Clinton Begin <cl...@gmail.com>
> wrote:
> > Can you open a JIRA ticket for this one?
> > Cheers,
> > clinton
>
> Done ( https://issues.apache.org/jira/browse/IBATIS-658 ).
> I have a patch that work for me, also "mvn test" results are ok (no
> postgresql is tested), how can I send it to our team ?
>
> Bye
> Stefano
>
> >
> > On Fri, Sep 18, 2009 at 10:13 AM, Stefano Emilio Campanini
> > <st...@gmail.com> wrote:
> >>
> >> Hi,
> >>
> >> I'have started using the new migrations today on a starting project.
> >> (migrations verison is 3.0 Beta 3 )
> >> We are using Postgresql 8.3.7 and at the beginning (creating the first
> >> table ) we meet a problem, after the launch of the first "migrate up".
> >>
> >> In fact using migrate status we have ...the follow error:
> >>
> >> batis-migration$ ./migrate status
> >> ID Applied At Description
> >>
> >>
> ================================================================================
> >> Exception in thread "main" java.lang.NullPointerException
> >> at java.math.BigDecimal.<init>(BigDecimal.java:724)
> >> at
> >>
> org.apache.ibatis.migration.commands.BaseCommand.getChangelog(BaseCommand.java:64)
> >> at
> >>
> org.apache.ibatis.migration.commands.StatusCommand.execute(StatusCommand.java:20)
> >> at
> >> org.apache.ibatis.migration.CommandLine.runCommand(CommandLine.java:77)
> >> at
> >> org.apache.ibatis.migration.CommandLine.execute(CommandLine.java:56)
> >> at org.apache.ibatis.migration.Migrator.main(Migrator.java:6)
> >>
> >> The follow is the unique script we have in our scripts dir, executed
> >> by the migrate up.
> >>
> >> --// Create Cliente Table
> >> -- Migration SQL that makes the change goes here.
> >>
> >> CREATE TABLE cliente
> >> (
> >> id serial PRIMARY KEY,
> >> codice varchar(50) UNIQUE NOT NULL,
> >> rag_sociale varchar(50),
> >> service_manager varchar(100),
> >> email varchar(50),
> >> certificato_pgp text
> >> );
> >> ALTER TABLE cliente OWNER TO gsd;
> >>
> >> --//@UNDO
> >> -- SQL to undo the change goes here.
> >>
> >> DROP TABLE cliente;
> >>
> >> Any ideas ?
> >>
> >> Thank you in advance
> >> Stefano
> >>
> >>
> >>
> >> --
> >> Tinvention - Ingegneria Informatica -
> >> http://tinvention.net/
> >> ing. Stefano E. Campanini
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: user-java-unsubscribe@ibatis.apache.org
> >> For additional commands, e-mail: user-java-help@ibatis.apache.org
> >>
> >
> >
>
>
>
> --
> Tinvention - Ingegneria Informatica -
> http://tinvention.net/
> ing. Stefano E. Campanini
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-java-unsubscribe@ibatis.apache.org
> For additional commands, e-mail: user-java-help@ibatis.apache.org
>
>
Re: Postgresql java.lang.NullPointerException migrate status
Posted by Stefano Emilio Campanini <st...@gmail.com>.
On Sat, Sep 19, 2009 at 1:57 AM, Clinton Begin <cl...@gmail.com> wrote:
> Can you open a JIRA ticket for this one?
> Cheers,
> clinton
Done ( https://issues.apache.org/jira/browse/IBATIS-658 ).
I have a patch that work for me, also "mvn test" results are ok (no
postgresql is tested), how can I send it to our team ?
Bye
Stefano
>
> On Fri, Sep 18, 2009 at 10:13 AM, Stefano Emilio Campanini
> <st...@gmail.com> wrote:
>>
>> Hi,
>>
>> I'have started using the new migrations today on a starting project.
>> (migrations verison is 3.0 Beta 3 )
>> We are using Postgresql 8.3.7 and at the beginning (creating the first
>> table ) we meet a problem, after the launch of the first "migrate up".
>>
>> In fact using migrate status we have ...the follow error:
>>
>> batis-migration$ ./migrate status
>> ID Applied At Description
>>
>> ================================================================================
>> Exception in thread "main" java.lang.NullPointerException
>> at java.math.BigDecimal.<init>(BigDecimal.java:724)
>> at
>> org.apache.ibatis.migration.commands.BaseCommand.getChangelog(BaseCommand.java:64)
>> at
>> org.apache.ibatis.migration.commands.StatusCommand.execute(StatusCommand.java:20)
>> at
>> org.apache.ibatis.migration.CommandLine.runCommand(CommandLine.java:77)
>> at
>> org.apache.ibatis.migration.CommandLine.execute(CommandLine.java:56)
>> at org.apache.ibatis.migration.Migrator.main(Migrator.java:6)
>>
>> The follow is the unique script we have in our scripts dir, executed
>> by the migrate up.
>>
>> --// Create Cliente Table
>> -- Migration SQL that makes the change goes here.
>>
>> CREATE TABLE cliente
>> (
>> id serial PRIMARY KEY,
>> codice varchar(50) UNIQUE NOT NULL,
>> rag_sociale varchar(50),
>> service_manager varchar(100),
>> email varchar(50),
>> certificato_pgp text
>> );
>> ALTER TABLE cliente OWNER TO gsd;
>>
>> --//@UNDO
>> -- SQL to undo the change goes here.
>>
>> DROP TABLE cliente;
>>
>> Any ideas ?
>>
>> Thank you in advance
>> Stefano
>>
>>
>>
>> --
>> Tinvention - Ingegneria Informatica -
>> http://tinvention.net/
>> ing. Stefano E. Campanini
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-java-unsubscribe@ibatis.apache.org
>> For additional commands, e-mail: user-java-help@ibatis.apache.org
>>
>
>
--
Tinvention - Ingegneria Informatica -
http://tinvention.net/
ing. Stefano E. Campanini
---------------------------------------------------------------------
To unsubscribe, e-mail: user-java-unsubscribe@ibatis.apache.org
For additional commands, e-mail: user-java-help@ibatis.apache.org
Re: Postgresql java.lang.NullPointerException migrate status
Posted by Clinton Begin <cl...@gmail.com>.
Can you open a JIRA ticket for this one?
Cheers,
clinton
On Fri, Sep 18, 2009 at 10:13 AM, Stefano Emilio Campanini <
stefano.campanini@gmail.com> wrote:
> Hi,
>
> I'have started using the new migrations today on a starting project.
> (migrations verison is 3.0 Beta 3 )
> We are using Postgresql 8.3.7 and at the beginning (creating the first
> table ) we meet a problem, after the launch of the first "migrate up".
>
> In fact using migrate status we have ...the follow error:
>
> batis-migration$ ./migrate status
> ID Applied At Description
>
> ================================================================================
> Exception in thread "main" java.lang.NullPointerException
> at java.math.BigDecimal.<init>(BigDecimal.java:724)
> at
> org.apache.ibatis.migration.commands.BaseCommand.getChangelog(BaseCommand.java:64)
> at
> org.apache.ibatis.migration.commands.StatusCommand.execute(StatusCommand.java:20)
> at
> org.apache.ibatis.migration.CommandLine.runCommand(CommandLine.java:77)
> at
> org.apache.ibatis.migration.CommandLine.execute(CommandLine.java:56)
> at org.apache.ibatis.migration.Migrator.main(Migrator.java:6)
>
> The follow is the unique script we have in our scripts dir, executed
> by the migrate up.
>
> --// Create Cliente Table
> -- Migration SQL that makes the change goes here.
>
> CREATE TABLE cliente
> (
> id serial PRIMARY KEY,
> codice varchar(50) UNIQUE NOT NULL,
> rag_sociale varchar(50),
> service_manager varchar(100),
> email varchar(50),
> certificato_pgp text
> );
> ALTER TABLE cliente OWNER TO gsd;
>
> --//@UNDO
> -- SQL to undo the change goes here.
>
> DROP TABLE cliente;
>
> Any ideas ?
>
> Thank you in advance
> Stefano
>
>
>
> --
> Tinvention - Ingegneria Informatica -
> http://tinvention.net/
> ing. Stefano E. Campanini
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-java-unsubscribe@ibatis.apache.org
> For additional commands, e-mail: user-java-help@ibatis.apache.org
>
>