I am trying to insert ID field from one table to another using below query:
INSERT INTO `srikprag_db`.`acbalance`
SELECT `id` FROM `srikprag_mlm`.`member_table`
Error is showing:
#1136 - Column count doesn't match value count at row 1
What is the reason for this error?
You did not define the destination column on where the values from the SELECT
statement will be saved, eg.
INSERT INTO srikprag_db.acbalance (ID) -- <<== destination column
SELECT id
FROM srikprag_mlm.member_table
probably you want to manipulate records across database.
The problem is with your query you are not assigning any value to the column. You have 1 column with zero value.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With