Hello guys,
I would like to try out something but I don't know if it is possible.
Here's my idea.
I have an EMPLOYEES table with quite a few fields, such as NAME, AGE, ADDRESS, etc etc, and an EMPLOYEE_NUMBER, which is created automatically (it increments by one for the next employee in the DB) and it is used as a primary key.
All the employees also have an EMPLOYEE_ID (also unique for every single one of them).
The thing is that this DB is not up to date, so I have to import the new employees from another DB and eventually update the existing profiles.
The problem is that in source database, I have the unique EMPLOYEE_ID but I don't have the EMPLOYEE_NUMBER.
So the question is, how do I import the new employees, generating a new EMPLOYEE_NUMBER for every single one of them?
Can this be done in the query?
(As far as I can see, updating is pretty easy, I have an INNER_JOIN on both tables and I update the existing fields, but adding a new record is not that simple for me)
Thank you for your time, be sure you help is much appreciated