Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 8372

Re: SELECT SINGLE VS SELECT UP TO 1 ROWS

$
0
0

I use SELECT UP TO 1 ROWS as a self-documenting code when I select without the full key specified.

 

Sometimes, it's just the way the table is designed (and maybe I can't change it) but I don't care, I just want the first row that meets the condition.

 

My intention is that if I were to read back the code at some point later, or some other poor soul have to figure out my code, I/they would know that I knowingly selected without the full key and ignored any possibility that a different row might have given a different result.


Viewing all articles
Browse latest Browse all 8372

Trending Articles



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