Today I was trying to create a new album in my gallery and I got this error message:
There was an error while processing a database query
Does anyone know what that mean? ??? I know that it means that is has something to do with my database, but I have no idea what to do? ??? ???
enable debug mode and post the actual error message
Critical error There was an error while processing a database query.QuoteWhile executing query "INSERT INTO cpg1410_albums (category, title, uploads, pos, description) VALUES ('0', 'Sweet Sacrifice Radio Promo CD', 'NO', '1', '')" on 0
mySQL error: Unknown column 'uploads' in 'field list'
File: /www/free-site-host.com/a/m/y/amyleerockfaerie/htdocs/Gallery/include/functions.inc.php - Line: 249
Post a link to your gallery
Quote from: Sami on April 01, 2007, 08:33:48 AM
Post a link to your gallery
http://amyleerockfaerie.free-site-host.com/Gallery/index.php (http://amyleerockfaerie.free-site-host.com/Gallery/index.php)
Your gallery seems fine,
Try again see if problem solved ;)
:( nope......... still the same problem.
Maybe I can PM you the admin info, so you can take a look for yourself? Don't knwo if that would help.
gallery admin info is not helpful , you should check your cpg1410_albums table (mysql table) and see if it has the upload column or not , it's not normal !
aha, now I see. No it doesn't I think it may have been deleted by accident. I'm trying to recreate it, or restore, but I have no Idea how to. Maybe I should ask my webhost about this.
If the albums table is not there, you can re-create it using a query like this:CREATE TABLE cpg1410_albums (
aid int(11) NOT NULL auto_increment,
title varchar(255) NOT NULL default '',
description text NOT NULL,
visibility int(11) NOT NULL default '0',
uploads enum('YES','NO') NOT NULL default 'NO',
comments enum('YES','NO') NOT NULL default 'YES',
votes enum('YES','NO') NOT NULL default 'YES',
pos int(11) NOT NULL default '0',
category int(11) NOT NULL default '0',
thumb int(11) NOT NULL default '0',
keyword VARCHAR( 50 ),
alb_password VARCHAR( 32 ),
alb_password_hint TEXT,
PRIMARY KEY (aid),
KEY alb_category (category)
) TYPE=MyISAM COMMENT='Used to store albums';
Run this query in phpMyAdmin or similar. If you have no idea how to do this, ask your webhost for support.
Thanks a lot. That code is basically what I needed to fix the problem. Thanks a lot.
Problem solved. :)