Page 2 of 2

Re: DB Function error 1146

Posted: Wed Mar 31, 2010 11:35 pm
by digmarketing
I had this same issue. I found out that it was only because I had forgotten to inter my table info from the old site into the new site. As soon as I imported the MySQL file into the database the site showed up perfectly. Seems silly but that was all I forgot and the error was gone.

Re: DB Function error 1146

Posted: Sat May 22, 2010 12:32 am
by jairobg
I move my joomla to godaddy hosting and now show the error 1146.

I check the prefix and is ok 'jos_' (in configuration file and database).
I check the database user and is ok.

I import the database using SQL code, any sugestion?

Re: DB Function error 1146

Posted: Wed Sep 15, 2010 8:19 pm
by stevedknight
i have just had the same problem when moving sites from one hosting provider to another - i have successfully fixed the problem as when i re-imported the database into the new server it took the capitals out of my table prefix - changed the prefix to be in the same case in the configuration.php file and all works well

Re: DB Function error 1146

Posted: Wed Sep 22, 2010 2:11 am
by walkys
here,s wha i,ve done

1 download the confing.php on my desktop
2 Deleted the file configuration.php in CPanel ;/public_html
As my change been done in Joomla back end: changed the ('jos_') to something else let say (walt_)
P.S - Once the change been done even if you use the Cpanel and change the 'walt_' to 'jos_' it,s not going to work because you might have an error ....
3 Used Dreamweaver to Edit the Php file back ans change the name back to 'jos_'
4 upload the file back to ;/public_html
var $dbprefix = 'jos_';
and it works..... i didnt change anything thing in my database or create any new table

Re: DB Function error 1146

Posted: Wed Oct 27, 2010 5:43 pm
by cneal4
Thanks guys changing the configuration.php var $dbprefix = 'jos_'; to the name in my sql database worked for me.

Good luck this joomla thing is quite frustrating when you first start.

Re: DB Function error 1146

Posted: Wed Mar 30, 2011 10:30 pm
by americanclassic
chopnaldo wrote:
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??
I'm getting a similar error with the plugins:

500 - An error has occurred.
DB function failed with error number 1146
Table 'LLHS_jo151.jos_plugins' doesn't exist SQL=INSERT INTO `jos_plugins`(`name`, `element`, `folder`, `access`, `ordering`, `published`, `iscore`, `client_id`, `params` ) VALUES('User - Jomsocial User', 'jomsocialuser', 'user', '0', '0', '1', '0', '0', '' )

if you found any way to fix it, please let me know! :)
I've never worked with joomla before, I only installed it because I wanted to create a small social network for my club members--I'm not too familiar with PHP.

Re: DB Function error 1146

Posted: Tue Apr 05, 2011 3:06 pm
by sonnyharrison1
I was able to fix the problem as stated by configuration.php var $dbprefix = 'jos_'; to the name in my sql database as well. No problems post config switch.

Re: DB Function error 1146

Posted: Tue Apr 26, 2011 1:05 pm
by pepes
Hi me too I get DB Function error 1146 but is not the same error code that

Code: Select all

Table 'host_ac.tmp' doesn't exist SQL=SELECT b.`id` as _comment_last_id, b.`date` as _comment_date, count( b.`comment` ) as _comment_count, b.`comment` as _comment_last , b.`post_by` as _comment_last_by, c.`like` as _likes, a.*, TO_DAYS('2011-04-14 08:33:09') - TO_DAYS( DATE_ADD(a.`created`, INTERVAL 0 HOUR ) ) as _daydiff FROM `ac_community_activities` as a LEFT JOIN tmp as b ON a.`comment_id` = b.`contentid` AND a.`comment_type` = b.`type` LEFT JOIN `ac_community_likes` AS c ON a.`like_id` = c.`uid` AND a.`like_type` = c.`element` WHERE `archived`=0 GROUP BY a.`id` ORDER BY a.`created` DESC LIMIT 160
Anyone can help me?

Re: DB Function error 1146

Posted: Sun May 08, 2011 1:21 pm
by Deep Si
This error can also be generated as a result of a situation where tables have not been copied into the joomla database properly. So the table suffix might be correct, but some of the information is or tables are missing.

