Skip to content
Advertisement

Tag: mongotemplate

Get multiple RequestParam of one variable

I’m trying to build a multifunctional search method using MongoTemplate, Query and Criteria. Here is my RequestMapping for variable search: I want to be able to search lastName with multiple request parameters. For example, I want to find everyone with lastname “Smith” and “Johnson”. Something like this: URL will be: http://localhost:8080/get?lastName=Smith&lastName=Johnson This is where I found Mapping a Multi-Value Parameter

Mongo DB Aggregation with Count for Specific Conditions and filter by Date Range which Outputs a Projection Doesn’t work as Expected

Please consider that I’m a beginner to MongoDB and I need to retrieve data from MongoDB database in somewhat complex query format. I’ve referred several Questions and Answers published in the community but my expected query was much complex due to some complex counts operations for certain conditions etc. However I was able manage to retrieve the data to a

Spring boot aggregation with group Trim

Consider collection with whitespace in field, in DB if there is white space if we group them “Ravi”, ” Ravi ” , consider as total 2 values. but it should consider as single value. So I have trim in Group. I had performed in DB. But I don’t know how can I trim and group value in Springboot. We can

Advertisement