CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Discussion (deprecated) »
  • Alpha and Beta Release Testing »
  • 4.6 Release Testing »
  • CiviCRM_API3_Exception: "DB Error: no such table"
Pages: [1]

Author Topic: CiviCRM_API3_Exception: "DB Error: no such table"  (Read 1650 times)

rocxa

  • I post occasionally
  • **
  • Posts: 40
  • Karma: 4
  • CiviCRM version: 4.5.5
  • CMS version: Drupal 7.34
  • MySQL version: 5.1.71
  • PHP version: 5.3.3
CiviCRM_API3_Exception: "DB Error: no such table"
January 13, 2015, 07:36:11 am
After installing the update from 4.5.5 to 4.6alpha1 and going to mailings -> new mailing

we get this error:
CiviCRM_API3_Exception: "DB Error: no such table"

Suggesting this table isn't created during the update script?
/civicrm/CRM/Mailing/Info.php(80): civicrm_api3("MailingAB", "get", (Array:0))

let me know if you need further details?


Hershel

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4640
  • Karma: 176
    • CiviHosting
  • CiviCRM version: Latest
  • CMS version: Mostly WordPress and Drupal
Re: CiviCRM_API3_Exception: "DB Error: no such table"
January 19, 2015, 05:02:43 am
Can you enable debugging to get a full error message?
CiviHosting and CiviOnline -- The CiviCRM hosting experts, since 2007

See here for the official: What to do if you think you've found a bug.

r4zoli

  • I post occasionally
  • **
  • Posts: 88
  • Karma: 1
  • CiviCRM version: 4.7
  • CMS version: Wordpress
  • MySQL version: 5
  • PHP version: 5
Re: CiviCRM_API3_Exception: "DB Error: no such table"
January 20, 2015, 12:22:38 am
I get same error when my installation test site upgraded under wordpress 4.1 from 4.5 beta9 to 4.6Alpha1. Now upgraded to 4.6Alpha2 and get same error.

The debugging error message:

CiviCRM_API3_Exception: "DB Error: no such table"

#0 /var/www/wp-content/plugins/civicrm/civicrm/CRM/Mailing/Info.php(90): civicrm_api3("MailingAB", "get", (Array:0))
#1 /var/www/wp-content/plugins/civicrm/civicrm/CRM/Core/Page/Angular.php(107): CRM_Mailing_Info->getAngularModules()
#2 /var/www/wp-content/plugins/civicrm/civicrm/CRM/Core/Page/Angular.php(32): CRM_Core_Page_Angular::getAngularModules()
#3 /var/www/wp-content/plugins/civicrm/civicrm/CRM/Core/Page/Angular.php(24): CRM_Core_Page_Angular->registerResources(Object(CRM_Core_Resources))
#4 /var/www/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(307): CRM_Core_Page_Angular->run((Array:3), NULL)
#5 /var/www/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(82): CRM_Core_Invoke::runItem((Array:12))
#6 /var/www/wp-content/plugins/civicrm/civicrm/CRM/Core/Invoke.php(54): CRM_Core_Invoke::_invoke((Array:3))
#7 /var/www/wp-content/plugins/civicrm/civicrm.php(1130): CRM_Core_Invoke::invoke((Array:3))
#8 [internal function](): CiviCRM_For_WordPress->invoke("")
#9 /var/www/wp-includes/plugin.php(496): call_user_func_array((Array:2), (Array:1))
#10 /var/www/wp-admin/admin.php(212): do_action("toplevel_page_CiviCRM")
#11 {main}


ken

  • I live on this forum
  • *****
  • Posts: 916
  • Karma: 53
    • City Bible Forum
  • CiviCRM version: 4.6.3
  • CMS version: Drupal 7.36
  • MySQL version: 5.5.41
  • PHP version: 5.3.10
Re: CiviCRM_API3_Exception: "DB Error: no such table"
January 25, 2015, 02:18:09 pm
I get a similar error with Drupal and 4.6.alpha3.

It appears that the upgrade script doesn't add the 'civicrm_mailing_abtest' table to the database.

The backtrace I have is more complete than earlier respondents saw...

