Another Random Record Selection Method

By Bill Graziano on 06 January 2002 | 0 Comments | Tags: Randomness


Dutch submitted "Yet an other method to random select a records from a database. However this method does not use a temporary table, which has a lot of overhead when you're dealing with large tables." Follow the link to Another Random Record Selection Method...

Discuss this article: 0 Comments so far. Print this Article. This page has been read 11,405 times.

If you like this article you can sign up for our newsletter. We send it out each week that we post a new article. There's an opt-out link at the bottom of each newsletter so it's easy to unsubscribe at any time.

Email Address:

Email ThisSubscribe to this feedKick itSave to del.icio.usView blog reactions

Related Articles

Using NEWID to Randomly Sort Records (16 April 2002)

Multiple Random Records w/Single Select (4 October 2000)

Returning a Single Random Row (27 September 2000)

Returning Rows in Random Order - Part III - Practical Applications (12 September 2000)

Returning Rows in Random Order - Part II - Revenge of the Randomizer (11 September 2000)

Other Recent Forum Posts

Help in query !!!!! Help!! (18 Replies)

Strange issue with foreign key (0 Replies)

can a fun have out paramter (2 Replies)

How to Compare DATETIME data with null values (2 Replies)

compare of 2 big tables (7 Replies)

complicated update (problem) (4 Replies)

Database consistency problem detected on database (1 Reply)

help needed in get date from datetime (5 Replies)

Subscribe to SQLTeam.com

Weekly SQL Server newsletter with articles, forum posts, and blog posts via email:

SQLTeam.com Articles via RSS

SQLTeam.com Weblog via RSS

- Advertisement -

- Sponsor's Message -

SQLShare.com Videos

Writing to the Registry from TSQL Using XP_Instance_RegWrite

Reading from the registry to figure out a configuration issue or two is common, but writing to the registry isn't something you'll need to do very often. Still, it's a useful trick to know and we've put it to work showing you how to alter the default folder used for database backups.

Using XP_Instance_RegRead To Get Default Database Path

SQL saves more than a few things to the registry and we can leverage that by reading those settings from TSQL using xp_instance_regread. Easy to use and only one minor quirk to learn, and you'll reading from the registry. Look for the follow up video that demonstrates how to write changes to the registry too.

How to Change the Default Path for New Databases

Typing CREATE DATABASE MyDB gets the job done, but it puts the files in whatever location has been set as the default - which means you should make sure the default is set to a good place, or specify them as part of the CREATE. We'll show you how to adjust the setting (and we've got a video coming up that shows you how to change it from code too!).

Overview of Data Driven Subscriptions in Reporting Services

Subscriptions are a powerful feature of Reporting Services because they allow users to decide which reports to receive. But what do you do when the boss wants a report sent to a group of users, perhaps based on some additional criteria that frequently changes? That's where data driven subscriptions make sense and in our lesson today Devin does a nice overview of the options and requirements.

Using DatePart and DateName

Ever want to get the month out of a date as a number, or as literal text? Many people will do it by parsing the date as a string, but we've got some built in functions that will do it cleanly and consistently.