error in SQL syntax

hugeknot - June 20, 2008 - 23:20
Project:Database Scripts
Version:5.x-1.x-dev
Component:Code
Category:support request
Priority:critical
Assigned:hugeknot
Status:closed
Description

I get this error message when I try to log out:
**********************************************************************
user warning: 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 'INNER JOIN node_access na ON na.nid = node.nid WHERE (na.grant_view >= 1 AND ((n' at line 1 query: INNER JOIN node_access na ON na.nid = node.nid WHERE (na.grant_view >= 1 AND ((na.gid = 0 AND na.realm = 'all') OR (na.gid = 1 AND na.realm = 'term_access'))) LIMIT 0, 5 in /home/musicoll/public_html/test/includes/database.mysql.inc on line 172.
**********************************************************************

I am sure it is something I have done to the database rather than the script.

If I try to edit my account I get: (on page - http://musicollaborate.com/test/?q=user/1)
***********************************************************************
Fatal error: Cannot access empty property in /home/musicoll/public_html/test/modules/profile/profile.module on line 549

#1

hugeknot - June 21, 2008 - 23:42

I did a complete reinstall with fresh database and then the error came back!

Not sure if it is the phpbb2 migration or the other users that I am importing with an SQL query... something is breaking the database!

#2

hugeknot - June 22, 2008 - 04:52

user warning: 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 'INNER JOIN node_access na ON na.nid = node.nid WHERE (na.grant_view >= 1 AND ((n' at line 1 query: INNER JOIN node_access na ON na.nid = node.nid WHERE (na.grant_view >= 1 AND ((na.gid = 0 AND na.realm = 'all') OR (na.gid = 1 AND na.realm = 'term_access'))) LIMIT 0, 5 in /home/musicoll/public_html/includes/database.mysql.inc on line 172.

It happened again. I managed to fix it before by changing some of the privacy options on the custom profile fields.

i can't find anything that cold be causing this now!!

Strangely, the site is failing to remember anything that I am doing... it is not updating the database!
It is fine when I am logged in, but when I log-out, everything reverts - as if it is a fresh installation - and I get the error message.

#3

hugeknot - June 22, 2008 - 11:32
Priority:normal» critical

user warning: 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 'INNER JOIN node_access na ON na.nid = node.nid WHERE (na.grant_view >= 1 AND ((n' at line 1 query: INNER JOIN node_access na ON na.nid = node.nid WHERE (na.grant_view >= 1 AND ((na.gid = 0 AND na.realm = 'all') OR (na.gid = 1 AND na.realm = 'term_access'))) LIMIT 0, 5 in /home/musicoll/public_html/includes/database.mysql.inc on line 172.

Any Ideas?

#4

hugeknot - June 24, 2008 - 08:34
Status:active» fixed

It was a box issue, issue solved in support forums... thanks.

#5

Anonymous (not verified) - July 8, 2008 - 08:42
Status:fixed» closed

Automatically closed -- issue fixed for two weeks with no activity.

#6

g76 - September 29, 2008 - 19:08

could you point to the forum topics? Same problem.

 
 

Drupal is a registered trademark of Dries Buytaert.