The Joomla! Forum ™



Forum rules


Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.



Post new topic Reply to topic  [ 42 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: DB Function error 1146
PostPosted: Tue Apr 08, 2008 10:18 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Tue Sep 18, 2007 9:19 pm
Posts: 19
Hello,

I need to transfer a functional joomla installation that is here:

http://qotsa.julianc.com

to another server. Because I am transferring to an IP for now, a joomla cloner script wasn't working right. I decided to do it manually, and got the working sql file from cpanel back as well as phpmyadmin afterwards to double check.

Once the joomla files were upload, the config file updated to match the sql info, I started getting this:

http://66.29.20.98/~thefade/

Code:
DB function failed with error number 1146
Table 'thefade_joom13.jos_session' doesn't exist SQL=SELECT session_id FROM jos_session WHERE session_id = '092d5926226c80011d04bf20201fe8e0'
SQL =

SELECT session_id
 FROM jos_session
 WHERE session_id = '092d5926226c80011d04bf20201fe8e0'


Each time I refresh a different WHERE session_id = is shown. If the SQL works fine on the other server, and I've doubled checked, tried a repair, and done it over a few times, what could this be? Thanks for any help :)


Top
 Profile  
 
PostPosted: Fri Apr 11, 2008 9:29 pm 
User avatar
Joomla! Hero
Joomla! Hero

Joined: Sat Dec 31, 2005 1:58 am
Posts: 2780
check the db user is the same and database is the same.
you can go thru phpmyadmin and empty the session table

_________________
Loyd
http://k4lch.info
http://volstatehosting.com


Top
 Profile  
 
PostPosted: Mon Apr 28, 2008 6:48 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Apr 28, 2008 6:16 pm
Posts: 11
DB function failed with error number 1146

You have recieved this error because your database is not using jos_ as its prefix , if you let us know what your database prefix is we will change the code to suit your needs or if you are happy to edit code yourself .

_________________
Thanks
pwdsoft
Website Design Development and Promotion
http://www.php-web-development.com


Last edited by pe7er on Wed Apr 30, 2008 9:52 pm, edited 1 time in total.
URL removed, self promotion is not allowed


Top
 Profile  
 
PostPosted: Wed Apr 30, 2008 11:33 am 
Joomla! Intern
Joomla! Intern

Joined: Wed Jun 21, 2006 11:03 pm
Posts: 55
did you fix the error?

If you are having problems with installation we know some people that can help / will install for you.


Top
 Profile  
 
PostPosted: Wed Apr 30, 2008 12:14 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Tue Sep 18, 2007 9:19 pm
Posts: 19
pwdsoft wrote:
DB function failed with error number 1146
You have recieved this error because your database is not using jos_ as its prefix , if you let us know what your database prefix is we will change the code to suit your needs or if you are happy to edit code yourself .


How can I change the prefix?


Top
 Profile  
 
PostPosted: Wed Apr 30, 2008 5:17 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Apr 28, 2008 6:16 pm
Posts: 11
To Change prefix Go to your database and check correct prefix (common starting charcters of tablename). Put that prefix in your configuration file of joomla.

_________________
Thanks
pwdsoft
Website Design Development and Promotion
http://www.php-web-development.com


Last edited by pe7er on Wed Apr 30, 2008 9:52 pm, edited 1 time in total.
URL removed, self promotion is not allowed


Top
 Profile  
 
PostPosted: Thu May 22, 2008 5:53 pm 
Joomla! Fledgling
Joomla! Fledgling

Joined: Thu May 22, 2008 5:50 pm
Posts: 2
$mosConfig_dbprefix = 'jos_';

is this the line your talking about in configuration file? If so, I'm having the same issue and my pre-fixes seem to match.


Top
 Profile  
 
PostPosted: Thu Jun 05, 2008 7:43 am 
Joomla! Fledgling
Joomla! Fledgling

Joined: Thu Jun 05, 2008 7:39 am
Posts: 3
I had the same error but pertaining to joomlat.bak_bb2_log. Joomlat is my database name and bak_ is the prefix for my tables. It turned out that the "bb2" was the Bad Behavior bot. I went into the settings for this bot and turned off the "verbose" setting and now I no longer see that mess at the top of my site.

Just wanted to let folks know what worked for me. If you can track down what piece is causing that and check the settings, it may be something similar.


Top
 Profile  
 
PostPosted: Sat Nov 08, 2008 12:12 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Sat Jun 30, 2007 11:19 am
Posts: 25
I am having the exact same problem, I checked my prefix in cpanel and it is rockandm_

In my config file it was jos_

I tried changing it and leaving it, adding the jos prefix to my username and that time it did at least tell me can not connect to the db.

I am at the end of my teather... can ANYONE please shed some light.

Ta


Top
 Profile  
 
PostPosted: Wed Nov 12, 2008 7:32 am 
Joomla! Fledgling
Joomla! Fledgling

Joined: Thu Jun 05, 2008 7:39 am
Posts: 3
Connectivityanywhere:

Can you paste the text from your error into a reply here? I think it might not be the prefix that's the problem. If you changed it or ensured the prefix was correct and this error is still getting thrown up, then maybe a component, mod or bot is causing the problem. That's what I explained in my post above. What text comes after the prefix in your error? If you can figure out what that is and disable it or change the settings (as in my case, where I turned off the verbose error reporting for the Bad Behavior bot) then your problem might be solved.

Cheers,
T.


Top
 Profile  
 
PostPosted: Fri Feb 06, 2009 6:05 am 
Joomla! Apprentice
Joomla! Apprentice

Joined: Fri Feb 06, 2009 5:58 am
Posts: 13
ok i just made a huge mistake by trying to change the prefix for the tables from the admin section and now i am getting the same error.

Code:
jtablesession::store failed
DB function failed with error number 1146
Table 'joomla.computec_session' doesn't exist SQL=INSERT INTO `computec_session` ( `session_id`,`time`,`username`,`gid`,`guest`,`client_id` ) VALUES ( '201a5cfd70ec046807563293d1ed8878','1233899163','','0','1','1' )



what should i do ..can someone help? Not able to open admin as well as the site.


Top
 Profile  
 
PostPosted: Wed Feb 11, 2009 10:52 am 
Joomla! Fledgling
Joomla! Fledgling

Joined: Thu Jun 05, 2008 7:39 am
Posts: 3
Why don't you log into the site where you're hosted - you should be able to get to your sql tables from there and fix the prefixes back to whatever they were. If that doesn't fix it then it's beyond me, I'm afraid.


Top
 Profile  
 
PostPosted: Wed Feb 11, 2009 2:06 pm 
User avatar
Joomla! Hero
Joomla! Hero

Joined: Sat Dec 31, 2005 1:58 am
Posts: 2780
log in to host control panel locate the configuration.php open it look for
this if 1.5 var $dbprefix = ' '; if 1.0
$mosConfig_dbprefix = ' ';

inside the ' ' change to match the prefix of your database then save it.
try to get into site now if prefix is correct then should be able to log in

_________________
Loyd
http://k4lch.info
http://volstatehosting.com


Top
 Profile  
 
PostPosted: Thu Feb 12, 2009 8:38 am 
Joomla! Apprentice
Joomla! Apprentice

Joined: Fri Feb 06, 2009 5:58 am
Posts: 13
thanks that fixed it :)


