Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Page 1 of 2
Undefined index error
 
jmayer
Jr. Member
 
Total Posts:  21
Joined:  2007-09-03
 

Hello,

Getting error when trying to use latest version of Magento 1.019870 when upgrading basic installation of ver. 1.0.19700. Copied files from existing . Using MAMP BTW. I only have tried to upgrade since I cannot press “continue on the first tab of the checkout in the login box “ for version 1.0.19700

Notice: Undefined index:  0 in /Applications/MAMP/htdocs/thesite/app/code/core/Mage/Core/Model/Mysql4/Config.php on line 107
Trace:
#0 /Applications/MAMP/htdocs/thesite/app/code/core/Mage/Core/Model/Mysql4/Config.php(107): mageCoreErrorHandler(8, ‘Undefined index...’, ‘/Applications/M...’, 107, Array)
#1 /Applications/MAMP/htdocs/thesite/app/code/core/Mage/Core/Model/Config.php(200): Mage_Core_Model_Mysql4_Config->loadToXml(Object(Mage_Core_Model_Config))
#2 /Applications/MAMP/htdocs/thesite/app/code/core/Mage/Core/Model/App.php(208): Mage_Core_Model_Config->init(Array)
#3 /Applications/MAMP/htdocs/thesite/app/Mage.php(404): Mage_Core_Model_App->init(’’, ‘store’, Array)
#4 /Applications/MAMP/htdocs/thesite/app/Mage.php(423): Mage::app(’’, ‘store’, Array)
#5 /Applications/MAMP/htdocs/thesite/index.php(40): Mage::run()
#6 {main}

Any ideas would be appreciated.

 
Magento Community Magento Community
Magento Community
Magento Community
 
Scott Bakke
Jr. Member
 
Total Posts:  5
Joined:  2008-04-23
 

I am getting the same error.

I’ve just tried to publish my Magento site onto a MediaTemple server.

It runs fine on my local machine with MAMP.

 
Magento Community Magento Community
Magento Community
Magento Community
 
darki777
Jr. Member
 
Total Posts:  25
Joined:  2008-04-08
 

I have this error too (on XAMPP) :( and also another errors when i update my magento with the “Magento Downloader”, the new version is a little bit buggy :/

 
Magento Community Magento Community
Magento Community
Magento Community
 
jeanlucb
Member
 
Total Posts:  60
Joined:  2008-02-10
 

same problem, please help !

 
Magento Community Magento Community
Magento Community
Magento Community
 
kthull
Jr. Member
 
Total Posts:  3
Joined:  2008-04-29
 

Add me to the list. Have any of you been able to get back into your admin panel? I had given up on trying to get multiple websites/stores running and upon deleting one, I got the above error. I can’t tell you how frustrating my Magento experience has been and how fragile this system seems to be. Unfortunately, I think it’s time for me to look elsewhere as I have several development projects waiting for a solution.

 
Magento Community Magento Community
Magento Community
Magento Community
 
mediagang
Sr. Member
 
Avatar
Total Posts:  111
Joined:  2008-01-16
Leeds UK
 

I also get this error!  Just posted the following as a bug to the magento team:

I have built my store using Magento ver. 1.0.19870 on windows xampp.  I’m now trying to move the site to the live server which is on a shared hosting account.  I’m able to install the latest version of 1.0.19870.4 on the live server using the following steps:

I then drop the tables and import my exsisting database ensuring the database name and privalliges match the live server. 
(I had to change the name of the database, as the db name magento was not available on the live server, as someone else had taken this name.  Changed the name of the db using phpmyadmin.)

1) Fresh install on live server
2) changed base url in both old site to {{baseurl}}
3) ran this code new db:
SET SQL_MODE=’’;
SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE=’NO_AUTO_VALUE_ON_ZERO’;

http://www.magentocommerce.com/boards/viewthread/8302/

4) exported old db using phpmyadmin
settings: extened inserts (off)
5) used BigDump to import due to file size
6) upload template files and media files
7) Clear the session and cache folders. 

I then see all the products, catergories and attributes.  However the correct templates to not display.  When i go to change settings in the configuration, i get the following error:

Notice: Undefined index:  0 in C:\xampp\htdocs\YCS\app\code\core\Mage\Core\Model\Mysql4\Config.php on line 107
Trace:
#0 C:\xampp\htdocs\YCS\app\code\core\Mage\Core\Model\Mysql4\Config.php(107): mageCoreErrorHandler(8, ‘Undefined index...’, ‘C:\xampp\htdocs...’, 107, Array)
#1 C:\xampp\htdocs\YCS\app\code\core\Mage\Core\Model\Config.php(200): Mage_Core_Model_Mysql4_Config->loadToXml(Object(Mage_Core_Model_Config))
#2 C:\xampp\htdocs\YCS\app\code\core\Mage\Core\Model\App.php(208): Mage_Core_Model_Config->init(Array)
#3 C:\xampp\htdocs\YCS\app\Mage.php(404): Mage_Core_Model_App->init(’’, ‘store’, Array)
#4 C:\xampp\htdocs\YCS\app\Mage.php(423): Mage::app(’’, ‘store’, Array)
#5 C:\xampp\htdocs\YCS\index.php(40): Mage::run()
#6 {main}

 
Magento Community Magento Community
Magento Community
Magento Community
 
mediagang
Sr. Member
 
Avatar
Total Posts:  111
Joined:  2008-01-16
Leeds UK
 

After many days of searching and testing i have found a solution to this smile

I checked to see what values the default admin store had in the following tables:

core_store
core_store_group
core_website

The values should be 0.  In my case it was 2.  This is probably a cause from an auto-increment whilst exporting/importing using tools like myphpadmin (as i have done).

Anyhow, i hope this helps you all…

 
Magento Community Magento Community
Magento Community
Magento Community
 
Bowen
Member
 
Avatar
Total Posts:  37
Joined:  2008-04-09
 

wow, that worked for me and don’t $*%^ about databases.  thank you!!!

 
Magento Community Magento Community
Magento Community
Magento Community
 
TemplatesMaster
Guru
 
Avatar
Total Posts:  308
Joined:  2008-04-01
Switzerland
 

This happens when you import database and have auto_value_for_zero = on on your mysql server.
You can always add this string to your sql dump
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";

 
Magento Community Magento Community
Magento Community
Magento Community
 
piccaya
Jr. Member
 
Avatar
Total Posts:  15
Joined:  2008-10-07
Brussels
 

Thanks Media Gang - this really help me to sort out a true crash!

 
Magento Community Magento Community
Magento Community
Magento Community
 
Doron Tal
Jr. Member
 
Total Posts:  1
Joined:  2008-11-19
 

amazing… worked for me as well,
I have just inserted the line to my import sql script:
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";

and it worked fine!!!
thanks

 
Magento Community Magento Community
Magento Community
Magento Community
 
crxman
Member
 
Total Posts:  57
Joined:  2008-11-14
 

Thanks a mediagang you help me a lot too !!!

in fact you have to check :
mag_core_store
mag_core_store_group
mag_core_website
mag_customer_group

compare with a fresh install and put “0” where you have to.

 
Magento Community Magento Community
Magento Community
Magento Community
 
kirubakar
Jr. Member
 
Total Posts:  2
Joined:  2009-01-09
 

Pls HELP Me urgent

Hi guys, wishes for ur reseaching, But one thing, these method not working for me, pls any one help me its urgent. What i did
I run the these queris first

SET SQL_MODE=’’;
SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE=’NO_AUTO_VALUE_ON_ZERO’;

then I import the database, then after I again run the queries like

SET SQL_MODE=IFNULL(@OLD_SQL_MODE,’’);
SET FOREIGN_KEY_CHECKS=IFNULL(@OLD_FOREIGN_KEY_CHECKS,0); but it shows the error, so then I run the queries like

SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO"; It executes but there is no result , again I seeing the error like

