It contains lots on Business Intelligence scenarios and solutions along with real problems regarding Microsoft Excel, SQL Server Reporting Services, SQL Server Integration & Analysis Services and various databases and also may contain other popular posts.

Thursday, 6 June 2013

Azure Blob Storage handling using c#

Window azure blob storage is a
service providing by Microsoft to store a large amount of unstructured data
into the cloud that can be accessed from anywhere via HTTP or HTTPS. A single
blob can be more than 100 GB in size and one blob account container can have
more than 100 TB in size.Common uses of the blob storage
are –

Serving images or files directly to a browser

Get distributed access of the data

Streaming Video/Audio file

Perform secure backup

On a recent application, we
implemented image uploading and downloading by using blob storage.As per the
requirement When user logs in to the application then he should be able to see
his profile picture and also he should be able upload the new picture for his
profile.

We will go through each operation
step by step and cover the following topics-

Downloading of an image from Azure Blob Storage

Uploading of an image to Azure

We implemented the
above both operations by using Jquery with WCF service by an Ajax call.For doing the above
both operation we need to have few values as mentioned below –

Storage account – This we can get while initially set-up the storage account in blob.
Let’s say tStorageAccount(just a variable name
for the reference).

Container
name – This is a container
which is created in blob for storing of files. Let’s say tBlob(just a variable name for the
reference).

Account key – Available in blob storage account. There is a clickable item ‘Manage
Keys’. Click on it, a dialog box will appear with account key. This is just a
long string of random characters.