Windows Azure – How to migrate data from SQL Server to a Storage account

Starting from this great article https://azure.microsoft.com/en-gb/documentation/articles/storage-dotnet-how-to-use-tables/ we started by including the required imports:

using Microsoft.WindowsAzure.Storage;
using Microsoft.WindowsAzure.Storage.Auth;
using Microsoft.WindowsAzure.Storage.Table;
using System.Configuration;
using System.Data.SqlClient;

Continue reading “Windows Azure – How to migrate data from SQL Server to a Storage account”

Advertisements

Windows Azure storage tables – How to delete a table in C#

Namespace declarations

Add the following code namespace declarations to the top of any C# file in which you wish to programmatically access Azure Storage.

using Microsoft.WindowsAzure.Storage;
using Microsoft.WindowsAzure.Storage.Auth;
using Microsoft.WindowsAzure.Storage.Table;

 try
            {
                // Retrieve the storage account from the connection string.
                CloudStorageAccount storageAccount = CloudStorageAccount.Parse(
                        ConfigurationManager.AppSettings["StorageConnectionString"]);

                // Create the table client.
                CloudTableClient tableClient = storageAccount.CreateCloudTableClient();

                // Create the table if it doesn't exist.
                //Table names must be unique within an account.
                //Table names may contain only alphanumeric characters.
                //Table names cannot begin with a numeric character.
                //Table names are case-insensitive.
                //Table names must be from 3 to 63 characters long.
                //Some table names are reserved, including "tables". Attempting to create a table with a reserved table name returns error code 404 (Bad Request)..
                string strTableName = txtClientDB.Text.Trim().Replace("_", "") + "erp";
                strTableName = strTableName.ToLower();
                CloudTable table = tableClient.GetTableReference(strTableName);
                // Delete the table it if exists.
                table.DeleteIfExists();
                lblSuccess.Text = "Delete succeeded";
                lblSuccess.Visible = true;
            }
            catch (Exception ex)
            {
                lblError.Visible = true;
                lblError.Text = ex.Message;
            }

https://azure.microsoft.com/en-gb/documentation/articles/storage-dotnet-how-to-use-tables/

Offsite Backup Advantages

Western Digital My Book Storage Option
Western Digital My Book Storage Option

Creating backups of your data and files is a very important way of staying on top of disaster and missing data. Both small and large businesses, including individuals, always look towards a backup of information to keep them going in the face of disaster. Even though backups are a great way to keep your data safe and protected, there are some flaws with the traditional methods.

When you create backups of your data, you must store them somewhere where they can’t be damaged or someone else can access them. For businesses, offsite backup is a well known and popular way to backup files. It offers you several different advantages when compared to other ways, such as BluRays, DVD, external hard drives, and even servers. One of the biggest advantages to offsite backup is the fact that the backups aren’t stored in your office or business.

Offsite backup companies store your data in state of the art safes, to protect them against fire, flood, and even prying eyes. This can be extremely beneficial if unexpected things have a habit of occurring around your office.

Another great thing about offsite backups are the fact that they can be used as stores for your data. You won’t need to rely on online space, as you can easily go to the company who is storing your data and go through it anytime you wish. You can also use online space with most companies as well. You simply upload your data to their online storage area, then go back anytime you wish and view it. This is a very handy feature, similar to a hosting company.

Another benefit of offsite backup is the fact that your data will always be protected, and you won’t have to use CD or DVDs to do it. CD and DVD storage is great for individuals, although there will be quite a bit of them for most businesses. This can get somewhat costly, but more importantly, it will use a lot of space to store the backup files. They can also become damaged or lost, unlike offsite backup storage.

Offsite storage is also great if your business is in a bad area. If Mother Nature has a habit of bashing your area with floods, fires, or hurricanes, you should look into offsite backup storage immediately. They have ways to protect your information from harm, including anything Mother Nature can dish out. There is no need to worry about natural disasters, system failures, hard drive crashes, or data failure with offsite backup storage.

Even though you may not realize it, the data will be available anytime you need it. Online backup services are available anytime, day or night, and can be accessed anywhere you are. Most are easy to set up, and offers you very impressive security measures. They are also fast and very efficient, which is great for those who need to access their files immediately.

When it comes to offsite backup, you can store virtually any file you need to, such as text files, e-books, contact record, pictures, music, and anything else you can think of. The storage for online backups are virtually endless, capable of storing everything you need.

All in all, offsite backup storage is ideal for any business or corporation. You can store your data with an online offsite backup, or choose to do it physically in an offsite safe. The choice is entirely up to you. No matter which method of offsite backup you choose – your data will always be protected, and best of all – it will always be there anytime you need it.