[SERVER-17682] query on ireport for jasperreports Created: 21/Mar/15  Updated: 23/Mar/15  Resolved: 23/Mar/15

Status: Closed
Project: Core Server
Component/s: Aggregation Framework
Affects Version/s: None
Fix Version/s: None

Type: Question Priority: Major - P3
Reporter: Camilo Assignee: Unassigned
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Participants:

 Description   

i run an aggregation query in ireport and works fine, but when i run it on server returns null on fields. If i do this query with the equivalent with findQuery works fine and returns data. What's wrong with this?

{'collectionName' : 'tsin_integrantes',
 
    'runCommand':{
        aggregate:'tsin_integrantes',
 
        pipeline:[
 
            {$match : {'idPerson':'$P!{idPerson}'}}
 
        ]
}
}
}

but a simple query like this works fine:

{'collectionName' : 'tsin_integrantes',
 
    'findQuery' : {
    'idPerson': $P{idPerson}
    }
    }
 
 
}



 Comments   
Comment by Camilo [ 22/Mar/15 ]

solved, must make a projection with alias

Generated at Thu Feb 08 03:45:16 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.