0

I want something that achieves a simmilar effect to passing the text of a stored proc to SQL Server and then executing it?

For example to set identity_insert and then insert a value

1 Answer 1

1

You mean something like this?

context.Database.ExecuteSqlCommand("INSERT INTO....");

This can take multiple commands if you wish.

Sign up to request clarification or add additional context in comments.

2 Comments

Maybe. Can you execute multiple sql commands in sequence using that? i.e to set indentity_insert then to do the insert
@kirsteng i believe so yes

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.