Jump to content

Recommended Posts

Posted

Use phpAdmin in cPanel to export the table from the database on the site you want to copy from.

 

Then use phpAdmin in cPanel to create a table in the other database and then insert the data into the new table.

Posted (edited)
Use phpAdmin in cPanel to export the table from the database on the site you want to copy from.

 

Then use phpAdmin in cPanel to create a table in the other database and then insert the data into the new table.

 

I should have mentioned that the table already exists in the database I want to copy into.

 

Will the "Insert" into the new database ask me if I want to overwrite the existing file or will it just overwrite without asking?

 

Also, when exporting do I enable/check "Save as file"? Or do I just copy/paste from the first to the second table?

Edited by rnmcd
Posted

Here is the "Export" from the table I want to copy from (I didn't "save as file":

 

-- phpMyAdmin SQL Dump

-- version 2.6.4-pl2

-- http://www.phpmyadmin.net

--

-- Host: localhost

-- Generation Time: Dec 21, 2005 at 01:13 PM

-- Server version: 4.0.25

-- PHP Version: 4.3.11

--

-- Database: `localme_or`

--

 

-- --------------------------------------------------------

 

--

-- Table structure for table `promo`

--

 

CREATE TABLE `promo` (

`id` int(10) NOT NULL auto_increment,

`name` varchar(10) NOT NULL default '',

`value` varchar(10) NOT NULL default '',

`percent` varchar(4) NOT NULL default '',

PRIMARY KEY (`id`)

) TYPE=MyISAM AUTO_INCREMENT=15 ;

 

--

-- Dumping data for table `promo`

--

 

INSERT INTO `promo` VALUES (13, 'code', 'qwerty', '50');

INSERT INTO `promo` VALUES (1, 'active', 'yes', '');

INSERT INTO `promo` VALUES (14, 'code', 'freetest', 'free');

 

Do I just copy and paste this into the table that I want to copied to?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...