Author |
Topic |
mrtanvirali
Starting Member
41 Posts |
Posted - 2009-11-22 : 03:02:41
|
Hi,I've to design database in which i've to manage referrals,there will be some zones,zone 1 As a person has 1st referral that could get sum of amount up to 11th level (referrals) (up till a person have 3 first level referrals),zone 2As he/she gets 4th referral (1st level) that will move to the next zone there he/she can get sum of amount unlimited levelsand so on uptill 5th zones (options same like zone 2)Please I need help, can any one help me in designing and or creation of database. |
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-11-22 : 12:12:25
|
seems like what you need is table to store zones and another one to store referal levels and their details |
|
|
mrtanvirali
Starting Member
41 Posts |
Posted - 2009-11-23 : 00:35:22
|
yea visakah16 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-11-23 : 09:20:12
|
is that ok or do you want help in designing table also? |
|
|
mrtanvirali
Starting Member
41 Posts |
Posted - 2009-11-23 : 11:10:55
|
ya i need help in designing tables, |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-11-23 : 11:26:52
|
can i ask what are attributes you have? |
|
|
mrtanvirali
Starting Member
41 Posts |
Posted - 2009-11-23 : 12:16:19
|
Its starting, i've just little till because i am just waiting for the ideas about referrals storing and there payments detailsfor user regstration that could be,ReferralId, DOB, FirstName, LastName, Address, City, Country, Zip/Postal, Email, Phonefor products table (currently only one item)productid, name, description, typeid, categoryid, price and some others might becategory tablecategoryid, name,descriptioni need help in referral storing and or managingi think there should be a table for user referral maping and the attributes should beUserId, ReferralIdbut how can i manage up to 11th level and or unlimited levels, |
|
|
mrtanvirali
Starting Member
41 Posts |
Posted - 2009-11-23 : 12:26:21
|
about product, that must be sell in the market (not online) as well as get referral to sell the product fruther |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-11-23 : 12:47:01
|
for managing levels you can have a hierarchial structure something like userid,refferalid which points to userid itself and it will roll down in hierarchial format. something like person1 refering person2, then person2 refering person3,.. then we can represent asuserid referingidperson1 nullperson2 person1person3 person2.... |
|
|
mrtanvirali
Starting Member
41 Posts |
Posted - 2009-11-24 : 01:51:11
|
what about the payments how can i manage that, and can you give me the proper tables of it |
|
|
gaggel
Starting Member
8 Posts |
Posted - 2009-12-03 : 00:42:32
|
Hi colleaguesI'm trying to design a db from scratch and I want to determine unique records to any table.In some tables it is not possible to do it with just one field (column) and I need to determine 2 or more fields as one field in order to play the role of the primary key of the table.E.g. for an application (p. key: 3) which is installed to this pc (p. key: 6) I have fix these problems:3,6: wertyuiop (first record)3,6: sdfghjklj (second record)3,6: xcvbnmnm (third record)For the same application in another pc I can have:3,8: thjkiol (first record)3,8: sasasas (second record)So this combination of "Application_ID + PC_ID" can work as a primary key in detail table.Does anyone know how can I declare it in the MS SQL?Thank you all, for your time in advance. |
|
|
|