Quantcast
Channel: Robust Parameters
Viewing all articles
Browse latest Browse all 5

Robust Parameters

$
0
0

Hi,

There too many ways to achieve your goal. One of them would be to use UNION

SELECT blah, blah

FROM MyTable

WHERE (your criteria for anonymous) AND (@parameter = 'anonymous' OR @parameter = 'all')

UNION

SELECT blah, blah

FROM MyTable

WHERE (your criteria for named user) AND (@parameter = 'named' OR @parameter = 'all')

 

 


Remember to mark as an answer if this post has helped you.

Viewing all articles
Browse latest Browse all 5

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>