c# - string array -> longId array in a SQL statement -


I'm getting a string from HttpContext.Current.Request ["key"] that I split (', ') If this is not empty.

Now I would like to write a SQL statement to delete any msgId (long / int64) that matches keys, how should I write it? The only way I want to convert uncensored [] string to long [] long, then loop a SQL statement. Is there a better way?

PS: Using SQL ATMs, but switching to another SQL engine. (I have chosen the server yet, so I do not know)

  table WHERE id Remove from IN (1,2,3, keys)  

Will it have to do?


Comments