given a list of facilityIds can I do a DB query and get a list of corresponding facility entities

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

given a list of facilityIds can I do a DB query and get a list of corresponding facility entities

Patrick-4
I have a list of facilityIds and I want the entities.   I know I could
put it in a for loop and do x number of database queries, but I was
hoping there was a faster way since I know that DB queries are the
bottleneck.  Thanks
Patrick
Reply | Threaded
Open this post in threaded view
|

Re: given a list of facilityIds can I do a DB query and get a list of corresponding facility entities

David E. Jones-2

Use the IN operator.

-David


On Apr 12, 2010, at 2:47 PM, Patrick wrote:

> I have a list of facilityIds and I want the entities.   I know I could
> put it in a for loop and do x number of database queries, but I was
> hoping there was a faster way since I know that DB queries are the
> bottleneck.  Thanks
> Patrick