SourceForge.net
2004-05-06 11:47:55 UTC
Bugs item #891758, was opened at 2004-02-06 23:33
Message generated for change (Comment added) made by tanderson
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=474136&aid=891758&group_id=54559
Category: persistence
Group: None
Priority: 5
Submitted By: Alex M. Schiroky (schiroky)
The table "Users" has a column named "password" but
this is a reserved word for Interbase, so I change the
name in the create table script for something
like "passwd" or "passwordx" only to test and the
OpenJMS have working since it except when some data
exist in these table. I take a look in your persistence
layer and found the problem and have a simple solution
for it.
In the "org.exolab.jms.persistence.Users" class all
methods use setter's and getter's by index except the
last "load" method who use them by name, look:
select = connection.prepareStatement("select * from
users");
set = select.executeQuery();
while (set.next()) {
String name = set.getString("username");
String password = set.getString("password");
}
To keep the same approach of the other methods and
works with Firebird, maybe with another one, I apply this
small change:
select = connection.prepareStatement("select * from
users");
set = select.executeQuery();
while (set.next()) {
String name = set.getString(1);
String password = set.getString(2);
}
----------------------------------------------------------------------
Message:
Logged In: YES
user_id=557161
Fixed in CVS.
I've changed the create_interbase.sql script so that the
'password' field is named 'passwd' instead.
Fix will be available in the 0.7.6.1 release.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=474136&aid=891758&group_id=54559
Message generated for change (Comment added) made by tanderson
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=474136&aid=891758&group_id=54559
Category: persistence
Group: None
Status: Closed
Resolution: NonePriority: 5
Submitted By: Alex M. Schiroky (schiroky)
Assigned to: Tim Anderson (tanderson)
Summary: DB table uses reserved word as column name
Initial Comment:Summary: DB table uses reserved word as column name
The table "Users" has a column named "password" but
this is a reserved word for Interbase, so I change the
name in the create table script for something
like "passwd" or "passwordx" only to test and the
OpenJMS have working since it except when some data
exist in these table. I take a look in your persistence
layer and found the problem and have a simple solution
for it.
In the "org.exolab.jms.persistence.Users" class all
methods use setter's and getter's by index except the
last "load" method who use them by name, look:
select = connection.prepareStatement("select * from
users");
set = select.executeQuery();
while (set.next()) {
String name = set.getString("username");
String password = set.getString("password");
}
To keep the same approach of the other methods and
works with Firebird, maybe with another one, I apply this
small change:
select = connection.prepareStatement("select * from
users");
set = select.executeQuery();
while (set.next()) {
String name = set.getString(1);
String password = set.getString(2);
}
----------------------------------------------------------------------
Comment By: Tim Anderson (tanderson)
Date: 2004-05-06 21:47Message:
Logged In: YES
user_id=557161
Fixed in CVS.
I've changed the create_interbase.sql script so that the
'password' field is named 'passwd' instead.
Fix will be available in the 0.7.6.1 release.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=474136&aid=891758&group_id=54559