I have a field in an Azure table that holds date times in string format. I want to replace this with a DateTime field and convert the values in the string column. What’s the best way to approach this?
In a SQL I’d do this by creating a new column and run an update statement…
I haven’t tried this myself, but here are the steps that /should/ work. This needs to be a C#/VB/etc script.
//now your table storage contains objects with new and old definition of that variable
Now, if you want the new datetime field to take the name of the original string variable do steps 1 thru 5 again, this time moving the data from one field into another. The only difference is that you don’t have to do conversion again.
In general, this is a complete PITA and one of the banes of object databases and storage services.