• Resolved duschsocke

    (@duschsocke)


    Hey,
    I am trying to search-replace entries in tablepress data and have not succeeded. In a different post it was stated their data was stored in wp_posts and settings + meta data in wp_postmeta.

    Unfortunately my tablepress entries not seem to be touched after running wp search-replace 'foo' 'bar' wp_posts wp_postmeta.

    Do you have another hint for me? I have over 300 tablepress tables with lots of data.

    Best wishes,
    William

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi,

    thanks for your post, and sorry for the trouble.

    Correct, TablePress stores the table content as JSON-encoded strings in the post_content field of its entries in the wp_posts database table, plus some meta data in the wp_postmeta table.

    What exactly are you searching/replacing? It might be necessary to escape special characters like " with a \, i.e. \".

    Regards,
    Tobias

    Thread Starter duschsocke

    (@duschsocke)

    Hey Tobias,
    I recently updated a url-cloak plugin and have ten thousands of /wp/go/ urls from the old version. The new version does not support the tag /wp/ due to the name restriction. Therefore, I now have lots of 301 redirects from /wp/go/ to /go/. I successfully search-replaced all occurrences but the ones from tablepress. And since I have a loooot of tablepress tables, this is a real bummer for me.

    Best wishes,
    William.

    • This reply was modified 7 years, 7 months ago by duschsocke.
    Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi,

    can you repeat the search/replace with searching for \/wp\/go\/ and replacing with \/go\/, please? Slashes / also need to be escaped with an extra \.

    Regards,
    Tobias

    Thread Starter duschsocke

    (@duschsocke)

    Hi Tobias,
    unfortunately the backslashes did not yield any new hits.

    Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi,

    sorry, then I’m out of ideas here. You will have to find out why your wp CLI is not finding the data then. Maybe it’s not taking into account Custom Post Types?
    Can you maybe try a direct SQL query, e.g. in a tool like phpMyAdmin?

    Regards,
    Tobias

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Search-replacing Tablepress db entries’ is closed to new replies.