Announcement

Collapse
No announcement yet.

Power Search Error When Rebuilding Search File

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Power Search Error When Rebuilding Search File

    I keep getting an error whenever I try to rebuild the search file in power search:

    Miva Merchant has encountered a fatal error and is unable to continue. The following information may assist you in determining the cause of the error:

    Error Code: MER-UTL-POW-00007
    Description: mysql_stmt_prepare: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version
    Other Information:
    Version: 5.0950 of the power search module.
    Miva Merchant 9.0003
    MivaScript Engine v5.22
    Database API: mysql

    I have tried to troubleshoot it by selecting only one field (name) in the power search settings, and then trying to rebuild the search file using JUST that one (name) in the Rebuild Power Search Field, yet even when pick only one field, it doesn't work.

    Thanks in advance.

    ~~~~~

    Oh, one more thing: is there still an option / need to Pack Data Files??? Can't seem to find it in the admin when using the admin search function.
    Mark Romero
    ~~~~~~~~

    #2
    Re: Power Search Error When Rebuilding Search File

    Bill replied to your other thread about custom field code names possibly causing this. Please send those in. The docs should reflect names that cannot be used.

    If there is a bug that is allowing incorrect SQL to be generated and sent, we can get that corrected.
    David Hubbard
    CIO
    Miva
    [email protected]
    http://www.miva.com

    Comment


      #3
      Re: Power Search Error When Rebuilding Search File

      See my response in your previous post and answer the question in this post.
      Bill Weiland - Emporium Plus http://www.emporiumplus.com/store.mvc
      Online Documentation http://www.emporiumplus.com/tk3/v3/doc.htm
      Question http://www.emporiumplus.com/mivamodu...vc?Screen=SPTS
      Facebook http://www.facebook.com/EmporiumPlus
      Twitter http://twitter.com/emporiumplus

      Comment


        #4
        Re: Power Search Error When Rebuilding Search File

        The power search creates a mirror of the products database and its custom fields. If the field codes violate the MySQL rules, then it fails with that exact error when building the mirror. For example, hyphens are not allowed in field codes in MySQL. Or if more than one field has the same letters as the first 10 letters in the code, duplicate field error is generated. Then there are some reserved words that can't be used. It is all in the docs.
        Bill Weiland - Emporium Plus http://www.emporiumplus.com/store.mvc
        Online Documentation http://www.emporiumplus.com/tk3/v3/doc.htm
        Question http://www.emporiumplus.com/mivamodu...vc?Screen=SPTS
        Facebook http://www.facebook.com/EmporiumPlus
        Twitter http://twitter.com/emporiumplus

        Comment


          #5
          Re: Power Search Error When Rebuilding Search File

          Here are my custom field CODES:

          alsobought
          altspell
          custom_category_title
          custom_cat_tree
          custom_meta_description
          dimension
          flyout_blurb
          head_title_add
          inclfile
          New_Head
          origin
          product-flag
          rating
          related_product_image
          reviews
          short_cat_desc
          short_name
          vendors
          waitlist

          The one that has a hyphen (which I guess violates the MySQL rules) is the "product-flag" custom code.

          however, the instructions / xml provisioning file for the suivant ready theme say to create that "product-flag" custom product field, don't they?

          Code:
          <Module code="customfields" feature="fields_prod">
              <ProductField_Add>
                  <Code>product-flag</Code>
                  <Name>Product Flag</Name>
                  <FieldType>dropdown</FieldType>
              </ProductField_Add>
              <ProductFieldTypeOption_Add code="product-flag" value="HOT" />
              <ProductFieldTypeOption_Add code="product-flag" value="NEW" />
              <ProductFieldTypeOption_Add code="product-flag" value="none" />
              <ProductFieldTypeOption_Add code="product-flag" value="SALE" />
          </Module>
          Maybe it is the first ten letters of these two files:

          custom_category_title
          custom_cat_tree

          Is it possible to just go in and edit the custom field codes in the Utility Settings > Custom Fields without wreaking havoc on everything???
          Last edited by Siamese-Dream.Com; 07-20-15, 01:34 PM.
          Mark Romero
          ~~~~~~~~

          Comment


            #6
            Re: Power Search Error When Rebuilding Search File

            You identified the 3 that violate. So the way to get around it is just list the essential custom codes that you want searchable in the input for that (assuming you have a fairly current version of the module). So as example in that configuration field only put
            short_name,vendors
            The mirror will only include those two custom fields, plus whatever basic fields (name, code, descrip, etc) that you checked the boxes for in the configuration.

            If you leave that custom field configuration blank, it will try to use all of the custom fields in the mirror and you will get errors on those 3 fields.
            Last edited by wcw; 07-20-15, 01:50 PM.
            Bill Weiland - Emporium Plus http://www.emporiumplus.com/store.mvc
            Online Documentation http://www.emporiumplus.com/tk3/v3/doc.htm
            Question http://www.emporiumplus.com/mivamodu...vc?Screen=SPTS
            Facebook http://www.facebook.com/EmporiumPlus
            Twitter http://twitter.com/emporiumplus

            Comment


              #7
              Re: Power Search Error When Rebuilding Search File

              Unfortunately, I still seem to have problems.

              In the settings ( which is in Utility Settings > Power Search ) the ONLY field I have checked is "vendors"

              In the screen with the Rebuild Power Search File, I typed in ONLY the code "vendors" (without any quotation marks).

              I still get the same error message after clicking the next button.

              Same thing happens if, say, I try to use two codes, such as "vendors" and "altspell"
              Mark Romero
              ~~~~~~~~

              Comment


                #8
                Re: Power Search Error When Rebuilding Search File

                One other thing:

                I deactivated power search, and then I reactivated it, and when I went to the STOREFRONT and searched for something, I got this error message:

                Runtime error in mm5/5.00/modules/util/powrsrch.mvc @ [00000018:00001dbc]: powrsrch.mv: Line 3201: MvOPENVIEW: mysql_stmt_prepare: Table 'thebuddha_mm5.s01_PowerSearchProducts' doesn't exist

                Don't know if that helps, or just makes things worse.
                Mark Romero
                ~~~~~~~~

                Comment


                  #9
                  Re: Power Search Error When Rebuilding Search File

                  Did you unassign power search from the utilities menu? If you did that, you have a major corruption of databases, ie some there and some not. It also sounds like you have an old version that does not have the ability to specify just the custom fields I told you to enter in the configuration screen. You should see this prompt "Limit to custom fields:" If you don't see that, you will not be able to rebuild the mirror until you fix those 3 custom fields, one of which will break your theme.

                  On the screen where you actually rebuild the mirror you should only see
                  (text input) records at a time
                  (checkbox) Turbo rebuild
                  Next button
                  Bill Weiland - Emporium Plus http://www.emporiumplus.com/store.mvc
                  Online Documentation http://www.emporiumplus.com/tk3/v3/doc.htm
                  Question http://www.emporiumplus.com/mivamodu...vc?Screen=SPTS
                  Facebook http://www.facebook.com/EmporiumPlus
                  Twitter http://twitter.com/emporiumplus

                  Comment


                    #10
                    Re: Power Search Error When Rebuilding Search File

                    Did you unassign power search from the utilities menu?

                    No, actually I deactivated it from the Modules area.

                    Home > Modules > Edit Module: Power Search > Information

                    You should see this prompt "Limit to custom fields:"
                    I don't see that anywhere.

                    If you don't see that, you will not be able to rebuild the mirror until you fix those 3 custom fields, one of which will break your theme.
                    When you say "fix those 3 custom fields," can I JUST go into the custom fields area and change the CODES for those three fields without breaking my store?

                    My concern is the "product-flag" code is probably used natively by the suivant theme, and hence changing the code from product-flag to product_flag will prevent the product flags from showing on the ctgy screen (or wherever else they are used).

                    Would getting an update to the power search module solve this? I am using version 5.0950

                    Thanks in advance.
                    Mark Romero
                    ~~~~~~~~

                    Comment


                      #11
                      Re: Power Search Error When Rebuilding Search File

                      As I said, changing product-flag would break your theme. So your only solution is to change them for a few minutes. Update power search with a newer version. Change the product-flag back. Then enter a couple field codes in the input I referenced previously. Try to rebuild the mirror. There is likely so much corruption now that you need to completely uninstall the module and either not use it or have someone from miva support fix the corruption and put the current version on there.
                      Bill Weiland - Emporium Plus http://www.emporiumplus.com/store.mvc
                      Online Documentation http://www.emporiumplus.com/tk3/v3/doc.htm
                      Question http://www.emporiumplus.com/mivamodu...vc?Screen=SPTS
                      Facebook http://www.facebook.com/EmporiumPlus
                      Twitter http://twitter.com/emporiumplus

                      Comment


                        #12
                        Re: Power Search Error When Rebuilding Search File

                        I was having the same issue. However, I didn't want to search any of the custom fields. I input:

                        Limit to custom fields: code, sku, name, image, descrip

                        Now it rebuilds. Am I safe to proceed with installing Power Search?
                        Thank you,
                        John

                        Comment


                          #13
                          Re: Power Search Error When Rebuilding Search File

                          If you are not indexing any of the custom fields with dashes, then the mirror should rebuild ok.
                          Brennan Heyde
                          VP Product
                          Miva, Inc.
                          [email protected]
                          https://www.miva.com

                          Comment


                            #14
                            Re: Power Search Error When Rebuilding Search File

                            If you leave that input blank, it will index ALL of the custom fields. If any of those break the rules (hyphen, longer than 10 characters, reserved word) the rebuild will fail. Hence, put at least one of the custom fields in the input and it will rebuild fine as long as that custom field does not violate the rules. Do not put the base fields in the custom field input.
                            Bill Weiland - Emporium Plus http://www.emporiumplus.com/store.mvc
                            Online Documentation http://www.emporiumplus.com/tk3/v3/doc.htm
                            Question http://www.emporiumplus.com/mivamodu...vc?Screen=SPTS
                            Facebook http://www.facebook.com/EmporiumPlus
                            Twitter http://twitter.com/emporiumplus

                            Comment

                            Working...
                            X