bitScry

  • Home
  • About
  • Blog
  • Contact

DataTable

About this site

This is a blog to help me remember some of the coding challenges I’ve faced and hopefully help others out if they’re suffering the same problems.

Recent Posts
  • Killing a Process Locking Port on a Mac
  • Mocking Hangfire BackgroundClient Jobs
  • Running Shinobi CCTV on a Raspberry Pi
  • Visual Studio CoreCLR Error
  • Adding Healthchecks to a .NET Core 6 API
Tag Cloud

.NET Core AAD API ASP.NET Core Authentication Authorization Azure Azure Active Directory Azure Function Azure Storage Blob Bootstrap C# Cloud Storage Console Application CSS DataTable Dependency Injection Dictionary Entity Framework Enum Extension Google GZip HTML IP Address JavaScript jQuery JSON List MVC MVC 6 Newtonsoft RestSharp Serilog SQL SSDT Stored Procedure Stream String Table Table Storage Web App Web Application WordPress

Programming

Data Transfer – Google Cloud Storage to SQL

In order to transfer data from a Google BigQuery table into SQL I first export it to Google Cloud storage and then stream it directly into into my SQL table using SqlBulkCopy and a modified version of the CsvDataReader from CsvHelper. This post demonstrates how to load data from Google Read more…

By Shinigami, 3 years30 December 2019 ago
Programming

Using CsvHelper to Write a DataTable to a Blob

CsvHelper is handy for reading and writing CSV files but there’s no obvious way to write out a DataTable to a CSV file. Therefore in order to do this we need to loop through all the rows and columns of the DataTable and write the values as individual fields as Read more…

By Shinigami, 3 years13 August 2019 ago
Programming

Using SQL Task Results in a Script Task in SSDT

In SSDT if you want to access the results of a SQL query in a script task you can do this by outputting the results as a full result set into a variable of type Object and then load this into a DataTable within your script task. It’s also possible Read more…

By Shinigami, 4 years15 August 2018 ago
Programming

Thread Safe DataTable Inserts and SqlBulkCopy

As part of a project where I was running multiple threads making API calls like this I was making a stored procedure call to log the results to an SQL database for each result returned. This worked fine when a low number of threads was used but then started to Read more…

By Shinigami, 4 years27 April 2018 ago
Programming

Checking for CSV Column Headers in C#

Importing CSV files into a .NET object isn’t too tricky and for this I usually use CsvHelper. However, sometimes I need to import a CSV file and only extract a couple of columns from it and these columns aren’t always guaranteed to exist. In order to do this I use Read more…

By Shinigami, 5 years26 January 2018 ago
  • Facebook
  • Twitter
  • Instagram
  • Email
Hestia | Developed by ThemeIsle