Webmaster Forum


Go Back   Webmaster Forum > Web Development > Web Design Lobby > Coding Forum
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Coding Forum Problems with your code? Let's hear about it.

   

Reply
 
LinkBack Thread Tools Display Modes
Old 01-24-2005, 03:41 PM   #1 (permalink)
Inactive
 
Join Date: 11-20-04
Posts: 27
iTrader: 0 / 0%
Latest Blog:
None

kakarotto is liked by many
Exclamation SQL problem

Well, I have been everywhere with this problem but no one's answers work. perhaps you guys' will .

I need to upload a db for PHPNuke. Most of the tables are already created, but some of the content inside them isn't, which creates errors at my site. What I need to figure out is a way that would let me insert the new SQL content to the old ones, without having the problem of the error saying:

#1050 - Table 'bahd bbka' already exists

Because when this happens to whole thing stops. In other words I need to find a way of making phpmyadmin insert the data and if it finds that the table is already there, it will just skip that and put in what is missing.

Thanks in advanced.
kakarotto is offline  
Add Post to del.icio.us
Reply With Quote
Old 01-24-2005, 03:58 PM   #2 (permalink)
v7n Mentor
 
hatchet's Avatar
 
Join Date: 10-11-03
Posts: 1,137
iTrader: 0 / 0%
Latest Blog:
None

hatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nice
Look at your sql file - remove the parts (at the top most likely) where it says
CREATE TABLE `bahd bbka` (
`field1` varchar(14) NOT NULL default '',
`field2` varchar(14) NOT NULL default '',
PRIMARY KEY (`field1`)
) TYPE=MyISAM;

should work just fine.
hatchet is offline  
Add Post to del.icio.us
Reply With Quote
Old 01-24-2005, 04:02 PM   #3 (permalink)
v7n Mentor
 
hatchet's Avatar
 
Join Date: 10-11-03
Posts: 1,137
iTrader: 0 / 0%
Latest Blog:
None

hatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nice
Or better yet change it to
CREATE TABLE IF NOT EXISTS 'bahd bbka' (
etc
etc) etc
hatchet is offline  
Add Post to del.icio.us
Reply With Quote
Old 01-24-2005, 04:02 PM   #4 (permalink)
Inactive
 
Join Date: 11-20-04
Posts: 27
iTrader: 0 / 0%
Latest Blog:
None

kakarotto is liked by many
So if I have:

