Opencart Database tables missing - opencart

I keep getting this error when trying to add a product in OpenCart 1.5.6 - it only started happening recently and I'm trying to trace back anything which might have been installed or uninstalled.
This is the error I seem to be getting. I was wondering if someone might know what the table is related to? I can then uninstall and reinstall.
Fatal error: Uncaught exception 'ErrorException' with message 'Error: Table 'DBName.shop_profile' doesn't exist<br />Error No: 1146<br />SELECT `p`.`profile_id`, `p`.`sort_order`, `pd`.`name` FROM `shop_profile` AS `p` JOIN `shop_profile_description` AS `pd` ON `pd`.`profile_id` = `p`.`profile_id` AND `pd`.`language_id` = 1 ORDER BY p.sort_order ASC ' in /system/database/mysqli.php:41 Stack trace: #0 /system/library/db.php(20): DBMySQLi->query('SELECT `p`.`pro...') #1 /admin/model/catalog/profile.php(34): DB->query('SELECT `p`.`pro...') #2 /admin/controller/catalog/product.php(868): ModelCatalogProfile->getProfiles() #3 /admin/controller/catalog/product.php(64): ControllerCatalogProduct->getForm() #4 [internal function]: ControllerCatalogProduct->insert() #5 /system/engine/front.php(42): in /system/database/mysqli.php on line 41

Related

Logstash grok pattern to catch the first line with the string Exception

This is the an example log:
2022-01-07 11:05:01,185 [http-nio-8080-exec-526] WARN de.web.Main| = - Error while execute Request
javax.servlet.ServletException: com.cg.blart.web.HttpInvocationException: Invalid tenant session
at com.cg.blume.web.DispatchingServlet.doGet(DispatchingServlet.java:169)
at de.jinx.lee.web.AutoDBUpgradeDispatchingServlet.lambda$doGet$0(AutoDBUpgradeDispatchingServlet.java:200)
at de.jinx.lee.web.AutoDBUpgradeDispatchingServlet.addMDCKey(AutoDBUpgradeDispatchingServlet.java:297)
Caused by: com.cg.blume.web.HttpInvocationException: Invalid tenant session
at com.cg.blume.web.procedure.HttpSessionManager.get(HttpSessionManager.java:190)
at de.jinx.lee.web.session.leeHttpSessionManager.get(leeHttpSessionManager.java:76)
... 41 more
This ist the pattern so far:
^.*?Exception: +%{DATA:exception}$
The output i get is close but no cigar: "com.cg.blart.web.HttpInvocationException: Invalid tenant session". For the live of me i dont get it to match the whole line. Can you show me the way? The desired output is:
javax.servlet.ServletException: com.cg.blart.web.HttpInvocationException: Invalid tenant session
Here is a link for a test tool: https://grokdebug.herokuapp.com/
Solution was this pattern:
(?<DATA:mps_exception>.*?(Exception:).*)
It is explained here: https://www.elastic.co/guide/en/logstash/current/plugins-filters-grok.html#_custom_patterns

WSO2AM with WSO2DAS - null apiPublisher for API_DESTINATION_SUMMARY

