I have collection in MongoDB , what i want to do is to retrieve data in the cassandra , and export it into a csv file . what i want is to transform each row into a , comma seperated string and insert it each time in the csv file , i started to collect the data in the collection , any help fir the rest , am new to c#, lany thanks
var server = MongoServer.Create("mongodb://localhost:27017");
var DB = server.GetDatabase("shop");
var collection = DB.GetCollection<BsonDocument>("Mobiles");
var list = collection.FindAll();
foreach (var dox in list)
{
insert into the csv file
}
Thanks a lot