Full Text Search not working

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • olof
    Senior Member
    • Jul 2018
    • 184

    #16
    Current state is when description is included and full text search is enabled we get: Error 500: Error while rebuilding database. See log file for details.

    Log:

    Code:
    [2018-08-01 16:36:39] Espo.ALERT: Rebuild database fault: exception 'PDOException' with message 'SQLSTATE[HY000]: General error: 1283 Column 'description' cannot be part of FULLTEXT index' in /usr/share/nginx/html/vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.php:699 Stack trace: #0 /usr/share/nginx/html/vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(699): PDO->query('CREATE FULLTEXT...') #1 /usr/share/nginx/html/application/Espo/Core/Utils/Database/Schema/Schema.php(196): Doctrine\DBAL\Connection->executeQuery('CREATE FULLTEXT...') #2 /usr/share/nginx/html/application/Espo/Core/DataManager.php(95): Espo\Core\Utils\Database\Schema\Schema->rebuild(NULL) #3 /usr/share/nginx/html/application/Espo/Core/DataManager.php(62): Espo\Core\DataManager->rebuildDatabase(NULL) #4 /usr/share/nginx/html/application/Espo/Controllers/Admin.php(51): Espo\Core\DataManager->rebuild() #5 /usr/share/nginx/html/application/Espo/Core/ControllerManager.php(118): Espo\Controllers\Admin->postActionRebuild(Array, '', Object(Slim\Http\Request)) #6 /usr/share/nginx/html/application/Espo/Core/Application.php(227): Espo\Core\ControllerManager->process('Admin', 'rebuild', Array, '', Object(Slim\Http\Request)) #7 [internal function]: Espo\Core\Application->Espo\Core\{closure}() #8 /usr/share/nginx/html/vendor/slim/slim/Slim/Slim.php(1210): call_user_func_array(Object(Closure), Array) #9 /usr/share/nginx/html/vendor/slim/slim/Slim/Slim.php(1356): Slim\Slim->applyHook('slim.before.dis...') #10 /usr/share/nginx/html/vendor/slim/slim/Slim/Middleware/Flash.php(85): Slim\Slim->call() #11 /usr/share/nginx/html/vendor/slim/slim/Slim/Middleware/MethodOverride.php(92): Slim\Middleware\Flash->call() #12 /usr/share/nginx/html/application/Espo/Core/Utils/Api/Auth.php(121): Slim\Middleware\MethodOverride->call() #13 /usr/share/nginx/html/application/Espo/Core/Utils/Api/Slim.php(125): Espo\Core\Utils\Api\Auth->call() #14 /usr/share/nginx/html/application/Espo/Core/Application.php(88): Espo\Core\Utils\Api\Slim->run() #15 /usr/share/nginx/html/api/v1/index.php(33): Espo\Core\Application->run() #16 {main}  Next exception 'Doctrine\DBAL\DBALException' with message 'An exception occurred while executing 'CREATE FULLTEXT INDEX IDX_SYSTEM_FULL_TEXT_SEARCH ON `account` (name, description)':  SQLSTATE[HY000]: General error: 1283 Column 'description' cannot be part of FULLTEXT index' in /usr/share/nginx/html/vendor/doctrine/dbal/lib/Doctrine/DBAL/DBALException.php:91 Stack trace: #0 /usr/share/nginx/html/vendor/doctrine/dbal/lib/Doctrine/DBAL/Connection.php(702): Doctrine\DBAL\DBALException::driverExceptionDuringQuery(Object(PDOException), 'CREATE FULLTEXT...', Array) #1 /usr/share/nginx/html/application/Espo/Core/Utils/Database/Schema/Schema.php(196): Doctrine\DBAL\Connection->executeQuery('CREATE FULLTEXT...') #2 /usr/share/nginx/html/application/Espo/Core/DataManager.php(95): Espo\Core\Utils\Database\Schema\Schema->rebuild(NULL) #3 /usr/share/nginx/html/application/Espo/Core/DataManager.php(62): Espo\Core\DataManager->rebuildDatabase(NULL) #4 /usr/share/nginx/html/application/Espo/Controllers/Admin.php(51): Espo\Core\DataManager->rebuild() #5 /usr/share/nginx/html/application/Espo/Core/ControllerManager.php(118): Espo\Controllers\Admin->postActionRebuild(Array, '', Object(Slim\Http\Request)) #6 /usr/share/nginx/html/application/Espo/Core/Application.php(227): Espo\Core\ControllerManager->process('Admin', 'rebuild', Array, '', Object(Slim\Http\Request)) #7 [internal function]: Espo\Core\Application->Espo\Core\{closure}() #8 /usr/share/nginx/html/vendor/slim/slim/Slim/Slim.php(1210): call_user_func_array(Object(Closure), Array) #9 /usr/share/nginx/html/vendor/slim/slim/Slim/Slim.php(1356): Slim\Slim->applyHook('slim.before.dis...') #10 /usr/share/nginx/html/vendor/slim/slim/Slim/Middleware/Flash.php(85): Slim\Slim->call() #11 /usr/share/nginx/html/vendor/slim/slim/Slim/Middleware/MethodOverride.php(92): Slim\Middleware\Flash->call() #12 /usr/share/nginx/html/application/Espo/Core/Utils/Api/Auth.php(121): Slim\Middleware\MethodOverride->call() #13 /usr/share/nginx/html/application/Espo/Core/Utils/Api/Slim.php(125): Espo\Core\Utils\Api\Auth->call() #14 /usr/share/nginx/html/application/Espo/Core/Application.php(88): Espo\Core\Utils\Api\Slim->run() #15 /usr/share/nginx/html/api/v1/index.php(33): Espo\Core\Application->run() #16 {main} [] []
    [2018-08-01 16:36:39] Espo.ERROR: API [POST]:/Admin/rebuild, Params:Array ( ) , InputData:  - Error while rebuilding database. See log file for details. [] []
    [2018-08-01 16:36:39] Espo.ERROR: Display Error: Error while rebuilding database. See log file for details., Code: 500 URL: /api/v1/Admin/rebuild [] []
    Database:

    Click image for larger version

Name:	phpmyadmin.JPG
Views:	333
Size:	61.1 KB
ID:	41020

    Comment

    • olof
      Senior Member
      • Jul 2018
      • 184

      #17
      We did a fresh install on MySQL and now this is working...

      Comment

      • olof
        Senior Member
        • Jul 2018
        • 184

        #18
        We now have this working - we did a reinstall on MySQL... seems like there are issues with Maria..

        I have a new issue though.. now its too permissive and I think its a bug.

        Seems that the "Global Search" is performing an OR search. For example if you search for Joe Bloggs it returns any contacts with Joe in their name and any contacts with Bloggs in their name.

        e.g. it returns Claire Bloggs...

        So in this case it returs 200 results. Now is I make the search Joe Bloggs Frank it returns 300 results..

        "Use 'contains' operator when filtering varchar fields" is unticked.

        Version is 3.5.6

        The online demo is not doing this and is also running 3.5.6.

        Kind regards

        Olof

        Comment

        • yuri
          Member
          • Mar 2014
          • 8495

          #19
          Hi,

          It's how full-text search works. Results are sorted by relevation.

          Like results in google search.
          If you find EspoCRM good, we would greatly appreciate if you could give the project a star on GitHub. We believe our work truly deserves more recognition. Thanks.

          Comment

          • olof
            Senior Member
            • Jul 2018
            • 184

            #20
            Something isn't working then..

            There is contact called Joe Bray. Search for Joe Bray and 15 contacts come up but Joe Bray in paginated on page 2.

            Comment

            • yuri
              Member
              • Mar 2014
              • 8495

              #21
              Not sure what it could be. I can't reproduce. Full-text search is implemented in mysql and can differ between versions. Make sure you have InnoDB engine for your table.
              If you find EspoCRM good, we would greatly appreciate if you could give the project a star on GitHub. We believe our work truly deserves more recognition. Thanks.

              Comment

              • brscpa.com
                Junior Member
                • Jun 2019
                • 10

                #22
                Full text search gives bad server response on version 5.6.3
                Unable to upgrade as Rebuild fails and gives 404 response.

                Comment

                • Maximus
                  Senior Member
                  • Nov 2018
                  • 2731

                  #23
                  Hello,
                  please check the error log file in data/logs.

                  Comment

                  • yuri
                    Member
                    • Mar 2014
                    • 8495

                    #24
                    I recommend to disable it.
                    If you find EspoCRM good, we would greatly appreciate if you could give the project a star on GitHub. We believe our work truly deserves more recognition. Thanks.

                    Comment

                    • brscpa.com
                      Junior Member
                      • Jun 2019
                      • 10

                      #25
                      espo-2019-09-26.log

                      [2019-09-26 15:30:55] Espo.ERROR: Uncaught Exception TypeError: "Argument 2 passed to Espo\Core\Utils\Api\Output:rocessError() must be of the type int, string given, called in C:\xampp\apps\espocrm\htdocs\application\Espo\Core \Application.php on line 299" at C:\xampp\apps\espocrm\htdocs\application\Espo\Core \Utils\Api\Output.php line 74 {"exception":"[object] (TypeError(code: 0): Argument 2 passed to Espo\\Core\\Utils\\Api\\Output:rocessError() must be of the type int, string given, called in C:\\xampp\\apps\\espocrm\\htdocs\\application\\Esp o\\Core\\Application.php on line 299 at C:\\xampp\\apps\\espocrm\\htdocs\\application\\Esp o\\Core\\Utils\\Api\\Output.php:74)"} []
                      [2019-09-26 15:30:58] Espo.ERROR: Uncaught Exception TypeError: "Argument 2 passed to Espo\Core\Utils\Api\Output:rocessError() must be of the type int, string given, called in C:\xampp\apps\espocrm\htdocs\application\Espo\Core \Application.php on line 299" at C:\xampp\apps\espocrm\htdocs\application\Espo\Core \Utils\Api\Output.php line 74 {"exception":"[object] (TypeError(code: 0): Argument 2 passed to Espo\\Core\\Utils\\Api\\Output:rocessError() must be of the type int, string given, called in C:\\xampp\\apps\\espocrm\\htdocs\\application\\Esp o\\Core\\Application.php on line 299 at C:\\xampp\\apps\\espocrm\\htdocs\\application\\Esp o\\Core\\Utils\\Api\\Output.php:74)"} []
                      [2019-09-26 15:31:02] Espo.ERROR: Uncaught Exception TypeError: "Argument 2 passed to Espo\Core\Utils\Api\Output:rocessError() must be of the type int, string given, called in C:\xampp\apps\espocrm\htdocs\application\Espo\Core \Application.php on line 299" at C:\xampp\apps\espocrm\htdocs\application\Espo\Core \Utils\Api\Output.php line 74 {"exception":"[object] (TypeError(code: 0): Argument 2 passed to Espo\\Core\\Utils\\Api\\Output:rocessError() must be of the type int, string given, called in C:\\xampp\\apps\\espocrm\\htdocs\\application\\Esp o\\Core\\Application.php on line 299 at C:\\xampp\\apps\\espocrm\\htdocs\\application\\Esp o\\Core\\Utils\\Api\\Output.php:74)"} []
                      [2019-09-26 15:31:05] Espo.ERROR: Uncaught Exception TypeError: "Argument 2 passed to Espo\Core\Utils\Api\Output:rocessError() must be of the type int, string given, called in C:\xampp\apps\espocrm\htdocs\application\Espo\Core \Application.php on line 299" at C:\xampp\apps\espocrm\htdocs\application\Espo\Core \Utils\Api\Output.php line 74 {"exception":"[object] (TypeError(code: 0): Argument 2 passed to Espo\\Core\\Utils\\Api\\Output:rocessError() must be of the type int, string given, called in C:\\xampp\\apps\\espocrm\\htdocs\\application\\Esp o\\Core\\Application.php on line 299 at C:\\xampp\\apps\\espocrm\\htdocs\\application\\Esp o\\Core\\Utils\\Api\\Output.php:74)"} []

                      Comment

                      • brscpa.com
                        Junior Member
                        • Jun 2019
                        • 10

                        #26
                        Instead of tracking upgrade problems (where new columns in tables are not created but yet crash the upgrade) does anyone have a procedure for exporting data only, using phpmyadmin, deleting the old install, installing the newest, and then importing the data back in to the tables using phpmyadmin?

                        Comment

                        • Maximus
                          Senior Member
                          • Nov 2018
                          • 2731

                          #27
                          Hi,
                          we do not have such guide for phpMyAdmin but we have the guide how to proced it via terminal:
                          https://www.espocrm.com/documentatio...ackup-database.
                          https://www.espocrm.com/documentatio...-database-dump.

                          Comment

                          Working...