• hum...

    That's really weird: For 10 ip, it takes 7-8 seconds. For 100, it takes about a minute which is slower than my problem at the beginning.

    BUT!

    If I try with 40 or 50 ip, it executes in a flash: 1 second!

    The difference is in uses table spool (lazy spool) in the first case but only clustered index seek in the second case.

    What the ...???

    By the way, in the prod environment, it's going to be up to 1000 ip.

    Stephane