i decided to use mongo db for product catalog : mongo db product catalog ecosystem
hi i want to use mongdo db for product catalog but i have question ? i have a website for selling second hand products in 100 categories and all of my fields is selective means if user want to sell vehicles he should choose brand like "bmw,toyota" not directive
so for saving all details in one document if after 2 years or 3 years toyota should be change to toyooota and my records go ver 20 million records i should update all toyota too toyootas yeah ? so it update command is expensive for that data ,
so another way its key value be in another collection like 1:bmw 2:toyota
so make a realtion between the documents and if one day we decide to change toyota to tooyoota we only change 1 record not entire collection ?
so what you prefer huge update on big data ,
or make a relation between product catalog details and another collection for key value
and then in details we say
{
title:"a good vehicle"
details:{
brand:"1" // means bmw, if we decide to change bmw name we should change brand name in another collection
}
}
and another way is
{
title:"good vehicle",
details:{
brand:"bmw" // if one day we want to changes all bmw to bmwn for example, then we need a huge update
}
}
notice:that values are selective by users they cant input directly their brand names like ebay ,
what u prefer for this design in mongodb?