Hello,
I have a website and it is designed to use relational database and now i want to give up that and use the Table storage of windows azure. lets say it is social website where you post on your friends walls (i will call the post "Status") and comment on each
Status. so the database was like this
User(ID, Name ... ), Status (FromID, ToID, Subject, ... ) , Comment (ID, StatusID, Subject ... ).
so the status belongs to two users, the one who submits it, and the one who has it on his wall.
now that i want the table storage i thought to put everything in one table for Users partitioned by the ID of the user:
public class User
{
public Guid ID { get; set; }
public List<Status> Statuses { get; set; } // the statuses the user submits to others
....
}
while the Status class has the List<Comments> property to expose related comments.
but i thought that design is not really what i want, because i want when i open a friends page i get the statuses posted on his wall not the statuses he posted on other's walls. so i changed the design to be
public class User
{
....
public List<Status> Status { get; set; } // the statuses on this user's wall
....
}
then i thought what if in the future i want to have two tabs, one shows me what i have posted on others walls, and the other tab shows me what others have posted on my wall. so now how the partitioning like that will slow the website when i want to get the
statuses i have posted. another scenario is, say we have advertisign website where users can brows "Companies" and their "Products" and we have one table for Companies (class Company has List<Product>) partitioned by the Company ID. that will be fine
while the user is browsing. but when the user goes to search for a "Product" by the property "Color" this partition will slow down his search.
so what is the best partitioning design for these cases? if i am totally wrong in the design please guid me since it is my early days with azure.
another question is regarding to identifying rows. any other "simpler" solution than Guid to identify my rows? you know Guid look ugly and make the query string hard to read thus the URI hard to share if you want to have it printed on paper or so.
Thank You.
Alan-SY