HowTo: Add existing users as entries in the GravityForm User Registration Form (without duplicating them) [RESOLVED]

Greetings and Happy Holidays,

I have a project where there are already about 200+ users. These users were registered using WordPress’s native user registration process.

I have since, enabled the Gravity Forms User Registration Add-On as well as the GravityWiz’ Better User Activation perk. And it was good!

Now I have a need to display user profiles on the front-end as well as allow users to upgrade their own profiles. My solution to this was to use GravityView but here is where things ground to a halt: GravityView cannot see users that do NOT have entries in the user registration form.

What I need: I need a way to import my existing WP users as User Registration Entries while also NOT duplicating them in the system (or changing their passwords, if possible).

Can this be done?

Please advise,

Preston

What may be possible is to export your current users with this plugin Export and import users as a CSV

And then use Gravity View import entries plugin to import the CSV data. The gravity view import entries plugin allows you to use an existing form and you can trigger your update user feed for that form.

Since the users are already registered and Gravity Forms registers user to Wordpress, you should be able to update the users you already have without duplicating any of them.

Once the users have been updated, gravity view should be able to populate your merge tags in a view.

The only issue is perhaps the CSV file that is exported may need to be modified before importing. You should reach out to Gravity View directly to inquire about this.

Perhaps someone from Gravity Forms can confirm that the update user feed can work for users registered to the site without Gravity Forms. @chrishajer

Great Idea Derek,

Last night it dawned on me that I already had WP All Import Pro, so the one difference to your solution was that I used All Export Pro to handle the export.

Did that as well, imported directly into the Registration Form as entries, but I did not try to trigger the Update User" feed. Theoretically, that’s a dang good idea, and certainly worth a shot :crossed_fingers: .

On it now. Will report back.

I did. They hit me with The Nuclear Option (and then recommended I not use it :fearful:).

From GravityView…

You can use export your existing WordPress Users into a CSV file, delete them all from your WordPress and use our Import Entries plugin to import a CSV containing all your users’ information into a form that has a create user feed from the User Registration add-on, but that will re-add your WordPress Users from scratch and they will lose any references to existing content on your website if they already created anything (posts or pages). Also, their passwords will be reset. I honestly don’t recommend this approach unless really necessary.

I appreciated the warning, and no, we won’t be doing that.

…more news as it happens.

Preston

1 Like

Update: Queried GForms Support. Here is their response.

Gravity Forms doesn’t have a way to export users and importing entries is also not a feature.

It’s also important to note that there is no connection between a form entry and a user so updating the entry that created the user wouldn’t update the user and vice versa.

If you create a separate form with a user registration update type feed the mapped fields on that form will be populated with the logged in user details and will update the user with the submitted values.

So yeah, it looks like the best approach is to export, then import the users into “a form” which then triggers the “update user” feed. However, there are still a couple of dark spots in my understanding of this approach (esp. since i’m still relatively new to GravityView):

  1. To my understanding, I need to use “User Registration” form to create a view for GravityView User Profiles.
  2. If that is the case, the “User Registration” form only triggers the “Create User” feed.
  3. Therefore, I would have to use the “Update User” form which (I’m assuming) would allow me to access those existing users for my User Profile View

So my question is, if I use the “Update User” approach and use these entries as the data source for my user profile view, how then do I merge both the updated (i.e. existing) users with any new users coming from User Registration entries?

Thanks,
Preston

If you are using Gravity View for user profiles you will want to use their “Join Condition” feature. This allows you to use separate forms that essentially contain the same data for one view.

If you’re concerned about potential issues you could always use a staging site to perform this task. Take a full backup including your database before importing your users CSV. That way you can always restore a backup or you can copy your production site to your staging site.

Depending on the # of users your current site has you could always turn this in a live environment and then restore the site if you needed to.

Thanks Again Derek,

I will RTFM on the “Join Condition” feature (didn’t know it existed) and I also will setup a staging site so I can “break things” without worry :rofl:

Thank you again for all your input! Very helpful.

…more news as it happens!

Preston

1 Like

