Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8555557
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T15:08:59+00:00 2026-06-11T15:08:59+00:00

I want to copy data from one database which has table named domains to

  • 0

I want to copy data from one database which has table named domains to another database which also has the table named domains to it.

I have tried doing it using phpmyadmin but it doesn’t copy maybe because of Auto_increment values. it just doesn’t get copied to another database.table.

I want to know what can be done in this regard? also I don’t want to copy old ID(auto_increment) values from first database to another.

phpmyadmin response.

 #1136 - Column count doesn't match value count at row 1 

both the structures are same in the databases still this.

My Query.

 INSERT INTO `site1`.`domains`
 SELECT * FROM `site33`.`domains` 

^ This much is fixed.
now comes the auto_increment problem I Get:

  #1062 - Duplicate entry '1' for key 'PRIMARY' 
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T15:09:00+00:00Added an answer on June 11, 2026 at 3:09 pm

    You are using an insert statement that has an incorrect number of values, for instance:

    for a table with columns a, b and c, these are all invalid:

    INSERT INTO YourTable VALUES (1, 2);
    
    INSERT INTO YourTable(b, c) VALUES (1, 2, 3);
    
    INSERT INTO YourTable(a, b, c) VALUES (2, 3);
    

    The number of columns in the column list must match the number of values in the value list.

    You may only omit the column list, but only if you specify one value for each column and in the order in which the columns exist in the table. This is bad practice, though. It is better to always specify the exact columns you need.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to copy all data from one database to another which has the
Im trying to copy over data from one table to another in the same
I have a task of copying the data from one database to another.I don't
I need to copy data from one database to another with EF. E.g. I
I need to use PHP to copy data from one MySQL database to another.
I have two databases. I want to dump data from one table in 1st
i want copy pdf file from application path(/data/data/package name) to sdcard.for that i have
I have a table in one database, call this db x. I have another
In django, I want to copy data from identical tables in one db to
This topic is related to Copy missing rows from one table to another in

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.