How to clean up custom phrases left by uninstalled products?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • AbdullahSZ
    New Member
    • Oct 2009
    • 19
    • 3.8.x

    [Forum] How to clean up custom phrases left by uninstalled products?

    There are way too many of unused phrases. Is there a way to delete them with few clicks?

    Thanks.

  • Sebastiano Vassellatti
    Former vBulletin QA
    • Aug 2008
    • 842
    • 5.5.x

    #2
    Can you please tell me which is the fieldname of each phrase group that contains the phrases you want to remove? (For example, "adv_gallery" for the phrase group displayed in your screenshot)

    Comment

    • AbdullahSZ
      New Member
      • Oct 2009
      • 19
      • 3.8.x

      #3
      adv_gallery
      adv_gallery_cp
      adv_gallery_ecard
      adv_gallery_showimg
      adv_gallery_upload
      adv_portal_cp

      There's a phrase type that is empty, no fieldname or anything. How can I delete the empty one and the blank ones?

      Comment

      • Sebastiano Vassellatti
        Former vBulletin QA
        • Aug 2008
        • 842
        • 5.5.x

        #4
        Backup your database first. Then go in Maintenance -> Execute SQL Query -> Manual Query.
        Run these queries:

        DELETE FROM phrase WHERE languageid='0' AND fieldname='adv_gallery'
        DELETE FROM phrase WHERE languageid='0' AND fieldname='adv_gallery_cp'
        DELETE FROM phrase WHERE languageid='0' AND fieldname='adv_gallery_ecard'
        DELETE FROM phrase WHERE languageid='0' AND fieldname='adv_gallery_showimg'
        DELETE FROM phrase WHERE languageid='0' AND fieldname='adv_gallery_upload'
        DELETE FROM phrase WHERE languageid='0' AND fieldname='adv_portal_cp'
        Originally posted by AbdullahSZ
        There's a phrase type that is empty, no fieldname or anything. How can I delete the empty one and the blank ones?
        If you delete all the phrases that belong to this phrase group, the phrase group itself should disappear. However if there is no filedname for this phrase group I think you cannot remove them with a query, but you will need to delete all the phrases of this phrase group manually.

        Comment

        • AbdullahSZ
          New Member
          • Oct 2009
          • 19
          • 3.8.x

          #5
          Great! It did remove all phrases but not the phrase type.

          What about the ones inside GLOBAL?

          Comment

          • Sebastiano Vassellatti
            Former vBulletin QA
            • Aug 2008
            • 842
            • 5.5.x

            #6
            Originally posted by AbdullahSZ
            Great! It did remove all phrases but not the phrase type.
            You can then try with these queries to remove also those phrase types:

            DELETE FROM phrasetype WHERE fieldname='adv_gallery'
            DELETE FROM phrasetype WHERE fieldname='adv_gallery_cp'
            DELETE FROM phrasetype WHERE fieldname='adv_gallery_ecard'
            DELETE FROM phrasetype WHERE fieldname='adv_gallery_showimg'
            DELETE FROM phrasetype WHERE fieldname='adv_gallery_upload'
            DELETE FROM phrasetype WHERE fieldname='adv_portal_cp'

            If the phrase type that has not been deleted is the one that had no field name, you can try with:

            DELETE FROM phrasetype WHERE fieldname=''

            This should work.
            Originally posted by AbdullahSZ
            What about the ones inside GLOBAL?
            I think you should manually delete the phrases you want to delete. The GLOBAL phrase group also contains the phrase you created with thread prefixes and notices (if you have created some of them), so you can't use a query like the ones above because it would delete these phrases too.

            Comment

            • AbdullahSZ
              New Member
              • Oct 2009
              • 19
              • 3.8.x

              #7
              The blanks ones are gone now . Thank you!

              The empty one goes by vBadvanced CMPS. I tried the following but didn't work.

              DELETE FROM phrasetype WHERE fieldname='vBadvanced CMPS'

              Comment

              • Sebastiano Vassellatti
                Former vBulletin QA
                • Aug 2008
                • 842
                • 5.5.x

                #8
                Try this:

                DELETE FROM phrasetype WHERE title='vBadvanced CMPS'

                Comment

                • AbdullahSZ
                  New Member
                  • Oct 2009
                  • 19
                  • 3.8.x

                  #9
                  I added a new phrase to it which made the fieldname appear (sneaky).

                  Originally posted by Darkshenron
                  Try this:

                  DELETE FROM phrasetype WHERE title='vBadvanced CMPS'
                  It worked.

                  Thank you very much Darkshenron!

                  Comment

                  widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
                  Working...