Page 1 of 1

[SOLVED] DB function failed error 1054, column missing ?!

Posted: Mon Apr 07, 2008 10:22 am
by icebear
Im doing an upgrade, at the moment I got a problem with the "Content > Content by section > News > News Items"

When I click on it I get:
DB function failed with error number 1054
Unknown column 'c.access' in 'on clause' SQL=SELECT c.*, g.name AS groupname, cc.name, u.name AS editor, f.content_id AS frontpage, s.title AS section_name, v.name AS author FROM mos_content AS c, mos_categories AS cc, mos_sections AS s LEFT JOIN mos_groups AS g ON g.id = c.access LEFT JOIN mos_users AS u ON u.id = c.checked_out LEFT JOIN mos_users AS v ON v.id = c.created_by LEFT JOIN mos_content_frontpage AS f ON f.content_id = c.id WHERE c.state >= 0 AND c.catid=cc.id AND cc.section=s.id AND s.scope='content' AND c.sectionid='1' ORDER BY cc.ordering, cc.title, c.ordering LIMIT 0,50

There seems like a column is missing ?
Question is how do I repair it ?

Same thing with "Newsflashes"
But in both cases the "Add/Edit Categories work"

Re: DB function failed error 1054, column missing ?!

Posted: Mon Apr 07, 2008 10:34 am
by user deleted
Hi,

I did a quick search on "Unknown column 'c.access'" which returned some similar issues. In some of the cases users had specific content extensions installed (deep pockets, iJoomla), could that be the case with you? Do you have some kind of content extension installed?

Re: DB function failed error 1054, column missing ?!

Posted: Mon Apr 07, 2008 3:54 pm
by icebear
Well, yes
But how do I know which one is the problem ?

I have :
Akobook
Docman
Ipblocker
Mamboxplorer
Rwcards
Simpleboard
Virtuenart
Zoom MediaGallery

Re: DB function failed error 1054, column missing ?!

Posted: Mon Apr 07, 2008 4:19 pm
by icebear
Found a working solution :)

On mysql5 the joining of tables has other rules...
you can can change 2 lines for a working mambo :-)

file: admin.content.php line 201
old: . "\n FROM , #__content AS c, #__categories AS cc, #__sections AS s"
new: . "\n FROM #__categories AS cc, #__sections AS s, #__content AS c "

simply move the content AS c to the end.

also: Line 312
old: . "\n FROM , #__content AS c, #__categories AS cc, #__sections AS s"
new: . "\n FROM #__categories AS cc, #__sections AS s, #__content AS c "

then the content works...

I´ve found another error, same type:
/administrator/components/com_events/
admin.events.main.php Line 227
change to:
. "\nFROM #__categories AS cc, #__events AS a "

(Simple reorder the '__events AS a' what is used in the next join to the end)


Source: http://forum.mamboserver.com/showthread.php?t=65497

Re: [SOLVED] DB function failed error 1054, column missing ?!

Posted: Mon Apr 07, 2008 6:28 pm
by user deleted
Glad you fixed it, I found that too in one of the results returned from my search.

Re: [SOLVED] DB function failed error 1054, column missing ?!

Posted: Mon Apr 07, 2008 10:40 pm
by icebear
Thank you :)

Now Im just trying to find Swedish language files for both Frontend and Backend that are for newer versions than 4.5.2.3
The one I have for Frontend also works for 4.5.3h, but found nothing for Backend newer than 4.5.2.3 that works.

Se also: http://forum.mamboserver.com/showthread.php?t=85662 (for you Swedish guys)

If it all works, Im going to try to upgrade to Joomla later on.
I have not found any guides for that though...

Tried to upgrade to Mambo 4.6, but it did not work out.
I thought that going to 4.6 first, would be a better thing to do before going over to Joomla.
But maybe I can skip that step? (If I find a guide how to do it ...)