WordPress.org

Make WordPress Core

Changes between Initial Version and Version 1 of Ticket #11302, comment 47


Ignore:
Timestamp:
09/20/2019 01:05:33 PM (14 months ago)
Author:
samba45
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #11302, comment 47

    initial v1  
    1 Possibile soluzione, interrompere la relazione SQL tra post e category con script da phpmyadmin.
    2 Del tipo:
    3 Supponiamo di avere il prefisso della tabella wp_blog, lanciando il comando “delete from wp_blog_term_relationships where term_taxonomy_id = 1 and object_id in (select id from wp_blog_posts where post_type = 'post' and post_status = 'publish’);” rompiamo la correlazione fra i due elementi (post e uncategorized) questa azione ha valore solo su il post settati su “pubblicati”.
    4 Riportiamo il valore counter della categoria uncategorized.
    5 Da phpmyadmin:
    6 “update wp_blog_term_taxonomy set count = 0 where term_taxonomy_id = 1;”
    7 Metodo da usare con cautela, rischio danneggiamento database SQL, fare backup prima di qualsiasi azione.
    8 Risultato : Rimuove “uncategorized dai post”
     1Possible solution, interrupt the SQL relationship between post and category with scripts from phpmyadmin.
     2Of the type:
     3Suppose we have the table prefix wp_blog, launching the command "delete from wp_blog_term_relationships where term_taxonomy_id = 1 and object_id in (select id from wp_blog_posts where post_type = 'post' and post_status = 'publish');" we break the correlation between the two elements (post and uncategorized) this action has value only on the post set to "published".
     4We report the counter value of the uncategorized category.
     5From phpmyadmin:
     6"Update wp_blog_term_taxonomy set count = 0 where term_taxonomy_id = 1;"
     7Method to use with caution, risk damaging SQL database, make backups before any action.
     8Result: Removes "uncategorized from posts"