Top
 Profile  
 
PostPosted: Fri Feb 27, 2009 9:19 am 
Joomla! Apprentice
Joomla! Apprentice

Joined: Sat Oct 11, 2008 2:13 pm
Posts: 36
Urgent! We're having problem when we try to access our frontpage from our Joomla Beckend. Kindly help us below is the error we're getting... and when i go to PHPmyadmin i don't see this table jos_content in the Database.
---- Error -----


DB function failed with error number 1146
Table 'sthelen1_sent.jos_content' doesn't exist SQL=SELECT c.*, g.name AS groupname, cc.title as name, s.title AS sect_name, u.name AS editor, f.ordering AS fpordering, v.name AS author FROM jos_content AS c LEFT JOIN jos_categories AS cc ON cc.id = c.catid LEFT JOIN jos_sections AS s ON s.id = cc.section AND s.scope="content" INNER JOIN jos_content_frontpage AS f ON f.content_id = c.id INNER JOIN jos_groups AS g ON g.id = c.access LEFT JOIN jos_users AS u ON u.id = c.checked_out LEFT JOIN jos_users AS v ON v.id = c.created_by WHERE c.state >= 0 ORDER BY fpordering , fpordering LIMIT 0, 20


Top
 Profile  
 
PostPosted: Fri Mar 20, 2009 5:53 am 
Joomla! Intern
Joomla! Intern

Joined: Sat Dec 01, 2007 3:25 am
Posts: 86
dear hero,

