REVENSE
Posts: 46
|
| Posted: 06/28/2007, 10:29 PM |
|
Hi Guys,
i was try to made numbering like this
fiield a b c d
1 1 1 -
1 1 1 1
1 1 2 -
1 1 2 1
1 2 1 -
1 2 1 1
so eaach data acording the parent.
i hope any one can give me idea how to solve it,
thx
jun
|
 |
 |
mamboBROWN
Posts: 1713
|
| Posted: 06/29/2007, 4:04 PM |
|
REVENSE
I don't know if I really understand what you are trying to do. Could you please give us some more information. If that is possible.
|
 |
 |
REVENSE
Posts: 46
|
| Posted: 07/04/2007, 3:44 AM |
|
mambo thx for u respon
i have 4 table
1. Table Parent (on field parent i have 5 record (fixed) each record have id example id = 1)
with filed idparent, and note.>>> idparent= 1 note = parent1
2. child1 (on tble child i have 3 field which is "idchild1,note, parent and when i entry the record i must select table parent then when i am save the record the data mus be
idfield = 1 >>> note = record child1 parent = 1.1 << acording the parent i selected
3. Child 2 (the proses is sameee but the difrent i must select child1 table, so the data what iam expected >>> idchild = 1, note = recordchild2, parent = 1.1.1 << acording the child i selected
if i selected child1 with record id=2 then record parent = 1.2.1.
example record = 1. <<< parent
1.1 <<< child 1
1.1.1 <<<< child 2
1.1.1.1 <<<< child 3
mambo can u give a solution how to do it,
but before that i am sorry my engglish 
thx mambo,
Jun
|
 |
 |
mamboBROWN
Posts: 1713
|
| Posted: 07/04/2007, 9:20 AM |
|
REVENSE
I think I understand what you are trying to do. It appears that you are trying to pull information from the three tables and display the information in numbering order according to parent and child. What you are going to need to do is create a query that pulls all the fields that you need from the parent and child tables. then we can join the fields together to give you the results that you are looking for and order them according to parent child relationship. Did you get all of that?? Before I get going I am going to need you to list each table and its' fields (also give me an example value for each field.) Thanks. I want to make sure that I get it right the first time.
|
 |
 |
REVENSE
Posts: 46
|
| Posted: 07/04/2007, 7:55 PM |
|
Tabel Parent
-----------------------------------------------------------
idparent Note Linkparent
---------- |-----------------------------------------------
1 | Admin 1
2 | Manager 2
3 | Reguler User 3
Tabel Child 1 (Group)
--------------------------------------------------------------------------------------------------
idchild1 | Note Linkparent
--------------------------------------------------------------------------------------------------
1 | Mic 1.1 all idparent i reciive when saved on insert mode
2 | Leon 1.2
3 | Andi 2.1
4 | Grace 3.1
Tabel Child 2 (membergroup)
-------------------------------------------------------------------------------------------------
idchild2 | Note LinkChild1
---------------------------------------------------------------------------------------------------
1 Susi 1.1.1 all LinkChild1 i reciive when saved on insert mode
2 Veronica 1.1.2
3 Stev 3.1.1
4 Dea 3.1.2
Tabel Child3 (memberstaff)
---------------------------------------------------------------------------------------------------
idchild3 | Note LinkcChild2
--------------------------------------------------------------------------------------------------
1 Glen 1.1.1.1 all LinkChild2 i reciive when saved on insert mode
2 Rei 1.1.1.2
3 Glen 3.1.2.1
4 Marry 3.1.2.2
TabelChild4 (aktivities)
-------------------------------------------------------------------------------------------------------------
idchild4 | Activities LinkcChild3
---------------------------------------------------------------------------------------------------------------
1 Activities1 1.1.1.1.1 all LinkChild3 i reciive when saved on insert mode
2 Activities2 1.1.1.1.2
3 Activities1 3.1.1.1.1
4 Activities2 3.1.1.1.2
Filed LinkcChild 1,2,3 will be incrase acording table parent (selected) on insert mode
mambo thx again for u respons,
|
 |
 |
mamboBROWN
Posts: 1713
|
| Posted: 07/11/2007, 8:40 PM |
|
REVENSE
I haven't forgotten about you. I am actually trying to come up with a different way for you to track the parent and children. The method that you listed above (in my opinion) is not the best way to do it. Please bear with me and I will try to get back to you very soon (hopefully before the end of the week).
|
 |
 |
REVENSE
Posts: 46
|
| Posted: 07/12/2007, 3:43 AM |
|
Ok and thx again mambo
i will be waiting the good news from you,
thx
REV
|
 |
 |
mamboBROWN
Posts: 1713
|
| Posted: 07/17/2007, 9:11 PM |
|
REVENSE
Here is one of my solutions:
instead of having multiple tables why not have one table and store the level information in it and create other supporting tables that will list parents, activities and children
SecParActivites (Table name)
-spa_ID (id)
-S1 (security level1)
-G2 (group level2)
-MG3 (member group level3)
-MS4 (member staff level4)
-A5 (activites level5)
-pid (person id from person table)
you would have these supporting tables:
sup_Security
sup_Group
sup_MemberGroup
sup_MemberStaff
sup_Activities
Person
You could then create a editable grid that would allow you to add in the data (use drop down list box). Make sure that you make the fields (with drop down list-S1,G2,MG3,MS4,A5
) mandatory and create an index on all of the fields (S1,G2,MG3,MS4,A5
) so that you will not have entres with the same 5 numbers (6 if you want it to be unique to each name).
Your data should then look like this:
spa_ID | S1 | G2 | MG3 | MS4 | A5 | pid
1 | 1 | 1 | 0 | 0 | 0 | 1 (Mic)
------------------------------------------------------
2 | 1 | 1 | 1 | 0 | 0 | 4 (Susi)
------------------------------------------------------
3 | 1 | 2 | 0 | 0 | 0 | 6(Leon)
------------------------------------------------------
4 | 1 | 2 | 1 | 0 | 0 | 9 ( Edwin)
------------------------------------------------------
5 | 1 | 3 | 0 | 0 | 0 | 5 (Andi)
------------------------------------------------------
6 | 1 | 3 | 1 | 0 | 0 | 20 (Donald)
When you print this out all you have to do is in the query order it by the levels.
I do have another suggestion. If I get the chance I will also put it here. Let me know if this helps you...
|
 |
 |
|