File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JForum and the fly likes How to use another user's database Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » JForum
Bookmark "How to use another user Watch "How to use another user New topic
Author

How to use another user's database

Francesc Roure
Greenhorn

Joined: Jul 25, 2012
Posts: 2
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
internet detective
Marshal

Joined: May 26, 2003
Posts: 29246
    
139

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.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
Francesc Roure
Greenhorn

Joined: Jul 25, 2012
Posts: 2
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
internet detective
Marshal

Joined: May 26, 2003
Posts: 29246
    
139

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.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to use another user's database
 
Similar Threads
Webapp Integration -- SSO issues
Advance jForum Integration
MD5.crypt() problem
Complex integration question - multiple jforums -> caching problem?
integrating jforum with ejb3 environment