473,395 Members | 1,554 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

SEEKING KNOWLEDGE OF MS ACCESS AND DATABASE

I'm a beginner of MS Access, I need adequate knowledge on how to
programme. I have a challenge in my office to write a pragramme that
will calculate a compensation for all our distributors. This is a
network marketing company that has so many distributors, and almost
all the distributors are introduced by one distributo or other.

For example:
Mr. A introduce Mr. B,
Mr. B introduce Mr. C,
And Mr. C introduce Mr. D.
Mr. A has succeeded in having one (one) direct Downline and 2 (two)
indirect downlines.

The Challenge I have is the Hierarchy, calculating the compensation
and reporting how much are we paying all the distributors in a
particular month.

Thanks!

Nov 15 '07 #1
3 1589
If you are a beginner, the only way you will get this to work is to talk to
others in your organization, find out what software they are using, and buy
it. It would take you at least 2 years of part time tinkering to develop
this in Access.

If you want a starting point, you need all the people in the one table, with
a self-join to the other record for the person who introduced them. For an
introduction to self-joins, see this article:
Self Joins: tables that look themselves up (Pedigrees example)
at:
http://allenbrowne.com/ser-06.html

Once you have that idea down, you will want to know how to query this.
There's a downloadable example here:
Bill Of Materials
at:
http://www.mvps.org/access/modules/mdl0027.htm

For more advanced approaches, search for Celko's material. Here's a starting
point:
http://www.intelligententerprise.com/001020/celko.shtml
http://www.dbmsmag.com/9603d06.html
http://www.dbmsmag.com/9604d06.html
http://www.dbmsmag.com/9605d06.html
http://www.dbmsmag.com/9606d06.html

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

<pe*************@gmail.comwrote in message
news:8d**********************************@e4g2000h sg.googlegroups.com...
I'm a beginner of MS Access, I need adequate knowledge on how to
programme. I have a challenge in my office to write a pragramme that
will calculate a compensation for all our distributors. This is a
network marketing company that has so many distributors, and almost
all the distributors are introduced by one distributo or other.

For example:
Mr. A introduce Mr. B,
Mr. B introduce Mr. C,
And Mr. C introduce Mr. D.
Mr. A has succeeded in having one (one) direct Downline and 2 (two)
indirect downlines.

The Challenge I have is the Hierarchy, calculating the compensation
and reporting how much are we paying all the distributors in a
particular month.

Thanks!
Nov 15 '07 #2
On Nov 15, 3:29 am, "perfectclick...@gmail.com"
<perfectclick...@gmail.comwrote:
I'm a beginner ofMSAccess, I need adequate knowledge on how to
programme. I have a challenge in my office to write a pragramme that
will calculate a compensation for all our distributors. This is a
network marketing company that has so many distributors, and almost
all the distributors are introduced by one distributo or other.

For example:
Mr. A introduce Mr. B,
Mr. B introduce Mr. C,
And Mr. C introduce Mr. D.
Mr. A has succeeded in having one (one) direct Downline and 2 (two)
indirect downlines.

The Challenge I have is the Hierarchy, calculating the compensation
and reporting how much are we paying all the distributors in a
particular month.

Thanks!
Just found this challenge!
You could start with this 2 table solution:
1. Table of people (tPeople)
Fields: ID (autonumber/primarykey), Name
2. Table of Introductions (tIntros)
Fields: ID (autonum/primarykey), IntroducerID (Long integer
pointing to tPeople's ID), IntroduceeID (same), Date, ynDirect (Yes/
No), Amt
Note: Right in the table design, you can have the drop-down list
of People appear for the 2 foreign keys.
This approach doesn't have the smarts to automatically set the
ynDirect to Yes or No based on examining other records but at least
you can enter it and report on it.
Maybe after a few years of practice you can do the code for that :)
Many ways of calculating the compensation.
You could have an update query fill in the Amt column with
IIf(ynDirect, <RateforYes>, <RateforNo>)
You can have the report calculate the amount in the same way without
using any Amt field (However when it comes to money, it should be set
right away so as to avoid problems with changing rates or rules.)
Or you could make a look up table with the two rates that is related
to tIntros thru ynDirect.

David, Access Application Developer
PS:
I love Lyle's philosophical answer, too.

