Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

MongoDB $in with $and Query in Java

 
Charlie Green
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is this type of query possible?

I need to query the database for data for a specified date for a set of specified stocks. So the data needs to have "this" date and be one of "these" symbols.

I have the following code:


This always comes up null. Can someone explain how to make a query like this work?
 
Charlie Green
Greenhorn
Posts: 6
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I found a solution in case anyone else needs to do something similar:

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic