Which fatal error are we talking about here? The one related to a missing table should not be caused by an update or any other change in the software, as that's between the module and the table name it created itself (or thought it created). Now, the other error about syntax is typically due to a bug in the PowerSearch module, and one of the many reasons its use should be eliminated. It does not properly quote many variables it uses in queries, and custom field names are often the source of this problem because they're created with characters or words that are reserved words in the underlying database. If that has occurred, the only solution is to remove or rename the custom field which created the issue.
Announcement
Collapse
No announcement yet.
PowerSearch Error
Collapse
X
-
Originally posted by ILoveHostasaurus View PostWhich fatal error are we talking about here? The one related to a missing table should not be caused by an update or any other change in the software, as that's between the module and the table name it created itself (or thought it created). Now, the other error about syntax is typically due to a bug in the PowerSearch module, and one of the many reasons its use should be eliminated. It does not properly quote many variables it uses in queries, and custom field names are often the source of this problem because they're created with characters or words that are reserved words in the underlying database. If that has occurred, the only solution is to remove or rename the custom field which created the issue.
tqMULu.png
This error looks to be the same error that Pysdde got so I checked the custom fields and didn't see any that matched his issue. Now I did notice that the store has a custom field color and a custom field colors. Could that cause an issue?Leslie Kirk
Miva Certified Developer
Miva Merchant Specialist since 1997
Previously of Webs Your Way (aka Leslie Nord leslienord)
Email me: [email protected]
www.lesliekirk.com
Follow me: Twitter | Facebook | FourSquare | Pinterest | Flickr
Comment
-
Hmmmm...how do I find out what the reserved words are?Leslie Kirk
Miva Certified Developer
Miva Merchant Specialist since 1997
Previously of Webs Your Way (aka Leslie Nord leslienord)
Email me: [email protected]
www.lesliekirk.com
Follow me: Twitter | Facebook | FourSquare | Pinterest | Flickr
Comment
-
No does not appear so; these are the field names you'd need to avoid https://dev.mysql.com/doc/mysqld-ver...words-5-7.html
A table not existing seems very odd unless the module's code drops and recreates the table when it does the 'rebuild', but I'd expect that to cause noticeable fatal errors on every store that has a long rebuild cycle, so this appears to be some other issue with the module where it dropped the table and didn't recreate it for some reason. Perhaps there's another field name that prevented its recreation. SQL logging could be temporarily enabled to try to determine if that is the case.
Comment
-
lesliekirk can you just remove Power Search? You're asking for trouble and it's not supported.
Comment
-
Originally posted by Rick Wilson View Postlesliekirk can you just remove Power Search? You're asking for trouble and it's not supported.Leslie Kirk
Miva Certified Developer
Miva Merchant Specialist since 1997
Previously of Webs Your Way (aka Leslie Nord leslienord)
Email me: [email protected]
www.lesliekirk.com
Follow me: Twitter | Facebook | FourSquare | Pinterest | Flickr
Comment
-
Originally posted by ILoveHostasaurus View PostNo does not appear so; these are the field names you'd need to avoid https://dev.mysql.com/doc/mysqld-ver...words-5-7.html
A table not existing seems very odd unless the module's code drops and recreates the table when it does the 'rebuild', but I'd expect that to cause noticeable fatal errors on every store that has a long rebuild cycle, so this appears to be some other issue with the module where it dropped the table and didn't recreate it for some reason. Perhaps there's another field name that prevented its recreation. SQL logging could be temporarily enabled to try to determine if that is the case.
Runtime error in mm5/5.00/modules/util/powrsrch.mvc @ [00000029:00000040]: powrsrch.mv: Line 5081: MvQUERY: mysql_stmt_prepare: Table 'delcors_devmiva5.s02_PowerSearchProducts' doesn't exist Runtime error in mm5/5.00/modules/util/powrsrch.mvc @ [00000029:00000470]: powrsrch.mv: Line 5136: MvQUERY: mysql_stmt_prepare: Table 'delcors_devmiva5.s02_PowerSearchProducts' doesn't existLeslie Kirk
Miva Certified Developer
Miva Merchant Specialist since 1997
Previously of Webs Your Way (aka Leslie Nord leslienord)
Email me: [email protected]
www.lesliekirk.com
Follow me: Twitter | Facebook | FourSquare | Pinterest | Flickr
Comment
-
Originally posted by ILoveHostasaurus View Post
A table not existing seems very odd unless the module's code drops and recreates the table when it does the 'rebuild', but I'd expect that to cause noticeable fatal errors on every store that has a long rebuild cycle, so this appears to be some other issue with the module where it dropped the table and didn't recreate it for some reason. Perhaps there's another field name that prevented its recreation. SQL logging could be temporarily enabled to try to determine if that is the case.
Leslie Kirk
Miva Certified Developer
Miva Merchant Specialist since 1997
Previously of Webs Your Way (aka Leslie Nord leslienord)
Email me: [email protected]
www.lesliekirk.com
Follow me: Twitter | Facebook | FourSquare | Pinterest | Flickr
Comment
-
The failure is due to a bug in the PowerSearch module. It looks at a store's custom field name definitions, and then tries to store them in a variable with a length of ten characters. This causes every custom field whose code is longer than ten characters to be truncated at ten characters. It doesn't bother to see if this has occurred, or to see if it has any duplicates in its list of field names, it just blindly constructs a SQL query to create a new power search products table with every field name it has found, including as many duplicated fields as it constructed erroneously. The result is a query with duplicate names that fails. The module also drops the power search product table before beginning the process, so it can never recover, and leaves the search broken.
In this store's case, the cause of the duplicate fields is the use of ShipStation, which adds the custom product fields:
shipstation_asin
shipstation_isbn
shipstation_location
shipstation_upc
Those are turned into "shipstatio" by the PowerSearch module when it attempts to recreate its product table. If this store does not use those fields, you could potentially delete them, but I do not know if ShipStation polls those fields and will itself have issues if they go missing. If they're not in use, you could note them down, remove them, rebuild power search and see if it works. If shipstation then fails, you'd have to put them back and know PowerSearch can no longer be rebuilt.
Only other quick option would be to restore the entire store from backup, but changes to data since the time of the update would be lost.
I'm going to recommend internally that PowerSearch be put on the upgrade prevention list, as along with all its other failure scenarios, this one is particularly bad given it breaks a store's search. We're at the point this module is no longer safe to be using; it's based on code dating back to version 5.5 12+ years ago.
Comment
-
Originally posted by ILoveHostasaurus View PostThe failure is due to a bug in the PowerSearch module. It looks at a store's custom field name definitions, and then tries to store them in a variable with a length of ten characters. This causes every custom field whose code is longer than ten characters to be truncated at ten characters. It doesn't bother to see if this has occurred, or to see if it has any duplicates in its list of field names, it just blindly constructs a SQL query to create a new power search products table with every field name it has found, including as many duplicated fields as it constructed erroneously. The result is a query with duplicate names that fails. The module also drops the power search product table before beginning the process, so it can never recover, and leaves the search broken.
In this store's case, the cause of the duplicate fields is the use of ShipStation, which adds the custom product fields:
shipstation_asin
shipstation_isbn
shipstation_location
shipstation_upc
Those are turned into "shipstatio" by the PowerSearch module when it attempts to recreate its product table. If this store does not use those fields, you could potentially delete them, but I do not know if ShipStation polls those fields and will itself have issues if they go missing. If they're not in use, you could note them down, remove them, rebuild power search, and see if it works. If shipstation then fails, you'd have to put them back and know PowerSearch can no longer be rebuilt.
Only other quick option would be to restore the entire store from backup, but changes to data since the time of the update would be lost.
I'm going to recommend internally that PowerSearch be put on the upgrade prevention list, as along with all its other failure scenarios, this one is particularly bad given it breaks a store's search. We're at the point this module is no longer safe to be using; it's based on code dating back to version 5.5 12+ years ago.many store owners don't actually know PowerSearch is installed in their store
Perhaps we can set up specific forums (or/and blog posts, knowledge bases, newsletters) to help guide others in how best to replace each of these modules. On a related note, I know there have been other store owners trying to find a suitable replacement for the Miscellaneous Fee module. Also being able to have a Custom Field collect a fee. I suspect a long laundry list could be of needs could be written along with a ton of ideas on how to make this happen in a friendly easy to understand way.
Leslie Kirk
Miva Certified Developer
Miva Merchant Specialist since 1997
Previously of Webs Your Way (aka Leslie Nord leslienord)
Email me: [email protected]
www.lesliekirk.com
Follow me: Twitter | Facebook | FourSquare | Pinterest | Flickr
Comment
-
Originally posted by delcorsets View PostWilliam Davis I have a lot of custom search functionality on one of my sites that was originally created using PowerSearch. Really cool Tag search and Designer search from my product pages and some customized "smart" searches from landing pages / NavBar for things that require multiple search criteria like "masculine jewelry from designer xxx" or "mens clothing with skulls under $100". It's possible that some of this could now be rewritten using native Miva search, but the original project was costly and unfortunately I don't currently have the budget to R&D / re-write the customizations (if it's even possible.)
If I could figure out to make these changes myself I would try it.. my available time to experiment with things like this however is very tight. I would like to be on Miva native functionality wherever possible just to get rid of some of the older 3rd party modules I'm still using - but in many cases Miva's solutions end up missing one or two critical features that I use from the modules that I currently have in use.
I am actually using some of Miva' s search features in tandem with the PowerSearch custom features, so I do have faceted search in use as well.
Is your heavily customized Power Search still working for you? The site I've been working on has had its "break" again. I don't know if someone tried to do the "Rebuild Power Search File" (which I was told would break it if ever run again) or if running the "Perform Module Cleanup Tasks" for another issue may have broken it again. Much of the custom work for this particular site was done by Miva's Professional Services and like you, it's not in their budget to have them rebuild it. Have you reached out to any other developers for quotes? I was going to try and get some for the store owner (some of the custom work is very javascript heavy and my javascript foo is not strong).Leslie Kirk
Miva Certified Developer
Miva Merchant Specialist since 1997
Previously of Webs Your Way (aka Leslie Nord leslienord)
Email me: [email protected]
www.lesliekirk.com
Follow me: Twitter | Facebook | FourSquare | Pinterest | Flickr
Comment
-
Leslie, that module's author died seven years ago, it has known severe performance issues, it has known security concerns, it became unsafe to use in any store seven years ago and only becomes more unsafe as the years go on and Miva Merchant changes. It's highly likely that module will be blacklisted at some point as it will surely cease working (well, it seems to have ceased working in at least some stores) or will ultimately have a complete compatibility failure.
Comment
-
Originally posted by ILoveHostasaurus View PostLeslie, that module's author died seven years ago, it has known severe performance issues, it has known security concerns, it became unsafe to use in any store seven years ago and only becomes more unsafe as the years go on and Miva Merchant changes. It's highly likely that module will be blacklisted at some point as it will surely cease working (well, it seems to have ceased working in at least some stores) or will ultimately have a complete compatibility failure.
Leslie Kirk
Miva Certified Developer
Miva Merchant Specialist since 1997
Previously of Webs Your Way (aka Leslie Nord leslienord)
Email me: [email protected]
www.lesliekirk.com
Follow me: Twitter | Facebook | FourSquare | Pinterest | Flickr
Comment
Comment