Examples of such situations might be a faulty migrations, restorations from backups or database copying from one host to another.

Re: DB Function error 1146

Posted: Thu May 31, 2012 1:20 pm
by SoftCorpse
hi, I installed joomla with no prefix and am getting the following error:

jos_session' doesn't exist SQL=INSERT INTO `jos_session` (`session_id`, `client_id`, `time`) VALUES ('71fb22b2cd545a57eeb33f4e46fd7583', 0, '1338469886')

Am I not able to install joomla without a prefix?

Re: DB Function error 1146

Posted: Thu May 31, 2012 5:38 pm
by Deep Si
You possibly can 'successfully' install with no prefix at all. Much depends on how bulletproof the installation program is. If you manage to do that it probably won't work.

By default, the prefix is jos_

You can utilise your own prefix, however some custom extensions are poorly designed and assume jos_ for table names regardless, so they may fail to work in my own experience. I won't 'list' the names in order to protect the guilty.

Utilising your own unique prefix for the joomla! table names on your installation is considered a good security measure.

If you deleted jos_ from the prefix field, but did not type an alternative one then the installation process might have continued successfully to the end. However, the probable result will be a website that doesn't work.

It sounds like you may have table names like :- banner, category, components, session.

Joomla! probably won't be expecting that.

It wants names like jos_session or me_session. where me_ is an example of a custom table name prefix.

  1. check what the table names are.
  2. check the file configuration.php in the root directory for a setting:- var $dbprefix = '';

To rectify the situation you can either start a fresh installation or alternatively you might possibly:-
  1. rename ALL the joomla tables to have a prefix e.g. jos_session
  2. edit the configuration.php file line of text to state var $dbprefix = 'jos_'; so that it matches the table name prefixes.
That may avoid you having to perform a fresh install.

Re: DB Function error 1146

Posted: Thu May 31, 2012 6:43 pm
by SoftCorpse
hehe, yea i get what you're saying. thanks for the reply!
guess i prefix will have to be used then, i was trying to find where it was hardcoded, but a major pain to do that, i will just settle for a custom prefix instead.

Re: DB Function error 1146

Posted: Mon Oct 07, 2013 10:06 am
by gsovis
I got the same error, but on the page tab I see "Error: 1146 Table 'nihss.nihss_tags' doesn't exist SQL=SELECT as value, a.title as text.......". Reading earlier posts on this error I changed the prefix to jos_. Then the page did not load. I removed it. Now I get "Error displaying the error page:Application instantiation Error'. Please help me.

Re: DB Function error 1146

Posted: Mon Jun 15, 2015 7:09 pm
by shawnlesky
I'm getting a DIFFERENT 1146 error I'd like to know how to fix; it's similar so I thought I'd post it here too.

Table '339331_12082013.dbl_users' doesn't exist SQL=SELECT id, password FROM dbl_users WHERE username='editedmyadminnameforsecurity purposes'

Re: DB Function error 1146

Posted: Tue Jun 16, 2015 6:50 am
by monlike
do you change this ?
var $dbprefix = 'jos_';

if yes
It sounds like the sql isn't being fully copied over to your server. You can simply download the sql dumps from the downloads area and import them into the database via phpmyadmin. The sql dumps contain the same data as the site shapers just in sql form.

Re: DB Function error 1146

Posted: Tue Jun 16, 2015 1:07 pm
by shawnlesky
I believe I changed that prefix to "dbl" instead of "jos", yes. However, I'm not quite sure how to go about taking your advice thereafter. I'm a novice when it comes to directly messing with the database. I have limited experience in there. I only touch it when I absolutely have to. I equate it to playing with a land mine, haha.

Re: DB Function error 1146

Posted: Tue Oct 06, 2015 12:26 pm
by mviallon
Hello, i have this same error when I want to crate a menu item which is a translation of another one.
I have created the original menu in English and want to create the same in Spanish. When I select of which item it is the translation of, if gives me this:
No valid database connection: DB function failed with error number 1146
Table 'bohealth.jos_Menu' doesn't exist SQL=SELECT `id` AS id,`title` FROM `jos_Menu` AS c WHERE c.client_id = 0 AND c.lft > 0 AND (c.language="*" OR c.language='en-GB')

The same happens for articles.
Any idea?

Many thanks!