Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to use another user's database

 
Francesc Roure
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am thinking to integrate JForum to my Java application, but I don't know if JForum can works with a different user's database. On my site users already have accounts registered, and I want to take profit of these accounts. Is there a way to integrate these users to JForum and use the login they make in the application?

Thanks.
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34193
340
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You could run a script to change the user ids to be unique to your database and then import the table. In other words:

1) Set sequence on your database to resume at 100000 or something high.
2) Add 50000 to all userids in source database
3) Import source database to your database

And make sure there aren't duplicate usernames.
 
Francesc Roure
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The idea is to have the same IDs in both databases?

I don't know if it's going to resolve the problem. I want logged users in my site can use the forum without have to login again. In my database every user have a username, and I want use it as forum's username.
Maybe I am going to change jforum's core to achieve it.
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34193
340
Eclipse IDE Java VI Editor
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Oh. I thought you wanted to do a one time migration.

To accept a login from another site, you don't need to migrate. But you do need to change the code (two recognized two databases.) And have unique ids or a formula to make the ids unique.
 
Toni Mergeani
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Francesc Roure wrote:I am thinking to integrate JForum to my Java application, but I don't know if JForum can works with a different user's database. On my site users already have accounts registered, and I want to take profit of these accounts. Is there a way to integrate these users to JForum and use the login they make in the application?

Thanks.



Hi, I want the exact same thing. Did you found out how to do it?. Thanks
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic