How to determine the same numbers in visual basic

Please support our Visual Basic 4 / 5 / 6 advertiser: Programming Forums - DaniWeb Sister Site
Reply

Join Date: Aug 2007
Posts: 47
Reputation: locsin is an unknown quantity at this point 
Solved Threads: 0
locsin locsin is offline Offline
Light Poster

How to determine the same numbers in visual basic

 
0
  #1
Apr 6th, 2009
Greetings!

Anybody have idea how the determine the same numbers in 100 records. For example there are 100 inputted numbers in the database file. These numbers, some numbers have the same value.

Anyone know to determine these numbers and display like this.

input
100 numbers inputted in the database file


sample output.

Number ...................... total number with the same value
34 ............................... 20
2 .............................. 15
78 .............................. 36
5 .............................. 9
17 .............................. 11
56 .............................. 8
3 .............................. 1

the numbers from the left is the inputted numbers in the database file. and the numbers from the right is the total of how many times these numbers were inputted or total numbers with the same value.

Thanks in advance.
Last edited by locsin; Apr 6th, 2009 at 2:56 am. Reason: to improve screen display
Reply With Quote Quick reply to this message  
Join Date: Feb 2007
Posts: 2,146
Reputation: debasisdas will become famous soon enough debasisdas will become famous soon enough 
Solved Threads: 132
debasisdas's Avatar
debasisdas debasisdas is offline Offline
Postaholic

Re: How to determine the same numbers in visual basic

 
0
  #2
Apr 6th, 2009
What about simply using a COUNT on the database table !!!

something like the following

  1. SELECT num,count(num) FROM table_name GROUP BY num
Last edited by debasisdas; Apr 6th, 2009 at 4:25 am.
Share your Knowledge.
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the Visual Basic 4 / 5 / 6 Forum


Views: 271 | Replies: 1
Thread Tools Search this Thread



Tag cloud for Visual Basic 4 / 5 / 6
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC