February 06, 2012

Search Procedure results without getting any data

Today a junior developer was having an issue where he was to
research a store procedure to extract a few 10k records from 
the database,however, each time he ran the procedure he was 
getting a timeout because his criteria was too abroad.Eventually,
he ask me "How can I see all the columns returns by the procedure?"
by that time he didn't care about the data,So I said to him 
SET FMTONLY ON
that's the fastest way to see the return from any query or procedure
without getting any data.SEE MAGIC.... 

No comments:

Post a Comment

Contact Form

Name

Email *

Message *