INSERTING values from one table into another table

后端 未结 2 546
一生所求
一生所求 2021-01-16 13:03

I have this code to select all the fields from the \'jobseeker\' table and with it it\'s supposed to update the \'user\' table by setting the userType to \'admin\' where the

2条回答
  •  一生所求
    2021-01-16 13:35

    There's nothing obviously wrong with your code (apart from it being insecure with using non-escaped values directly from $_GET).

    I'd suggest you try the following in order to debug:

    1. var_dump $userData to check that the values are as you expect
    2. var_dump $rQuery and copy and paste it into phpMyAdmin to see if your query is not as you expect

    If you don't find your problem then please post back your findings along with the structure of the tables you're dealing with

提交回复
热议问题