none
Table Storage reserved column names? A column named Payload is ignored after v2.0.6.1

    Question

  • Has something changed in the latest Azure Table Storage v2.0.6.1 regarding column names ?

    I have a Storage table with a column called Payload which has been fine since December, after upgrading to v2.0.6.1 this column is now ignored and is always empty on insert or update, indeed even if I create a totally new table with a column called Payload, it doesn't even show up.

    Renaming the column to say Payload2 works fine ...

    Anybody else have this issue?

    Ta

    D


    There's no right way ... but there may be a better way

    Wednesday, August 14, 2013 10:55 AM

Answers

All replies

  • I just tried it and everything worked perfectly fine. Here's the code I used:

    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;
    using Microsoft.WindowsAzure.Storage;
    using Microsoft.WindowsAzure.Storage.Auth;
    using Microsoft.WindowsAzure.Storage.Table;
    
    namespace TableStoragePayloadQuestion
    {
        class Program
        {
            static void Main(string[] args)
            {
                CloudStorageAccount storageAccount = CloudStorageAccount.DevelopmentStorageAccount;
    
                CloudTableClient client = storageAccount.CreateCloudTableClient();
                CloudTable table = client.GetTableReference("Test");
                table.CreateIfNotExists();
                var entity = new MyEntity()
                {
                    PartitionKey = "MyEntity",
                    RowKey = Guid.NewGuid().ToString(),
                    Payload = "This is a test payload",
                };
                TableOperation insertOperation = TableOperation.Insert(entity);
                table.Execute(insertOperation);
                Console.ReadLine();
            }
        }
    
        public class MyEntity : TableEntity
        {
            public string Payload
            {
                get;
                set;
            }
        }
    }
    
    I tried it in both storage emulator and against cloud storage and it worked fine at both places. Can you share the code?
    Wednesday, August 14, 2013 1:29 PM
  • Thanks Gaurav,

    My code is doing nothing different to your test.

    I tried in a separate console app and all is ok, just doesn't work in my project any more.

    I renamed my TableEntity column to PayloadContent and all is ok, just doesn't like Payload for some reason ..... wierd

    D


    There's no right way ... but there may be a better way

    Wednesday, August 14, 2013 4:51 PM
  • Hi Dev,

    I also give it a try and it is ok on my side.

    >> Has something changed in the latest Azure Table Storage v2.0.6.1 regarding column names?

    If you think the issue is related to new SDK, you can try to remove the references and re-add them. If there's no break changes(http://msdn.microsoft.com/en-us/library/windowsazure/dn407359.aspx ), re-reference the assemblies may solve the issue.

    Best Regards


    Jambor yao
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Thursday, August 15, 2013 6:43 AM
    Moderator