MySQL Forums
Forum List  »  General

Error 1242 Subquery returns more than 1 row .....But...there is no subquery?
Posted by: John Doe
Date: August 05, 2020 11:39AM

Hello There,

I have been using MySQL forever and a day...and I have never run into this issue before...I believe it is a table issue, but cannot seem to figure out why it is happening...so I have a very simple insert...

insert into reg_swap_history (`ca_id`, `imaw_num`, `phone_id`, `Remarks`, `switch_date`, `switch_by`) VALUES ('161111193', '56754000180690', '72', '56754000180690 is no longer valid', '2020-08-04', 'admin');

it errors out with a 1242 Subquery returns more than one 1 row...but the weird thing is there is no subquery??? it only seems to be happening to this one table. If I Insert a record via the GUI window display it displays the query it is about to run (I copied that) and then hit apply...goes in fine. I try to run the query the system showed before the system inserted the record:

INSERT INTO `registration`.`reg_swap_history` (`ca_id`, `imaw_num`, `phone_id`, `Remarks`, `switch_date`, `switch_by`) VALUES ('161111193', '56754000180690', '72', '56754000180690 is no longer valid', '2020-08-04', 'admin');

and it again gives me the same subquery error...using the same statement that it itself used...I dont think it is MySQL workbench, as this is affecting my php sql query as well....it looks to be the table itself.

Has anyone ever seen anything like this before? any help would be greatly appreciated.

Thanks
B

Options: ReplyQuote


Subject
Written By
Posted
Error 1242 Subquery returns more than 1 row .....But...there is no subquery?
August 05, 2020 11:39AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.