By David on Wednesday, 26 February 2020
Posted in General Issues
Replies 3
Likes 0
Views 3.5K
Votes 0
Hi guys, this is important to correctly display the most popular posts in any modules and pages. As this is such a critical issue when migrating to the new composer, I'm sure you've got it covered.

I know I can make a new post with the new composer and just copy over the contents of the old post. But how do I carry over all the stats (like hit counter) from the old post?

If need be, I'm ready to follow your instructions to do it via database, but please a batch procedure, not one by one.

Thanks
Hey there,

You can run the following SQL query with the old post id to know its hit:

SELECT `hits` FROM `jos_easyblog_post` WHERE `id` = 123;


Replace the 123 with your old post id.

After that, run the following SQL query to update the new post's hit:

UPDATE `jos_easyblog_post` SET `hits` = 7 WHERE `id` = 123;


Replace the 123 with your new post id and replace the 7 with the old post's hit.

Take note that you need to replace the jos with your table prefix before you run the queries.

Also, may I know what do you mean stats of the post?
·
Wednesday, 26 February 2020 12:03
·
0 Likes
·
0 Votes
·
0 Comments
·
Thanks a lot Irwin! It slipped between my fingers back then and I just wanted to thank you. It helped!!

I can't remember what I meant with stats but I'll let you know if I do
·
Wednesday, 04 November 2020 11:15
·
0 Likes
·
0 Votes
·
0 Comments
·
You're most welcome.
·
Wednesday, 04 November 2020 11:24
·
0 Likes
·
0 Votes
·
0 Comments
·
View Full Post