james-server-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Eung-ju Park" <co...@isoft.co.kr>
Subject Re: latest cvs compile but doesn't start up
Date Wed, 12 Sep 2001 01:17:50 GMT

----- Original Message -----
From: "Gabriel Bucher" <gabriel.bucher@razor.ch>
To: <james-dev@jakarta.apache.org>
Sent: Wednesday, September 12, 2001 5:06 AM
Subject: Re: latest cvs compile but doesn't start up


> Serge Knystautas wrote:
> > It's supposed to have 2 primary keys.
> >
> > You need to be able to store a message with the same message_name in the
> > same table as it could reside in multiple repositories.  For instance,
if a
> > message gets delivered to 2 people with inboxes, they would have the
same
> > message name and different repositories (inbox/user1 and inbox/user2)
> >
>
> Ok, that's true.
> I'm using the 'org.gjt.mm.mysql.Driver' JDBC Driver and get the
> following exception if james try to create the new table 'message'!
>
> java.sql.SQLException: Invalid argument value: Multiple primary key
defined
> at org.gjt.mm.mysql.MysqlIO.sendCommand(MysqlIO.java:497)
> at org.gjt.mm.mysql.MysqlIO.sqlQueryDirect(MysqlIO.java:550)
> at org.gjt.mm.mysql.Connection.execSQL(Connection.java:885)
> at org.gjt.mm.mysql.PreparedStatement.execute(PreparedStatement.java:1093)
> at
>
org.apache.james.mailrepository.JDBCMailRepository.initialize(JDBCMailReposi
tory.java:251)
> at org.apache.james.core.AvalonMailStore.select(AvalonMailStore.java:211)
> at
org.apache.james.core.AvalonMailStore.initialize(AvalonMailStore.java:98)
>
>
> What I think, the mysql Driver has a bug or doesn't support his!?!

try

message_name varchar (200) NOT NULL,
repository_name varchar (200) NOT NULL,
message_state varchar (30) NOT NULL ,
error_message varchar (200) NULL ,
sender varchar (200) NULL ,
...
...
PRIMARY KEY (message, repository_name),
...
...

instead of

message_name varchar (200) NOT NULL PRIMARY KEY,
repository_name varchar (200) NOT NULL PRIMARY KEY,
message_state varchar (30) NOT NULL ,
error_message varchar (200) NULL ,
sender varchar (200) NULL ,
...
...




---------------------------------------------------------------------
To unsubscribe, e-mail: james-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: james-dev-help@jakarta.apache.org


Mime
View raw message