0

我有table1一列是主键,另一列是table22 列和 5 行。table1我需要根据行中的行进行批量插入table2并检索我需要用于另一个表 3 的插入行。有人可以帮助我吗?

表 2 -SourceItem

Sourceid SourceLocation SourceAmount Soucename Feedname
--------------------------------------------------------
1        London         3000         process   monthly
2        Swindon        2500         process   monthly
3        Bristol        500          process   monthly
4        Hatfield       1000         process   monthly
5        Leeds          3000         process   monthly

表格1:Grain

GrainID

我需要根据 sourceitem 表中的行数在 Grain 表中插入行,并且我需要检索我们插入的 GrainID 以便我可以在不同的表中使用插入的值

4

0 回答 0