Forums / General / create ezpublish users from a script

create ezpublish users from a script

Author Message

Ruben Torres

Tuesday 06 April 2004 11:36:16 pm

Hello,

I'm migrating a users database to ezpublish and I want to use a script to create
all my users in ezpublish without having to do this one by one. What tables do I
have to use? Does someone has a functional script like this and wants
to share it with me? I would really appreciate this because Im in a hurry.

Using ezp 3.3-3 and postgresql 7.3.4-4 over Fedora.

Marco Zinn

Thursday 15 April 2004 2:30:04 pm

I suggest, that you have a look at the "contribution" section. There are scripts for migration ez2-DBs to ez3.
This includes user groups and users, which are read (via SQL) from an ez2-table or two and creates users in ez3 by calling the ezPublish API for this. This worked well for me and should be easy to adapt for another SQL DB, when you know and understand that structure.
Note, that you will need to make up your mind about permissions and roles, as this script does not take care of this, as the concept was changed completly between ez2 and ez3.
How many users do you need to migrate?
The import scripts are not very fast!

(PS: Maybe it's an option to create an ez2-like table structure from your data, so you could just "run" that existing script).

Marco
http://www.hyperroad-design.com