Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

6
  • please complete your example code. where is bulkCopy Commented Jun 1, 2018 at 14:06
  • 3
    It is already here: await bulkCopy.WriteToServerAsync(table); Commented Sep 5, 2018 at 13:43
  • Maybe i wasn't clear, in your write up, you suggest you made an extension...which i took to mean that no 3rd part lib was needed, when in fact in both methods use SqlBulkCopy lib. This entirely relies on SqlBulkCopy, when why i asked where does bulkCopy come from, its an extension lib which you wrote an extension lib on top of. Would of just made more sense to say here is how i used SqlBulkCopy lib. Commented Sep 12, 2018 at 14:29
  • should use conn.OpenAsync in async version Commented Jan 14, 2019 at 8:41
  • 1
    @SOHODeveloper Yes, you are correct. This code uses Entity to gather information about the table and column names, and then generate a "default" bulk insert that can be used with SqlClient.SqlBulkCopy. Commented Jun 18, 2020 at 16:40