Inserting item in order via SQL

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
7 anos atrás
I need to insert an item in new orders according to certain conditions via SQL (it's a Christmas gift to all orders from 15th November on).
I'd like to use a trìgger in Order table for insert, but the problem is that I don't know what to insert into OrderItemGuid field in OrderItem table.
Can anyone help me please?
Thanks a lot
7 anos atrás
Hi. You can use NEWID() T-SQL function to generate the ID.
7 anos atrás
Great, thank you very much!
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.