Notice: Undefined index:  0 in C:\wamp\www\ayuryoga\magento1\app\code\core\Mage\Core\Model\Mysql4\Config.php on line 107
Trace:
#0 C:\wamp\www\ayuryoga\magento1\app\code\core\Mage\Core\Model\Mysql4\Config.php(107): mageCoreErrorHandler(8, ‘Undefined index...’, ‘C:\wamp\www\ayu...’, 107, Array)
#1 C:\wamp\www\ayuryoga\magento1\app\code\core\Mage\Core\Model\Config.php(200): Mage_Core_Model_Mysql4_Config->loadToXml(Object(Mage_Core_Model_Config))
#2 C:\wamp\www\ayuryoga\magento1\app\code\core\Mage\Core\Model\App.php(208): Mage_Core_Model_Config->init(Array)
#3 C:\wamp\www\ayuryoga\magento1\app\Mage.php(404): Mage_Core_Model_App->init(’’, ‘store’, Array)
#4 C:\wamp\www\ayuryoga\magento1\app\Mage.php(423): Mage::app(’’, ‘store’, Array)
#5 C:\wamp\www\ayuryoga\magento1\index.php(40): Mage::run()
#6 {main}

When ever I access the magento index file it cums, bcos I changed the code from one server to another one server

 
Magento Community Magento Community
Magento Community
Magento Community
 
Raj Aryan
Jr. Member
 
Avatar
Total Posts:  7
Joined:  2009-03-19
 

Hi frnds i want to add my view to this post...while importing database of magento to another server.(means while config database of another server ) we need to take care of these steps..

1. First export the database from first server. by Disabling foreign key checks Checkbox checked
2. While importing database to another server..
add this script at the starting of your sql script

SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT;
SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS;
SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION;
SET NAMES utf8;
SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0;
SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE=’NO_AUTO_VALUE_ON_ZERO’;
SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0;

3. and at the end of your sql file add this script ..
SET SQL_MODE=@OLD_SQL_MODE;
SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS;
SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS;
SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT;
SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS;
SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION;
SET SQL_NOTES=@OLD_SQL_NOTES;

4. Then we need to make changes in some tables..
like core_config_data
here edit two entries having config_id 2,3
to your new server’s url path to magento’s folder..
like first you have http://hostname/magento(site_name)/
change it to new server url..
http://hostname/magento(site_name)/
in both entries

5. Edit local.xml
there you need to edit the database name,username and password of your new server..

<default_setup>
<connection>
<host><![CDATA[localhost]]></host>
<username><![CDATA[username]]></username>
<password><![CDATA[password]]></password>
<dbname><![CDATA[database]]></dbname>
<active>1</active>
</connection>
</default_setup>

 
Magento Community Magento Community
Magento Community
Magento Community
 
tragic_rich
Jr. Member
 
Avatar
Total Posts:  15
Joined:  2009-04-03
San Diego, CA
 

OMG Thank you Raj_Aryan!!!
This has been a week long pain in my ass. I had tried all of the suggestions on this page, plus a many others from other magento related blogs, with no success. Somehow I overlooked your comment at the bottom. Although some of the techniques would allow me to successfully import my DB and even view my site, the site was not displaying the appropriate theme. When I tried to edit the suggested tables in phpmyadmin i got MySQL errors. If I tried to change anything in the admin I got magento errors. Finally your advice about changing the ‘core_config_data’ table allowed me to change the base_url without breaking the site via the admin. From there I had to edit the tables in the following order (to change the admin id to 0):
core_website
core_store_group
core_store

and finally MySQL allowed the changes and my site displayed appropriately!!
Thank you all for your excellent posts.

 
Magento Community Magento Community
Magento Community
Magento Community
 
rentown
Jr. Member
 
Total Posts:  29
Joined:  2009-03-01
 

hi i dont understand much about programing.

i have the following error:

Undefined index: url in /home/soaringc/domains/dressanddresses.com/public_html/app/code/core/Mage/Core/Model/Email/Template/Filter.php on line 253

the above is the same fix?

if not.

is there anyone that can help me?

i have problem on the check out. and it keeps showing:
“"There was an error processing your order. Please contact us or try again later”

and then i keep clicking checkout and goes to paypal and says:

“Unable to process payment. Please contact the merchant as the shipping address provided by the merchant is invalid, and the merchant has requested that your order must be shipped to that address.”

Please help.

my website it was working for several month and now suddenly is just not working.

i havent changed anything for months. help!!

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top
Page 1 of 2