Mongodb SQL - How to put a default where clause like 1=1 -


i put default clause below.

select * emp_table  ( emp_name in (<emp_list_selected_from_api>) or ('all') in (<emp_list_selected_from_api>) ) 

here "all" default filter, using above query, can keep displaying employees, unless specific selected using filter. how write such query in mongodb.


Comments

Popular posts from this blog

Sort a complex associative array in PHP -

vb.net - How to ignore if a cell is empty nothing -

recursion - Can every recursive algorithm be improved with dynamic programming? -