my dbprefix is properly specified as
var $dbprefix = 'jos_';

and indeed, JSAS has a warning not to change this

but I still get the 1146 error message and the gibberish about
Table 'xxx.jos_session' doesn't exist

indeed, if you look at the list of db tables for this xxx database, you see there are no tables whatsoever -- on the other hand this is exactly the same situation that pertains with another site in a similar stage of development for which I get no such message!

indeed, the second site has been constructed by copying the files from the first site and making a few changes, yet for the first one everything works fine and for the second one I get the 1146 error message

ideas? oh yee who actually know the innards of joomla


Top
 Profile  
 
PostPosted: Fri Mar 20, 2009 1:22 pm 
User avatar
Joomla! Hero
Joomla! Hero

Joined: Sat Dec 31, 2005 1:58 am
Posts: 2780
did you create or import a database for the second site?

_________________
Loyd
http://k4lch.info
http://volstatehosting.com


Top
 Profile  
 
PostPosted: Sat Mar 21, 2009 8:57 pm 
Joomla! Intern
Joomla! Intern

Joined: Sat Dec 01, 2007 3:25 am
Posts: 86
I created it, then imported the structure only from the previous one


Top
 Profile  
 
PostPosted: Sat Mar 21, 2009 9:00 pm 
Joomla! Intern
Joomla! Intern

Joined: Sat Dec 01, 2007 3:25 am
Posts: 86
further thought to throw a monkeywrench (or a spanner, if you prefer) into all this: I have yet another site under development where all I did was create a new db, without importing anything -- in fact that db has no tables in it -- but for that site I have had no problems so far and do not get the 1146 message


Top
 Profile  
 
PostPosted: Sat Mar 21, 2009 10:06 pm 
Joomla! Intern
Joomla! Intern

Joined: Sat Dec 01, 2007 3:25 am
Posts: 86
maybe it's not a monkeywrench, or even a spanner . . . a little more looking and it appears that although that third database was created by me (in the name of the site under development), the system (ie, JSAS) is not using it . . . instead it is using a database it itself creates when it installs joomla . . . these default databases are named some version of %mysql% and they do have the tables . . .

I suppose the same is true of my second site, and although I created a database for it and then imported tables into it, this is not being used either

so, to get back to the original issue, perhaps something went wrong when the default database was created for the second site -- and that's why I get the 1146 message


Top
 Profile  
 
PostPosted: Fri Mar 27, 2009 12:27 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Aug 04, 2008 9:44 pm
Posts: 5
I am having the same issue. When I go into the MyPHPAdmin I do not even see a table called Session. Should I manually create one?


Top
 Profile  
 
PostPosted: Sun Mar 29, 2009 4:49 am 
Joomla! Intern
Joomla! Intern

Joined: Sat Dec 01, 2007 3:25 am
Posts: 86
I think, now, the best way to deal with the 1146 message is just to start over

delete/uninstall what you have created and then recreate/reinstall what you want

when the new one comes up be sure to rename the configuration file so its name is:
configuration.php . . . otherwise you will get an error message


Top
 Profile  
 
PostPosted: Sun Mar 29, 2009 3:48 pm 
Joomla! Apprentice
Joomla! Apprentice

Joined: Mon Aug 04, 2008 9:44 pm
Posts: 5
Thanks. However, I have a live site right now. If I do this what effect will this have on my site? If we are talking about a temporary downtime, then I am ok, but if I have to rebuild, then need to think about it more.


Top
 Profile  
 
PostPosted: Mon Mar 30, 2009 5:49 am 
Joomla! Intern
Joomla! Intern

Joined: Sat Dec 01, 2007 3:25 am
Posts: 86
my experience is with localhost, so you will have to decide for yourself about what to do with a live site

I have discovered one thing about JSAS which is key here (and everywhere): when you Create A New Site, you get a popup which tells you you have to delete the installation folder when you are done

Don't believe it

Don't believe it, not because it is wrong, but because it is ambiguous (and ambiguity is a bedfellow of JSAS).

Do not delete the installation file right after it has been created! In fact, you have to access your site through localhost first -- so that you will be led through a series of screens which create username/password that you will later need to access your site's backend (ie, accessing yoursite/administrator with a username and password)

only after all that do you delete the installation folder

should you delete it before this you will never be able to login successfully to
yoursite/administrator


Top
 Profile  
 
