1

我有两个表:notificattins 和 users

我想为 users 表的每条记录插入一条记录到通知表中。

事实上,我想为每个用户添加一个通知。

谁能帮我?

4

1 回答 1

1

您没有指定表结构,但通常可以这样做

insert into notifications (some_column, other_column)
select username, other_column
from users
于 2013-07-27T12:01:14.940 回答