Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 553
Default HIERARCHIAL COUNTING (Please Help Urgently)

Can anyone please help me in developing a a single/same formula in "C" that
could count the total linked cells. Lets take an example, "A" represents
Executives, "B" represents their Heads and "C" should be reflecting the span
of total control over the staff strength:

A B C
P - 17 (4 VPs, 6 AVPs, 6 Officers & 1 Asst.)
VP1 P 9 (3 AVPs, 5 Officers & 1 Asst.)
VP2 P 3 (2 AVPs & 1 Officer)
VP3 P 1 (1 AVP)
VP4 P 0 (No subordinate)
AVP1 VP1 3 (2 Officers & 1 Asst.)
AVP2 VP1 2 (2 Officers)
AVP3 VP1 1 (1 Officer)
AVP4 VP2 1 (1 Officer)
AVP5 VP2 0 (No subordinate)
AVP6 VP3 0 (No subordinate)
Officer1 AVP1 1 (1 Asst.)
Officer2 AVP1 0
Officer3 AVP2 0
Officer4 AVP2 0
Officer5 AVP3 0
Officer6 AVP4 0
Asst.1 Officer1 0

Please Urgent Help is required!

Kindly, note that the rows may be in any order.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,081
Default HIERARCHIAL COUNTING (Please Help Urgently)

This sort of problem is discussed frequently in the SQL Server/Transact SQL
newsgroup, because it is non-trivial and requires recursive routines that
traverse the hierarchy tree and execute queries at eachnode. As such, it is
something far better handled by a database.

You may want to look at this link for a generic description of what's
required in SQL

http://www.vbmysql.com/articles/data...data-in-mysql/

"FARAZ QURESHI" wrote:

Can anyone please help me in developing a a single/same formula in "C" that
could count the total linked cells. Lets take an example, "A" represents
Executives, "B" represents their Heads and "C" should be reflecting the span
of total control over the staff strength:

A B C
P - 17 (4 VPs, 6 AVPs, 6 Officers & 1 Asst.)
VP1 P 9 (3 AVPs, 5 Officers & 1 Asst.)
VP2 P 3 (2 AVPs & 1 Officer)
VP3 P 1 (1 AVP)
VP4 P 0 (No subordinate)
AVP1 VP1 3 (2 Officers & 1 Asst.)
AVP2 VP1 2 (2 Officers)
AVP3 VP1 1 (1 Officer)
AVP4 VP2 1 (1 Officer)
AVP5 VP2 0 (No subordinate)
AVP6 VP3 0 (No subordinate)
Officer1 AVP1 1 (1 Asst.)
Officer2 AVP1 0
Officer3 AVP2 0
Officer4 AVP2 0
Officer5 AVP3 0
Officer6 AVP4 0
Asst.1 Officer1 0

Please Urgent Help is required!

Kindly, note that the rows may be in any order.

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1,081
Default HIERARCHIAL COUNTING (Please Help Urgently)

As an alternative to SQL, but requiring a fair amount of coding in VBA or
perhaps VB Express, would be to use your data to populate a Windows Treeview
control, then use the Treeview's methods to count the nodes subordinate to
each node in your table.

Any way you look at this, it is a somewhat complicated task


"FARAZ QURESHI" wrote:

Can anyone please help me in developing a a single/same formula in "C" that
could count the total linked cells. Lets take an example, "A" represents
Executives, "B" represents their Heads and "C" should be reflecting the span
of total control over the staff strength:

A B C
P - 17 (4 VPs, 6 AVPs, 6 Officers & 1 Asst.)
VP1 P 9 (3 AVPs, 5 Officers & 1 Asst.)
VP2 P 3 (2 AVPs & 1 Officer)
VP3 P 1 (1 AVP)
VP4 P 0 (No subordinate)
AVP1 VP1 3 (2 Officers & 1 Asst.)
AVP2 VP1 2 (2 Officers)
AVP3 VP1 1 (1 Officer)
AVP4 VP2 1 (1 Officer)
AVP5 VP2 0 (No subordinate)
AVP6 VP3 0 (No subordinate)
Officer1 AVP1 1 (1 Asst.)
Officer2 AVP1 0
Officer3 AVP2 0
Officer4 AVP2 0
Officer5 AVP3 0
Officer6 AVP4 0
Asst.1 Officer1 0

Please Urgent Help is required!

Kindly, note that the rows may be in any order.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
COUNTING HIERARCHIAL LINKS (URGENT PLEASE) FARAZ QURESHI Excel Discussion (Misc queries) 2 September 10th 07 11:52 AM
Urgently need help with a formula!!! [email protected] Excel Discussion (Misc queries) 2 September 27th 06 10:09 PM
Need your help urgently Calculate Date range Excel Worksheet Functions 1 August 2nd 06 12:25 PM
How do I have hierarchial drop down lists in Excel Kunal Excel Worksheet Functions 2 March 20th 06 04:08 PM
Help Please Urgently, Please Giffy Excel Discussion (Misc queries) 1 September 5th 05 10:44 PM


All times are GMT +1. The time now is 11:03 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"