CREATE TABLE nuke_bbforums (
forum_id smallint(5) unsigned NOT NULL auto_increment,
cat_id mediumint( unsigned DEFAULT '0' NOT NULL,
forum_name varchar(150),
forum_desc text,
forum_status tinyint(4) DEFAULT '0' NOT NULL,
forum_order mediumint( unsigned DEFAULT '1' NOT NULL,
forum_posts mediumint( unsigned DEFAULT '0' NOT NULL,
forum_topics mediumint( unsigned DEFAULT '0' NOT NULL,
forum_last_post_id mediumint( unsigned DEFAULT '0' NOT NULL,
prune_next int(11),
prune_enable tinyint(1) DEFAULT '1' NOT NULL,
auth_view tinyint(2) DEFAULT '0' NOT NULL,
auth_read tinyint(2) DEFAULT '0' NOT NULL,
auth_post tinyint(2) DEFAULT '0' NOT NULL,
auth_reply tinyint(2) DEFAULT '0' NOT NULL,
auth_edit tinyint(2) DEFAULT '0' NOT NULL,
auth_delete tinyint(2) DEFAULT '0' NOT NULL,
auth_sticky tinyint(2) DEFAULT '0' NOT NULL,
auth_announce tinyint(2) DEFAULT '0' NOT NULL,
auth_globalannounce tinyint(2) DEFAULT '3' NOT NULL,
auth_vote tinyint(2) DEFAULT '0' NOT NULL,
auth_pollcreate tinyint(2) DEFAULT '0' NOT NULL,
auth_attachments tinyint(2) DEFAULT '0' NOT NULL,
auth_download tinyint(2) DEFAULT '0' NOT NULL,
PRIMARY KEY (forum_id),
KEY forums_order (forum_order),
KEY cat_id (cat_id),
KEY forum_last_post_id (forum_last_post_id)
);

I need to leave it like:

nuke_bbforums (
forum_id smallint(5) unsigned NOT NULL auto_increment,
cat_id mediumint( unsigned DEFAULT '0' NOT NULL,
forum_name varchar(150),
forum_desc text,
forum_status tinyint(4) DEFAULT '0' NOT NULL,
forum_order mediumint( unsigned DEFAULT '1' NOT NULL,
forum_posts mediumint( unsigned DEFAULT '0' NOT NULL,
forum_topics mediumint( unsigned DEFAULT '0' NOT NULL,
forum_last_post_id mediumint( unsigned DEFAULT '0' NOT NULL,
prune_next int(11),
prune_enable tinyint(1) DEFAULT '1' NOT NULL,
auth_view tinyint(2) DEFAULT '0' NOT NULL,
auth_read tinyint(2) DEFAULT '0' NOT NULL,
auth_post tinyint(2) DEFAULT '0' NOT NULL,
auth_reply tinyint(2) DEFAULT '0' NOT NULL,
auth_edit tinyint(2) DEFAULT '0' NOT NULL,
auth_delete tinyint(2) DEFAULT '0' NOT NULL,
auth_sticky tinyint(2) DEFAULT '0' NOT NULL,
auth_announce tinyint(2) DEFAULT '0' NOT NULL,
auth_globalannounce tinyint(2) DEFAULT '3' NOT NULL,
auth_vote tinyint(2) DEFAULT '0' NOT NULL,
auth_pollcreate tinyint(2) DEFAULT '0' NOT NULL,
auth_attachments tinyint(2) DEFAULT '0' NOT NULL,
auth_download tinyint(2) DEFAULT '0' NOT NULL,
PRIMARY KEY (forum_id),
KEY forums_order (forum_order),
KEY cat_id (cat_id),
KEY forum_last_post_id (forum_last_post_id)
);

?
kakarotto is offline  
Add Post to del.icio.us
Reply With Quote
Old 01-24-2005, 05:34 PM   #5 (permalink)
Possible Terrorist
 
kwvarga's Avatar
 
Join Date: 10-13-03
Location: Tuscaloosa, AL or Atlanta
Posts: 4,904
iTrader: 0 / 0%
Latest Blog:
A+ Certification

kwvarga is a highly respected web prokwvarga is a highly respected web prokwvarga is a highly respected web prokwvarga is a highly respected web prokwvarga is a highly respected web prokwvarga is a highly respected web prokwvarga is a highly respected web prokwvarga is a highly respected web prokwvarga is a highly respected web prokwvarga is a highly respected web prokwvarga is a highly respected web pro
Send a message via AIM to kwvarga
I would leave the CREATE TABLE IF NOT EXISTS like he says in his first post
__________________
Kyle Varga
"m3lt/theSpear"
student, web designer/coder, future IT consultant
Experience: PHP/MySQL, Java, C++, MS-SQL
kwvarga is offline  
Add Post to del.icio.us
Reply With Quote
Old 01-24-2005, 07:34 PM   #6 (permalink)
v7n Mentor
 
hatchet's Avatar
 
Join Date: 10-11-03
Posts: 1,137
iTrader: 0 / 0%
Latest Blog:
None

hatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nicehatchet is just really nice
Exactly Kyle. you need to leave it like
CREATE TABLE IF NOT EXISTS 'nuke_bbforums' (
etc..etc..
hatchet is offline  
Add Post to del.icio.us
Reply With Quote
Old 01-24-2005, 08:20 PM   #7 (permalink)
Inactive
 
Join Date: 11-20-04
Posts: 27
iTrader: 0 / 0%
Latest Blog:
None

kakarotto is liked by many
you are kool lol
kakarotto is offline  
Add Post to del.icio.us
Reply With Quote
Go Back   Webmaster Forum > Web Development > Web Design Lobby > Coding Forum

Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
where is the problem parabara Web Hosting Forum 11 09-23-2007 03:45 PM
Google's China Problem (and China's Google Problem) - NYTimes Sunday Mag (4/23/06) Julie Google Forum 3 09-18-2007 02:00 AM
Problem with godaddy. Post your problem here!! charlesgan Web Hosting Forum 7 05-09-2007 10:36 AM
CSS problem blelisa Web Design Lobby 4 03-05-2004 03:32 PM


Sponsor Links
Get exposure! Get exposure! Find Scripts Web Hosting Directory Get exposure! SEO Blog


All times are GMT -7. The time now is 02:58 AM.
© Copyright 2008 V7 Inc