最新消息:Welcome to the puzzle paradise for programmers! Here, a well-designed puzzle awaits you. From code logic puzzles to algorithmic challenges, each level is closely centered on the programmer's expertise and skills. Whether you're a novice programmer or an experienced tech guru, you'll find your own challenges on this site. In the process of solving puzzles, you can not only exercise your thinking skills, but also deepen your understanding and application of programming knowledge. Come to start this puzzle journey full of wisdom and challenges, with many programmers to compete with each other and show your programming wisdom! Translated with DeepL.com (free version)

migration - Update around 200,000 posts

matteradmin4PV0评论

So I have recently migrated from a regular site to a wordpress CMS all via MySQL. I successfully was able to adapt the old database with that of WordPress.

Now, the site has content in 3 languages. I am using polylang to achieve that. I have successfully created the taxonomy relationships and I can see that all my posts have the required language id. I also have around 60 Categories. Polylang has a feature where if the post is updated (not the database update) the required categories are created on the fly in the posts' language. I have tested this with a manual update and it works. But the problem is I am unable to find a solution to bulk update all the posts together at once.

I tried what is written here But then I just get an error 500 when I reload the site ("localhost is unable to handle this request). First I thought that this is an error of the memory limits and execution time. I have set it all to unlimited but with no success. I am using BITNAMI WAMP stack on Windows as my development server.

Any help will be a great one!

Thanks in advance.

So I have recently migrated from a regular site to a wordpress CMS all via MySQL. I successfully was able to adapt the old database with that of WordPress.

Now, the site has content in 3 languages. I am using polylang to achieve that. I have successfully created the taxonomy relationships and I can see that all my posts have the required language id. I also have around 60 Categories. Polylang has a feature where if the post is updated (not the database update) the required categories are created on the fly in the posts' language. I have tested this with a manual update and it works. But the problem is I am unable to find a solution to bulk update all the posts together at once.

I tried what is written here But then I just get an error 500 when I reload the site ("localhost is unable to handle this request). First I thought that this is an error of the memory limits and execution time. I have set it all to unlimited but with no success. I am using BITNAMI WAMP stack on Windows as my development server.

Any help will be a great one!

Thanks in advance.

Share Improve this question edited Apr 5, 2019 at 18:43 Byte IT Antwerpen asked Apr 5, 2019 at 18:29 Byte IT AntwerpenByte IT Antwerpen 15 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 0

You mentioned setting the memory limits and execution time to unlimited, so this may not be the right answer. I thought I'd mention it anyway since it may help.

Since you have so much content, you'll have to find ways to accomplish this in the background rather than during the request. This is the perfect situations for scheduled tasks.

This would allow you to schedule an update that will run when cron runs rather than within the scope of the request.

You can also use WP CLI to write a command that will accomplish this. This allows you to run this manually and/or schedule this with cron.

Hope this helps.

Post a comment

comment list (0)

  1. No comments so far