Quote
Jan 26 08:55:27  [info] $backTrace = #0 /civicrm/CRM/Core/Error.php(889): CRM_Core_Error::backtrace("backTrace", TRUE)
#1 [internal function](): CRM_Core_Error::exceptionHandler(Object(DB_Error))
#2 /civicrm/packages/PEAR.php(931): call_user_func((Array:2), Object(DB_Error))
#3 /civicrm/packages/DB.php(976): PEAR_Error->PEAR_Error("DB Error: no such table", -18, 16, (Array:2), "SELECT * \n FROM civicrm_mailing_abtest \n \n \n \n \n \n LIMIT 0, 25 [native...")
#4 /civicrm/packages/PEAR.php(564): DB_Error->DB_Error(-18, 16, (Array:2), "SELECT * \n FROM civicrm_mailing_abtest \n \n \n \n \n \n LIMIT 0, 25 [native...")
#5 /civicrm/packages/DB/common.php(1905): PEAR->raiseError(NULL, -18, NULL, NULL, "SELECT * \n FROM civicrm_mailing_abtest \n \n \n \n \n \n LIMIT 0, 25 [native...", "DB_Error", TRUE)
#6 /civicrm/packages/DB/mysql.php(899): DB_common->raiseError(-18, NULL, NULL, NULL, "1146 ** Table 'cbf_civicrm_46alpha3.civicrm_mailing_abtest' doesn't exist")
#7 /civicrm/packages/DB/mysql.php(328): DB_mysql->mysqlRaiseError()
#8 /civicrm/packages/DB/common.php(1216): DB_mysql->simpleQuery("SELECT * \n FROM civicrm_mailing_abtest \n \n \n \n \n \n LIMIT 0, 25")
#9 /civicrm/packages/DB/DataObject.php(2442): DB_common->query("SELECT * \n FROM civicrm_mailing_abtest \n \n \n \n \n \n LIMIT 0, 25")
#10 /civicrm/packages/DB/DataObject.php(441): DB_DataObject->_query("SELECT * \n FROM civicrm_mailing_abtest \n \n \n \n \n \n LIMIT 0, 25")
#11 /civicrm/api/v3/utils.php(878): DB_DataObject->find()
#12 /civicrm/api/v3/utils.php(1191): _civicrm_api3_dao_to_array(Object(CRM_Mailing_BAO_MailingAB), (Array:1), FALSE, "")
#13 /civicrm/api/v3/MailingAB.php(70): _civicrm_api3_basic_get("CRM_Mailing_BAO_MailingAB", (Array:1))
#14 /civicrm/Civi/API/Provider/MagicFunctionProvider.php(89): civicrm_api3_mailing_a_b_get((Array:1))
#15 /civicrm/Civi/API/Kernel.php(96): Civi\API\Provider\MagicFunctionProvider->invoke((Array:9))
#16 /civicrm/api/api.php(25): Civi\API\Kernel->run("MailingAB", "get", (Array:1), NULL)
#17 /civicrm/api/api.php(43): civicrm_api("MailingAB", "get", (Array:1))
#18 /civicrm/CRM/Mailing/Info.php(93): civicrm_api3("MailingAB", "get", (Array:0))
#19 /civicrm/Civi/Angular/Manager.php(95): CRM_Mailing_Info->getAngularModules()
#20 /civicrm/Civi/Angular/Page/Main.php(58): Civi\Angular\Manager->getModules()
#21 /civicrm/Civi/Angular/Page/Main.php(50): Civi\Angular\Page\Main->registerResources()
#22 /civicrm/CRM/Core/Invoke.php(313): Civi\Angular\Page\Main->run((Array:2), NULL)
#23 /civicrm/CRM/Core/Invoke.php(82): CRM_Core_Invoke::runItem((Array:12))
#24 /civicrm/CRM/Core/Invoke.php(54): CRM_Core_Invoke::_invoke((Array:2))
#25 /civicrm/drupal/civicrm.module(404): CRM_Core_Invoke::invoke((Array:2))
#26 [internal function](): civicrm_invoke("a")
#27 /var/www/citybibleforum/includes/menu.inc(517): call_user_func_array("civicrm_invoke", (Array:1))
#28 /var/www/citybibleforum/index.php(21): menu_execute_active_handler()
#29 {main}

ken

  • I live on this forum
  • *****
  • Posts: 916
  • Karma: 53
    • City Bible Forum
  • CiviCRM version: 4.6.3
  • CMS version: Drupal 7.36
  • MySQL version: 5.5.41
  • PHP version: 5.3.10
Re: CiviCRM_API3_Exception: "DB Error: no such table"
January 25, 2015, 05:08:45 pm
This issue has been fixed in the upgrade script so it should be resolved in alpha4. To work around this, CREATE the civicrm_mailing_abtest table using the SQL starting at line 32 of https://github.com/civicrm/civicrm-core/blob/master/CRM/Upgrade/Incremental/sql/4.6.alpha1.mysql.tpl

r4zoli

  • I post occasionally
  • **
  • Posts: 88
  • Karma: 1
  • CiviCRM version: 4.7
  • CMS version: Wordpress
  • MySQL version: 5
  • PHP version: 5
Re: CiviCRM_API3_Exception: "DB Error: no such table"
January 25, 2015, 11:52:39 pm
In my case the workaround works.  :)
Thanks for your effort.

Yashodha Chaku

  • Forum Godess / God
  • Ask me questions
  • *****
  • Posts: 755
  • Karma: 57
    • CiviCRM
Re: CiviCRM_API3_Exception: "DB Error: no such table"
January 27, 2015, 12:24:01 am
This has been fixed in the upgrade script and should be available in 4.6 alpha4 .

-Yashodha
Found this reply helpful? Contribute NOW and help us improve CiviCRM with the Make it Happen! initiative.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Discussion (deprecated) »
  • Alpha and Beta Release Testing »
  • 4.6 Release Testing »
  • CiviCRM_API3_Exception: "DB Error: no such table"

This forum was archived on 2017-11-26.