Nov 18 '07 #3
On Nov 18, 12:55 am, david12 <davidste...@yahoo.comwrote:
On Nov 15, 3:29 am, "perfectclick...@gmail.com"

<perfectclick...@gmail.comwrote:
I'm a beginner ofMSAccess, I need adequate knowledge on how to
programme. I have a challenge in my office to write a pragramme that
will calculate a compensation for all our distributors. This is a
network marketing company that has so many distributors, and almost
all the distributors are introduced by one distributo or other.
For example:
Mr. A introduce Mr. B,
Mr. B introduce Mr. C,
And Mr. C introduce Mr. D.
Mr. A has succeeded in having one (one) direct Downline and 2 (two)
indirect downlines.
The Challenge I have is the Hierarchy, calculating the compensation
and reporting how much are we paying all the distributors in a
particular month.
Thanks!

Just found this challenge!
You could start with this 2 table solution:
1. Table of people (tPeople)
Fields: ID (autonumber/primarykey), Name
2. Table of Introductions (tIntros)
Fields: ID (autonum/primarykey), IntroducerID (Long integer
pointing to tPeople's ID), IntroduceeID (same), Date, ynDirect (Yes/
No), Amt
Note: Right in the table design, you can have the drop-down list
of People appear for the 2 foreign keys.
This approach doesn't have the smarts to automatically set the
ynDirect to Yes or No based on examining other records but at least
you can enter it and report on it.
Maybe after a few years of practice you can do the code for that :)
Many ways of calculating the compensation.
You could have an update query fill in the Amt column with
IIf(ynDirect, <RateforYes>, <RateforNo>)
You can have the report calculate the amount in the same way without
using any Amt field (However when it comes to money, it should be set
right away so as to avoid problems with changing rates or rules.)
Or you could make a look up table with the two rates that is related
to tIntros thru ynDirect.

David,AccessApplication Developer
PS:
I love Lyle's philosophical answer, too.
Actually I should mention that you should use a different name than
"Date".
Maybe it would be dtIntro or IntroDate for date of introduction.

Also wanted to mention that this solution shows something about
letting users to do their share of thinking.
In this case it's real easy for a human to pick whether direct
introduction or not (assuming they have that knowledge handy - if not,
simply list all other introduction records for that introducer for the
user to examine.)
That leaves Access to do what it's good at, namely record keeping. In
this case it can behave much like any compensation application.
Which reminds me, you should have a payment table, too. Or at least a
yes/no field in tIntros table for whether that intro was compensated.
The Payment table would have fields: IntroID (foreign key pointing to
ID of tIntros), PayDate, Amt

Good luck!
David Stelle
Nov 18 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: aum | last post by:
Hi, I'm looking for an object-relational layer, which can wrap a MySQL database into highly pythonic objects. There seem to be dozens of packages which provide some of this functionality, but...
0
by: John MacLeod | last post by:
I'm stumped... If anyone here considers themselve's knowledgeable about databases & sql, and is open to a challenge, I would truly appreciate their help. I have a fairly limited knowledge of...
5
by: chanchito_cojones | last post by:
hi there, I am quite interested in making the move from Access to MySQL. I have grabbed all the software that is needed (MySQL, MySQL Control Center, MaxDB, etc.) and have installed it all...
1
by: Yasso Picasso | last post by:
Greetings, I have to admit that I'm still a beginner in the database field, but I'm actively studying, and this is why I will be utterly grateful for the proper, accurate, and wise guidance to...
5
by: clintonG | last post by:
I'm looking for documentation and would not turn my nose up to any code from anybody who thinks they are good at the design of an algorythm that can be used to generated a hierarchical relational...
6
by: Greg M | last post by:
I have 5 years of MS Access/VBA development experience and am moving into the VB.net world. I am seeking a tutor which could facilitate this move. I live in Anderson, IN and am willing to...
4
by: Mason Barge | last post by:
I'm learning how to build a website. So far I've gotten pretty good with HTML, CSS, and Paint Shop Pro, and I'm currenly learning the basics of Javascript. I'm hoping, eventually, to build and...
4
by: | last post by:
I am a recent college graduate and am looking for some advice on how to be a skilled C++ developer. My educational background is from a quite mediocre campus. Can anybody please explain what is...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.