Title: Bulk Edit, on solution
Last modified: June 28, 2017

---

# Bulk Edit, on solution

 *  Resolved [mullergregoire](https://wordpress.org/support/users/mullergregoire/)
 * (@mullergregoire)
 * [8 years, 10 months ago](https://wordpress.org/support/topic/bulk-edit-on-solution/)
 * Hi,
 * I have find a solution for bulk editing in members plugin.
    I wanted to add credentials
   for an entire post category with thousands of posts. I did not find any answer
   on the web, so I have made a SQL request to add on your phpMyAdmin to.
 * First, the most important, do an SQL backup of your database before any change!
   
   Next, insert this code on your phpMyAdmin
 *     ```
       INSERT INTO wp_postmeta (post_id,meta_key,meta_value)
       -- First find the ID of the post of a specific category (wp_posts.post_type)
       SELECT DISTINCT ID,'_members_access_role','subscriber' FROM wp_posts -- change 'subscriber' by the user type you wanted to change credentials
       JOIN wp_postmeta ON wp_postmeta.post_id = wp_posts.ID
       WHERE wp_postmeta.post_id NOT IN (SELECT ID FROM wp_postmeta JOIN wp_posts ON wp_posts.ID = wp_postmeta.post_id WHERE wp_postmeta.meta_key = ('_members_access_role')) -- check that the post did not have any previous credentials
       AND wp_posts.post_type = 'category_of_posts' -- change this name with the name of the posts' category you wanted to change the credentials
       ```
   
    -  This topic was modified 8 years, 10 months ago by [mullergregoire](https://wordpress.org/support/users/mullergregoire/).
    -  This topic was modified 8 years, 10 months ago by [Steven Stern (sterndata)](https://wordpress.org/support/users/sterndata/).

The topic ‘Bulk Edit, on solution’ is closed to new replies.

 * ![](https://ps.w.org/members/assets/icon-256x256.png?rev=3508404)
 * [Members - Membership & User Role Editor Plugin](https://wordpress.org/plugins/members/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/members/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/members/)
 * [Active Topics](https://wordpress.org/support/plugin/members/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/members/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/members/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [mullergregoire](https://wordpress.org/support/users/mullergregoire/)
 * Last activity: [8 years, 10 months ago](https://wordpress.org/support/topic/bulk-edit-on-solution/)
 * Status: resolved