Through a webservice my application receives a list of identifiers. With this list, I have to look up a field, one per identifier. If the field does not exist, the value should be null (it has to be shown).
I am wondering what would be the best approach. First I thought it was best to create a temporary table holding the id's and then joining it to the table holding the data, but if I'm correct this takes at least 1 query per identifier to insert it in the temporary table. In that case, it seems that I could just as well iterate through the list of identifiers in my application and query the database 1 by 1. Is this correct? Which approach can you advise?
greetings,
coen