{
"_id" : ObjectId("5eb1116ed99e7c68395d479c"),
"sheets" : [
{
"Sheet1" : [
{
"headers" : [
"name,mobile"
],
"data_count" : 10
}
]
}
],
"name" : "2.csv"
},
{
"_id" : ObjectId("5eb1116ed99e7c68395d480c"),
"sheets" : [
{
"Sheet1" : [
{
"headers" : [
"name,mobile,mobile1,mobile2,email1,email2"
],
"data_count" : 30
}
],
"Sheet2" : [
{
"headers" : [
"name,mobile,mobile1"
],
"data_count" : 20
}
]
}
],
"name" : "1.csv"
}
I have multiple document in a collection so I will pass id and sheet name e.g. Sheet2 and I want to get the sum of data count for all the input id's and sheets
so suppose in above case my input is [{file_id:"5eb1116ed99e7c68395d479c", sheet_name:"Sheet1"}, {file_id:"5eb1116ed99e7c68395d480c", sheet_name:"Sheet2"}]
so output should be data_count is 30