Connecting wso2am-2.0.0 and wso2am-analytics-2.0.0 on PGSQL (9.5) database (having common WSO2AM_STATS_DB database), we receive a following exception:
TID: [-1] [] ERROR {org.wso2.carbon.ntask.core.impl.TaskQuartzJobAdapter} - Error in executing task: Error while saving dat
a to the table API_DESTINATION_SUMMARY : Job aborted due to stage failure: Task 0 in stage 54296.0 failed 1 times, most recent failure: Lost task 0.0
in stage 54296.0 (TID 50425, localhost): java.sql.BatchUpdateException: Batch entry 0 INSERT INTO API_DESTINATION_SUMMARY (api, version, apiPublisher,
context, destination, total_request_count, hostName, year, month, day, time) VALUES ('test01', 'v1.0.0', NULL, '/test/v1.0.0', 'http://demo6009762.mo
ckable.io', 1, 'wso2apimgr3', 2017, 1, 26, '2017-01-26 15:59') ON CONFLICT (api,version,apiPublisher,context,destination,hostName,year,month,day) DO U
PDATE SET total_request_count=EXCLUDED.total_request_count, time=EXCLUDED.time was aborted: ERROR: null value in column "apipublisher" violates not-nu
ll constraint
full exception is here.
According to the logs the direct cause is that the apipublisher field is null what should not happen.
So now I have a few questions:
How do I prevent that? How do I configure the apipublisher value?. And How do I get rid of the invalid data
Thank you for any hint
There is a reported issue for this. You can apply the fix mentioned in the jira ticket.

AWS send bulk email error with message - "Domain contains dot-dot"

I am trying to send a large chunk emails and got error with message "Domain contains dot-dot".
Does anyone know why I am getting this error?
#0 /var/www/vhosts/domainame.com/vendor/aws/aws-sdk- php/src/Aws/Common/Exception/NamespaceExceptionFactory.php(76): Aws\Common\Exception\NamespaceExceptionFactory->createException('Aws\\Ses\\Excepti...', Object(Guzzle\Http\Message\EntityEnclosingRequest), Object(Guzzle\Http\Message\Response), Array)
#1 /var/www/vhosts/domain.com/vendor/aws/aws-sdk-php/src/Aws/Common/Exception/ExceptionListener.php(55): Aws\Common\Exception\NamespaceExceptionFactory->fromResponse(Object(Guzzle\Http\Message\EntityEnclosingRequest), Object(Guzzle\Http\Message\Response))
#2 [internal function]: Aws\Common\Exception\ExceptionListener->onRequestError(Object(Guzzle\Common\Event), 'request.error', Object(Symfony\Compone in /var/www/vhosts/domainname.com/vendor/guzzle/guzzle/src/Guzzle/Service/Exception/CommandTransferException.php on line 25
PHP Fatal error: Uncaught exception 'Guzzle\Service\Exception\CommandTransferException' with message 'Errors during multi transfer
(Aws\Ses\Exception\SesException) /var/www/vhosts/domainname.com/vendor/aws/aws-sdk-php/src/Aws/Common/Exception/NamespaceExceptionFactory.php line 91
Domain contains dot-dot
Domain name of some mail address contains more then one dot sign (.) literally.
eg. Alan#stackoverflow..com
Reference:
1.
https://java.net/projects/javamail/sources/mercurial/diff/mail/src/oldtest/java/javax/mail/internet/addrlist?rev1=61&rev2=62
https://java.net/projects/javamail/sources/mercurial/content/mail/src/main/java/javax/mail/internet/InternetAddress.java?rev=557

Sitecore 8: The automation state for contact 46905fd6-25ee-4b91-a968-80cc29943e2f and plan 00000000-0000-0000-0000-000000000000 has not been found

I'm getting the following error message on Sitecore logs in one of our production environment.
MessageTaskRunner worker thread 3 06:40:35 ERROR EmailCampaign: Message sending error: Sitecore.Modules.EmailCampaign.Exceptions.EmailCampaignException: The automation state for contact 46905fd6-25ee-4b91-a968-80cc29943e2f and plan 00000000-0000-0000-0000-000000000000 has not been found.
at Sitecore.Modules.EmailCampaign.Core.Analytics.AutomationStatesManager.EnrollOrUpdateContact(Guid contactId, Guid planId, String stateName, EcmCustomValues customValues, String[] validStates)
at Sitecore.Modules.EmailCampaign.Core.Dispatch.DispatchManager.EnrollOrUpdateContact(Guid contactId, DispatchQueueItem dispatchQueueItem, Guid planId, String stateName, EcmCustomValues customValues)
at Sitecore.Modules.EmailCampaign.Core.Dispatch.DispatchTask.OnSendToNextRecipient()
ManagedPoolThread #2 06:40:35 INFO EmailCampaign: Dispatch Message (Unsubscribe Notification): Finished
ManagedPoolThread #2 06:40:35 INFO Job ended: Sending message (C354709A5AEC45AD939190E246A3CEA4) (units processed: )
ManagedPoolThread #16 06:40:35 ERROR Could not update index entry. Action: 'Saved', Item: '{7356F179-B8D2-4091-AC17-D65F02E4416D}'
Exception: System.IO.IOException
Message: read past EOF
Source: Lucene.Net
at Lucene.Net.Store.BufferedIndexInput.Refill()
at Lucene.Net.Store.BufferedIndexInput.ReadByte()
at Lucene.Net.Store.ChecksumIndexInput.ReadByte()
at Lucene.Net.Store.IndexInput.ReadInt()
at Lucene.Net.Index.SegmentInfos.Read(Directory directory, String segmentFileName)
at Lucene.Net.Index.IndexFileDeleter..ctor(Directory directory, IndexDeletionPolicy policy, SegmentInfos segmentInfos, StreamWriter infoStream, DocumentsWriter docWriter, HashSet`1 synced)
at Lucene.Net.Index.DirectoryReader.DoCommit(IDictionary`2 commitUserData)
at Lucene.Net.Index.IndexReader.Commit(IDictionary`2 commitUserData)
at Lucene.Net.Index.IndexReader.Commit()
at Lucene.Net.Index.IndexReader.DecRef()
at Lucene.Net.Index.IndexReader.Dispose(Boolean disposing)
at Sitecore.Search.Crawlers.DatabaseCrawler.DeleteItem(Item item)
at Sitecore.Search.Crawlers.DatabaseCrawler.UpdateItem(Item item)
at System.EventHandler.Invoke(Object sender, EventArgs e)
at Sitecore.Data.Managers.IndexingProvider.UpdateIndexPhaseOne(HistoryEntry entry, Database database)
I have rebuild the Sitecore analytics database also.
But still I'm getting this error.
I tried submitting forms on our site, and it is working fine. I'm getting the subscription mails and the subscription notifications.
Thanks.

DQL searching MD5 string?

How do I search my database using DQL for a MD5 string.
I'm using doctrine and want to write the following query in DQL.
SELECT * FROM club_members WHERE md5( CONCAT('secret_key',id)) = '8e801b9cd9b38c142472d5fc5238f538'
I tried
$dql = "SELECT c FROM models\Club_members c WHERE md5( CONCAT('".$secret_key."',c.id)) = '8e801b9cd9b38c142472d5fc5238f538'";
but get a fatal error
Fatal error: Uncaught exception 'Doctrine\ORM\Query\QueryException' with message '[Syntax Error] line 0, col 52: Error: Expected known function, got 'md5'' in //application/libraries/Doctrine/ORM/Query/QueryException.php:42 Stack trace: #0 //application/libraries/Doctrine/ORM/Query/Parser.php(396): Doctrine\ORM\Query\QueryException::syntaxError('line 0, col 52:...') #1 //application/libraries/Doctrine/ORM/Query/Parser.php(2778): Doctrine\ORM\Query\Parser->syntaxError('known function', Array) #2 //application/libraries/Doctrine/ORM/Query/Parser.php(2311): Doctrine\ORM\Query\Parser->FunctionDeclaration() #3 //application/libraries/Doctrine/ORM/Query/Parser.php(2279): Doctrine\ORM\Query\Parser->ArithmeticPrimary() #4 //application/libraries/Doctrine/ORM/Query/Parser.php(2247): Doctrine\ORM\Query in //application/libraries/Doctrine/ORM/Query/QueryException.php on line 42
Any suggestions?
MD5 is not included into standard Doctrine, you need to install MD5 extension: https://github.com/beberlei/DoctrineExtensions/blob/master/lib/DoctrineExtensions/Query/Mysql/Md5.php