Hi,
I have a document as below.
db.QtrPatchesNew.insert(
{
"Qtr": "Jan2016",
"Patches": [ 21948347, 21948348, 21948355] ,
"PatchScripts": [ { "1": "script1.ksh" , "2": "script5.ksh" , "3": "script6.ksh" } ]
}
)
If i executed find command i get details as follows.
> db.QtrPatchesNew.find( {"Qtr": "Jan2016"}, { "PatchScripts": 1, "_id": 0 } ).pretty()
{
"PatchScripts" : [
{
"1" : "script1.ksh",
"2" : "script5.ksh",
"3" : "script6.ksh"
}
]
}
>
Could you please someone help me print output like
1:script1.ksh
2:script5.ksh
3:script6.ksh
Appreciate your help.
Thanks in advance.
Jaison