PostPosted: Wed Apr 29, 2009 4:44 pm 
Joomla! Fledgling
Joomla! Fledgling

Joined: Wed Apr 29, 2009 4:33 pm
Posts: 1
I had a similar 1146 error when installing AlfContact component. The problem for me was that the Joomla installer had not created the necessary tables in MySQL. I unzipped the AlfContact package and found the SQL install script, then opened in notepad and changed relative table names to absolute in 4 places. I then copied and pasted into phpmyadmin and ran without issues. Component works great now.

So before getting frustrated, be sure to check to make sure the table being requested actually exists in your DB. If it doesn't you may be able to fix easily in a similar way. I hope this helps someone else!


Top
 Profile  
 
PostPosted: Tue Aug 04, 2009 9:41 am 
Joomla! Fledgling
Joomla! Fledgling

Joined: Tue Aug 04, 2009 8:01 am
Posts: 4
While Changing from CB support to JomSocial support on a messenger based module I started to receive this error... Any advice would be appreciated...

DB function failed with error number 1146
Table 'gnrmgr_jo151.jos_community_connection' doesn't exist SQL=SELECT DISTINCT c.avatar, m.connect_from , s.username , s.session_id, u.name FROM jos_community_connection m, jos_community_users c, jos_session s, jos_users u WHERE m.connect_to = '70' AND u.id = s.userid and m.connect_from = s.userid and c.userid = s.useridDB function failed with error number 1146
Table 'gnrmgr_jo151.jos_community_users' doesn't exist SQL=SELECT avatar FROM jos_community_users WHERE userid = 70


Top
 Profile  
 
PostPosted: Thu Oct 01, 2009 7:02 pm 
Joomla! Intern
Joomla! Intern

Joined: Mon Oct 29, 2007 4:20 pm
Posts: 69
I get this EVERY TIME I try to install Joomla manually now on many different servers. The only way I've been able to figure out how to get around the problem is to use Fantastico if it is available and have it install it. Problem is, not all my clients have Fantastico available to them. I've had to go so far as to move their sites to get around the problem.

Can the Joomla folks please fix this? I see lots of people struggling with it.


Top
 Profile  
 
PostPosted: Mon Oct 05, 2009 5:43 am 
Joomla! Explorer
Joomla! Explorer

Joined: Mon Mar 09, 2009 9:54 am
Posts: 459
Location: Dallas, TX
There should be a good tutorial available or a video tutorial for this. We do all of our transfers manually and all of them are like a breeze. Of course at the beginning we were challenged because we were using different database prefixes. One time when we installed a website with a different prefix that we called soley instead of jos_, it cause problems in when trying to export, because we were trying to install it with jos_ database prefix instead of a soley database prefix. Be always sure you change the prefix database.

We always use linux server. They are more easier to use.

_________________
http://cmsteachings.com - Joomla Tips & Tutorials
http://ubrainmedia.com - My Joomla Company

My Joomla Advice is my personal experience. It does not means I am right or wrong. It just means that I work with Joomla in my own way and it works for me.


Top
 Profile  
 
PostPosted: Thu Dec 17, 2009 10:31 pm 
Joomla! Fledgling
Joomla! Fledgling

Joined: Thu Dec 17, 2009 6:38 pm
Posts: 3
Quote:
While Changing from CB support to JomSocial support on a messenger based module I started to receive this error... Any advice would be appreciated...


I had the exact same thing while moving from cb to jomsocial somebody know more about this issue? I'm a bit of a newbie so you gys got help me out step by step

jtablesession::Store Failed
DB function failed with error number 1146
Table 'DB452082.jos_users_visitsession' doesn't exist SQL=INSERT INTO `jos_users_visitsession` ( `session_id`,`time`,`username`,`gid`,`guest`,`client_id` ) VALUES ( 'lm3jqcki2m3pd2b7punfpmhg63','1261088982','','0','1','0' )

So what can i do now in my phpmyadmin which table exactly do i have to edit??


Top
 Profile  
 
PostPosted: Wed Mar 03, 2010 11:39 pm 
Joomla! Fledgling
Joomla! Fledgling

Joined: Wed Mar 03, 2010 11:15 pm
Posts: 1
I have the same issue, I am getting the 1146 error message, however I tried to change in the configuration.php file the var $dbprefix = 'jos_ '; but I received the following error message "Cannot save configuration.php.", Can you kindly help me with this error message?


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 42 posts ]  Go to page 1, 2  Next



Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group