Update:

  1. I created a registration form and an update form.
  2. I exported all users and ran import entries with trigger feed (and authentication off)
  3. That added all the existing users was “update entries”.
  1. I enabled Gravity View’s multiple forms addon and then worked with the “Join Condition” feature, but quickly realized that this is only adding additional data to existing entries where fields match between both forms.
  2. AFAIK, this does NOT allow me to merge entries from one form into another.
  3. They even spell it out in this article: Multiple Forms: Unions are not supported.

So… i’m pretty much back where I started. I still have users in two separate forms and therefore cannot use them all in one view.

I’m not sure why you need a view for the user registration feed. Why not just create a view with the update user feed?

Plus, you can use Gravity Forms and Gravity Views User and Created by tag pretty much anywhere on your website.

So, whatever the latest input is for the users say email address, you would just add {user:user_email} and that will display the email address of the currently logged in user.

Plus, if you still need to join information, with Gravity View joins, then just don’t add the merge tags from the registration form for the fields you updated in your user update feed.

To make matters even more complex for you, you can always use Gravity Flow form connector extension to just update the user registration feed with the entry data of the update user form you recently created.

So basically after you import the data for the update user form, you can update the original user registration form with the form connector extension. You can add new fields to the user registration form as well and update those fields.

Then you would have access to all of the data inside the view without using Joins. If I am fully understanding your use case, the form connector extension should work. I would still give my other suggestion a go if you don’t already own a copy of Gravity Flow.

PPS: lol

Why couldn’t you also just create an update user feed on the registration form? You would just add a simple condition to the registration feed to trigger the correct feed on import.

There’s a few options for you. Personally, I think Gravity Flows form connector would be your best bet. @JamieO

Because if someone registers and does not do an update, they won’t be in the view, or am I missing something.

Everything else in this post when straight over my head. Once again, I’m still pretty green using Gravity View, so keep that in mind. Once I put a bit more time into Gravity View the remaining options you present may become clearer to me.

Preston

But to me, it’s like overkill for what i’m trying. In other words, I feel like I should not need to use Gravity Flow to accomplish this task.

I actually had a developer license for Gravity Flow, but I’m letting it expire because -other than to play with- I did not use it in a single project for a full year. Great tool. I just didn’t need it, and the developer cost is hard to justify in that case.

Now we’re talking. Actually I did try this last night and still got some of the strangest results. I finally figured it out, but you will not believe the cause of all my heartburn.

  1. I set up a testing site using Local by Flywheel
  2. To simulate existing users, I added some fake users using Faker Press (bypassing the User Registration feed).
  3. I exported those users using WP All Export Pro (with User Export Add-On)
  4. I setup a stand alone update profile form/feed to test importing.
  5. I imported the csv generated from WP All Export Pro.
  6. The records went into the form, but completely mangled my actual user profile (literally changed my name to one of the existing records and other weirdness).
  7. I reviewed all my notes read everything I could find on Gravity Forms, GravityView and any place else I thought might provide a clue. …nothing. Every import caused …anomalies.
  8. Finally, I decided to see if it was the actual csv file that was causing the errors.
  9. So I deactivated WP All Export Pro and installed the “Import and export users and customers” plugin.
  10. I did another export, then ran the same import procedure, only now using the new csv from Import and export users and customers.

…and BINGO! It worked!

Da heck?!? …so I tested it again (and again) …and yep, same thing.

  1. I could successfully reproduce the anomaly every time I imported a csv generated from WP All Export Pro.
  2. I could successfully import records with no anomalies using the csv generated from Import and export users and customers.

…go figure.

So then I did get the Gravity Wiz plugin Allow Update & Create Feeds on Same Form and set up the conditionals for registering and updating and then I tested some more.

Again, the import failed with WP All Export Pro csv and worked like a charm with the Import and export users and customers csv.

In closing, both csv’s opened without issue in Excel. I even opened them in a text editor and could see no issues. So I have no idea why one csv worked and the other crashed and burned.

But at least i’m out of the weeds on this issue. I thought I would report all of this in case anyone else ran into this bizarre csv issue.

p.s. I LOVE the Import and export users and customers. Good call, Derek @user5c0166073a6c48.6 Thanks again for all your help! Happy Holidays!

2 Likes