Search code examples
expressionengine

Batch Edit Custom Fields


I need to batch edit a new custom field I have added to a channel for about 200 entries in that channel. Is there a way to accomplish this? Cannot find a way so far.


Solution

  • If I am understanding you correctly, try this:

    UPDATE exp_channel_data SET field_id_X = 'some value' WHERE channel_id = 1;
    

    This code will update 1 field in all the rows on the channel with an id of '1'. Obviously replace field_id_X with the correct field. Just be sure to do a complete SQL backup before you make any changes. If any problems arise, but revert back to the last known working install. (Just be careful and you shouldn't have any issues.)