Help coderanch get a
new server
by contributing to the fundraiser
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Devaka Cooray
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Tim Moores
  • Carey Brown
  • Mikalai Zaikin
Bartenders:
  • Lou Hamers
  • Piet Souris
  • Frits Walraven

jforum_user.user_lastvisit is never updated

 
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
All is in title

See UserModel.update in generic_queries.sql and public void update(User user) in GenericUserDAO.java

Modifying in generic_queries.sql :
UserModel.update = UPDATE jforum_users SET user_aim = ?, \
user_avatar = ?,\
gender = ?, \
themes_id = ?,\
user_allow_pm = ?, \
user_allowavatar = ?, \
user_allowbbcode = ?, \
user_allowhtml = ?, \
user_allowsmilies = ?, \
user_email = ?, \
user_from = ?, \
user_icq = ?, \
user_interests = ?, \
user_occ = ?, \
user_sig = ?, \
user_website = ?, \
user_yim = ?, \
user_msnm = ?, \
user_password = ?, \
user_viewemail = ?, \
user_viewonline = ?, \
user_notify = ?, \
user_attachsig = ?, \
username = ?, \
user_lang = ?, \
user_notify_pm = ?, \
user_biography = ?, \
user_lastvisit = ?, \
WHERE user_id = ?

In GenericUserDAO.java :
public void update(User user) throws Exception
.
.
.
// REDHAND MOD
// p.setInt(28, user.getId());
p.setTimestamp(28, new Timestamp(user.getLastVisit().getTime()));
p.setInt(29, user.getId());

but LastVisit should be set before ... more soon

[originally posted on jforum.net by redhand]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks.

I added your fix to the cvs

Rafael
[originally posted on jforum.net by Rafael Steil]
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic