HiI have two tables.
tbl1
id int(11) NOT NULL
positionName varchar(20) NULL
positionId int(11) NULL
tbl2
positionId int(11) NOT NULL
positionName varchar(20) NULL
Originally, there is no column positionId in tbl1. Now will use positionId instead of positionName for tbl1.
The problem is there are over thousands of data already stored in both tables.
So, How can I successfully and quickly link to the correct positionId for the each data of tbl1 , in which positionName was previously used?
Is batch updating is a way?
Is there anyway that I can perform all things with SQL browser? If possible, I don’t want to use coding.
Thanks ahead.
Are you looking for a multiple-table
UPDATE, like this?I’m assuming that
positionNameis unique intbl2, but if it isn’t, you’ll need to consider how you wish to handle that.