Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Creating a Lottery Application

New Here ,
Jul 21, 2008 Jul 21, 2008
Hi all,
I am trying to create a lottery application using coldfusion and oracle but so far have had no luck. Has anyone developed such an application and if so could you please direct me in the right direction. The primary purpose of the Lottery is to select all applicants from a table then randomly select a few winners from all applicants based on the number of prizes available.

Your help will be greatly appreciated.

Thank you
TOPICS
Getting started
597
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 21, 2008 Jul 21, 2008
LATEST
My approach would be:

Select the count from the table, not all the records. I'm not sure, but you might have to add 1 to this number to make the last record eligible.

Use randrange to get your random numbers.

Select the records where the row number corresponds to those numbers. If you google "oracle row number" you should find the necessary sql.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources