• I have to agree it is helpful to post the DDL create statements for the tables and include sample data in a consumable format

    the number depends on certain word

    This is where I am lost. If you have a table you let the table autogenerate a number. I assume this is the primary key column. Are you trying to have a key defined by a alphanumeric string?

    I think the insert statement mentioned gives you something good to work with. Though depending on how the data is stored you may have to use DISTINCT as in

    INSERT INTO table1

    ( SECTION )

    SELECT Distinct SECTION

    FROM table2

    WHERE NOT EXISTS ( SELECT *

    FROM table1

    WHERE table1.SECTION = table2.SECTION )

    ----------------------------------------------------