Import Users and by Username instead of ID

We are migrating a large database of users (5000+) from a Joomla Community Builder platform to S2Members Pro. Frustratingly, the user data can only be exported from Joomla in two separate CSV files that have different sets of data. One file contains the user information the other contains the subscription information.

The only field that the two csv files have in common is the username.

We need to import the first CSV and then update the users by importing the second CSV.

The problem is that after importing the first CSV, user IDs are automatically generated and S2 member needs to have the user ID to update the users with the second CSV. We would have to manually find and insert the user ID’s into the second CSV or export from S2 and manually merge the data somehow. Ouch.

I’d really like to be able to tell S2 member to match the users by the username when importing instead of the ID. Since usernames are unique it seems like it should be possible to do this without creating conflict.

Can this be done? or is there some other solution I’m not thinking of?

Here is a link to an image of the simplified version of the two files.

Thanks!

This isn’t a job for s2Member. You need to get your CSV files sorted out before importing them for s2Member to use.

That’s a job for Excel or Calc or some other office (or cloud) program. Try Googling.

For example, how about this idea: http://superuser.com/questions/609713/excel-merging-to-data-sets-based-on-a-common-field

@AJD: If other methods to merge CSV files falls, I can help you with a custom script, it’s maybe 20-30 rows of code.

BTW, I have assembled “How to use s2Member Pro export/import function” manual, may be help for you, s2M needs exactly column names.

1 Like

@KTS915 Hi. Thanks. I was hoping that there was a filter in S2 to simply switch the user import matching from ID to Username, if there isn’t then CSV manipulation is the only option.

@krumch Thanks. I’ll post back as I have time to dig into the Calc functions.