I am trying to insert data into an Azure table, but everything is converted to rows.
eg. I insert numbers / booleans
var test={ PartitionKey : '4', RowKey : '2', foo: 4, bar: true }; tableService.insertEntity('mytable', test, ...);
but
tableService.queryEntity('mytable', '4', '2', ...);
returns
{ id: 'http://127.0.0.1:10002/devstoreaccount1/identid(PartitionKey=\'4\',RowKey=\'2\')', link: 'identid(PartitionKey=\'4\',RowKey=\'2\')', updated: '2012-12-12T10:26:44Z', etag: 'W/"datetime\'2012-12-12T10%3A26%3A44.547Z\'"', PartitionKey: '4', RowKey: '2', Timestamp: '2012-12-12T10:20:44.897Z', foo: '4', bar: 'true' }
How can I specify a data type?
OK, just saw in the SDK that you can specify the data type with
var test={ PartitionKey : '4', RowKey : '2', foo: { '@': { type: 'Edm.Int32' }, '#': 4 } };
however, are there any helper functions for automatically adding a type?