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) »
  • Support »
  • Installing CiviCRM »
  • Joomla! Installations (Moderator: Deepak Srivastava) »
  • Installation Successful, DB Error: syntax error
Pages: [1]

Author Topic: Installation Successful, DB Error: syntax error  (Read 1131 times)

epodowski

  • Guest
Installation Successful, DB Error: syntax error
July 17, 2009, 04:09:24 pm
Hello,

This is my first installation of CiviCRM.  It went well until I tried to access Administer CiviCRM from the Joomla Components Menu.  I received the following error.  I am not very literate in MySQL, could someone give me a troubleshooting hint as to the possible cause?

We are using Joomla 1.5.11, CiviCRM 2.2.7, MySQL 4.1.22 and PHP 5.2.6.

Additional information - I was reading another post about DB errors and table type.  This database is shared with the Joomla installation.  All the civicrm_ tables are InnoDB and all the jos_ tables are MyISAM.

Thank you for your help.
Ed Podowski


Code: [Select]

Sorry. A non-recoverable error has occurred.


--------------------------------------------------------------------------------

DB Error: syntax error

Database Error Code: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(MINUTE, cache_date, NOW()) > 0 )' at line 7, 1064

Return to home page.

Error Details:


Array
(
    [callback] => Array
        (
            [0] => CRM_Core_Error
            [1] => handle
        )

    [code] => -2
    [message] => DB Error: syntax error
    [mode] => 16
    [debug_info] =>
DELETE     g
FROM       civicrm_group_contact_cache g
INNER JOIN civicrm_contact c ON c.id = g.contact_id
WHERE      g.group_id IN (
    SELECT id
    FROM   civicrm_group
    WHERE  TIMESTAMPDIFF(MINUTE, cache_date, NOW()) > 0  
)
 [nativecode=1064 ** You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(MINUTE, cache_date, NOW()) > 0  
)' at line 7]
    [type] => DB_Error
    [user_info] =>
DELETE     g
FROM       civicrm_group_contact_cache g
INNER JOIN civicrm_contact c ON c.id = g.contact_id
WHERE      g.group_id IN (
    SELECT id
    FROM   civicrm_group
    WHERE  TIMESTAMPDIFF(MINUTE, cache_date, NOW()) > 0  
)
 [nativecode=1064 ** You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(MINUTE, cache_date, NOW()) > 0  
)' at line 7]
    [to_string] => [db_error: message="DB Error: syntax error" code=-2 mode=callback callback=CRM_Core_Error::handle prefix="" info="
DELETE     g
FROM       civicrm_group_contact_cache g
INNER JOIN civicrm_contact c ON c.id = g.contact_id
WHERE      g.group_id IN (
    SELECT id
    FROM   civicrm_group
    WHERE  TIMESTAMPDIFF(MINUTE, cache_date, NOW()) > 0  
)
 [nativecode=1064 ** You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(MINUTE, cache_date, NOW()) > 0  
)' at line 7]"]
)
[/code]
« Last Edit: July 17, 2009, 04:26:52 pm by epodowski »

lcdweb

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1620
  • Karma: 116
    • www.lcdservices.biz
  • CiviCRM version: many versions...
  • CMS version: Joomla/Drupal
  • MySQL version: 5.1+
  • PHP version: 5.2+
Re: Installation Successful, DB Error: syntax error
July 17, 2009, 07:58:27 pm
You're running MySQL 4. Civi requires 5.x
The syntax error is a result of version differences. Talk to your hosting provider and see if they can enable mysql 5 on your space.
support CiviCRM through 'make it happen' initiatives!
http://civicrm.org/mih

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Installing CiviCRM »
  • Joomla! Installations (Moderator: Deepak Srivastava) »
  • Installation Successful, DB Error: syntax error

This forum was archived on 2017-11-26.