dbTalk Databases Forums  

got myself in a corner with sub sub form and links

comp.databases.ms-access comp.databases.ms-access


Discuss got myself in a corner with sub sub form and links in the comp.databases.ms-access forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
sparks
 
Posts: n/a

Default got myself in a corner with sub sub form and links - 02-26-2008 , 03:03 PM






TRYING TO USE SHORT NAMES might make more since.

I have a main form and its tied to tblmain
subform1 and it is tied to tbl1
subsubformA on subform1 tied to tbl2


MAIN---tblmain----autoid
subform1----tbl1----ID
subsubform1----tbl2----ID



hope that makes since.
mainform to subform is AutoId to ID

the links on the subform to subsubform is ID to ID
ID (tbl1)
ID(tbl2)


all of this works but it requires them to put in some data on the
subform so It gets an ID and then the subsubform will link to it.

This is great until they want to put some data into subsubform and
nothing in its parent form. No record nothing to link to.

I thought about trying to tie subsubformA tbl2 to tblmain
but the links on the forms/subforms won't allow that.

how should I do this so they can enter data into the subsubform
without entering data into the subform?
make an autoid and/or Id field on the subform and make Id required?
Then if they didn't do anything on this form would I end up with empty
records in the table?

anyone know how to get around this so I don't have empty records but
allow them to put in whatever they want?




Reply With Quote
  #2  
Old   
Larry Linson
 
Posts: n/a

Default Re: got myself in a corner with sub sub form and links - 02-26-2008 , 06:26 PM






If it makes sense to have data in the main Form, no data in the Form
embedded in the first-level Subform Control, but data in the Form embedded
in the second-level Subform Control, then you have structured your
Form/SubformControl/SubformControl wrongly.

The first level of Subform Control should contain information related
many-to-one to records in the main Form. The second level of Subform
Control should contain information related many-to-one to records in the
first level of Subform Control.

If, on the other hand, both of the Subform Controls contain data that is
related to the main Form, then they should be on the same level and should
have LinkMasterFields and LinkChildFields relating each to the main Form.

It's really helpful to use precise terminology... so there's no confusion
about what's meant by "tied" or "subsubform", for example. And, in my
observation, the questions that get the best answers are precise and
concise. For other good suggestions on effective use of newsgroups, see the
FAQ at http://www.mvps.org/access/netiquette.htm.

Larry Linson
Microsoft Office Access MVP

"sparks" <sparks (AT) comcast (DOT) net> wrote

Quote:
TRYING TO USE SHORT NAMES might make more since.

I have a main form and its tied to tblmain
subform1 and it is tied to tbl1
subsubformA on subform1 tied to tbl2


MAIN---tblmain----autoid
subform1----tbl1----ID
subsubform1----tbl2----ID



hope that makes since.
mainform to subform is AutoId to ID

the links on the subform to subsubform is ID to ID
ID (tbl1)
ID(tbl2)


all of this works but it requires them to put in some data on the
subform so It gets an ID and then the subsubform will link to it.

This is great until they want to put some data into subsubform and
nothing in its parent form. No record nothing to link to.

I thought about trying to tie subsubformA tbl2 to tblmain
but the links on the forms/subforms won't allow that.

how should I do this so they can enter data into the subsubform
without entering data into the subform?
make an autoid and/or Id field on the subform and make Id required?
Then if they didn't do anything on this form would I end up with empty
records in the table?

anyone know how to get around this so I don't have empty records but
allow them to put in whatever they want?






Reply With Quote
  #3  
Old   
sparks
 
Posts: n/a

Default Re: got myself in a corner with sub sub form and links - 02-27-2008 , 07:24 AM



Well they have a paper form(s) 8 pages.
on page 1 is the persons info.
lets call it tablemain and formmain

each page is a subform pg2- pg7

now on pg2 is a list 1 to many of all the things this person can use.

The problem is pg2 has all the info for this visit and the subsubform
is a contiguous form of all the usable things

this is fine but as they told me we might put in the things this
person can use and not fill in anything else.

I said well lets make another tab and form and you can fill that in.

their reply BUT ITS ON PAGE 2

FU#$%

I did explain to them that page2 also has a DATE and they should be
REQUIRED to put that in (solve everything) they are thinking about it.

hope they can understand this



On Wed, 27 Feb 2008 00:26:29 GMT, "Larry Linson"
<bouncer (AT) localhost (DOT) not> wrote:

Quote:
If it makes sense to have data in the main Form, no data in the Form
embedded in the first-level Subform Control, but data in the Form embedded
in the second-level Subform Control, then you have structured your
Form/SubformControl/SubformControl wrongly.

The first level of Subform Control should contain information related
many-to-one to records in the main Form. The second level of Subform
Control should contain information related many-to-one to records in the
first level of Subform Control.

If, on the other hand, both of the Subform Controls contain data that is
related to the main Form, then they should be on the same level and should
have LinkMasterFields and LinkChildFields relating each to the main Form.

It's really helpful to use precise terminology... so there's no confusion
about what's meant by "tied" or "subsubform", for example. And, in my
observation, the questions that get the best answers are precise and
concise. For other good suggestions on effective use of newsgroups, see the
FAQ at http://www.mvps.org/access/netiquette.htm.

Larry Linson
Microsoft Office Access MVP

"sparks" <sparks (AT) comcast (DOT) net> wrote in message
news:23v8s31aq4khg33mgpsf67ptjjomo1jj5n (AT) 4ax (DOT) com...
TRYING TO USE SHORT NAMES might make more since.

I have a main form and its tied to tblmain
subform1 and it is tied to tbl1
subsubformA on subform1 tied to tbl2


MAIN---tblmain----autoid
subform1----tbl1----ID
subsubform1----tbl2----ID



hope that makes since.
mainform to subform is AutoId to ID

the links on the subform to subsubform is ID to ID
ID (tbl1)
ID(tbl2)


all of this works but it requires them to put in some data on the
subform so It gets an ID and then the subsubform will link to it.

This is great until they want to put some data into subsubform and
nothing in its parent form. No record nothing to link to.

I thought about trying to tie subsubformA tbl2 to tblmain
but the links on the forms/subforms won't allow that.

how should I do this so they can enter data into the subsubform
without entering data into the subform?
make an autoid and/or Id field on the subform and make Id required?
Then if they didn't do anything on this form would I end up with empty
records in the table?

anyone know how to get around this so I don't have empty records but
allow them to put in whatever they want?






Reply With Quote
  #4  
Old   
Larry Linson
 
Posts: n/a

Default Re: got myself in a corner with sub sub form and links - 02-28-2008 , 01:40 AM



I am sorry... but I find your description more than a little difficult to
follow.

The forms used in a manual system are often illogical and do not give good
guidance for automating that system. It is the data that should determine
what forms to use, and how, not the other way around.

My guess is that your statement "The problem is pg2 has all the info for
this visit and the subsubform
is a contiguous form of all the usable things", at the very least, means
that you are not using Subform Controls as I understand they should be used.

Back off -- try to figure out how to describe the data you have, simply and
straightforwardly, to someone who _does not_ already know it. That means
you are likely to have to be a good deal less vague, and a good deal more
specific and more detailed, if we are to be able to assist you.

Larry Linson
Microsoft Office Access MVP


"sparks" <sparks (AT) comcast (DOT) net> wrote

Quote:
Well they have a paper form(s) 8 pages.
on page 1 is the persons info.
lets call it tablemain and formmain

each page is a subform pg2- pg7

now on pg2 is a list 1 to many of all the things this person can use.

The problem is pg2 has all the info for this visit and the subsubform
is a contiguous form of all the usable things

this is fine but as they told me we might put in the things this
person can use and not fill in anything else.

I said well lets make another tab and form and you can fill that in.

their reply BUT ITS ON PAGE 2

FU#$%

I did explain to them that page2 also has a DATE and they should be
REQUIRED to put that in (solve everything) they are thinking about it.

hope they can understand this



On Wed, 27 Feb 2008 00:26:29 GMT, "Larry Linson"
bouncer (AT) localhost (DOT) not> wrote:

If it makes sense to have data in the main Form, no data in the Form
embedded in the first-level Subform Control, but data in the Form embedded
in the second-level Subform Control, then you have structured your
Form/SubformControl/SubformControl wrongly.

The first level of Subform Control should contain information related
many-to-one to records in the main Form. The second level of Subform
Control should contain information related many-to-one to records in the
first level of Subform Control.

If, on the other hand, both of the Subform Controls contain data that is
related to the main Form, then they should be on the same level and should
have LinkMasterFields and LinkChildFields relating each to the main Form.

It's really helpful to use precise terminology... so there's no confusion
about what's meant by "tied" or "subsubform", for example. And, in my
observation, the questions that get the best answers are precise and
concise. For other good suggestions on effective use of newsgroups, see
the
FAQ at http://www.mvps.org/access/netiquette.htm.

Larry Linson
Microsoft Office Access MVP

"sparks" <sparks (AT) comcast (DOT) net> wrote in message
news:23v8s31aq4khg33mgpsf67ptjjomo1jj5n (AT) 4ax (DOT) com...
TRYING TO USE SHORT NAMES might make more since.

I have a main form and its tied to tblmain
subform1 and it is tied to tbl1
subsubformA on subform1 tied to tbl2


MAIN---tblmain----autoid
subform1----tbl1----ID
subsubform1----tbl2----ID



hope that makes since.
mainform to subform is AutoId to ID

the links on the subform to subsubform is ID to ID
ID (tbl1)
ID(tbl2)


all of this works but it requires them to put in some data on the
subform so It gets an ID and then the subsubform will link to it.

This is great until they want to put some data into subsubform and
nothing in its parent form. No record nothing to link to.

I thought about trying to tie subsubformA tbl2 to tblmain
but the links on the forms/subforms won't allow that.

how should I do this so they can enter data into the subsubform
without entering data into the subform?
make an autoid and/or Id field on the subform and make Id required?
Then if they didn't do anything on this form would I end up with empty
records in the table?

anyone know how to get around this so I don't have empty records but
allow them to put in whatever they want?








Reply With Quote
  #5  
Old   
sparks
 
Posts: n/a

Default Re: got myself in a corner with sub sub form and links - 02-28-2008 , 07:15 AM



Well this has been a LOOOONNNNGGGGG week.

It seems that people can put something on paper no matter how it works
or doesn't work and expect a database to perform like a piece of
paper.

The main database is controlled by tableMain which has one autoID for
linking to the other tables in a 1 to 1 link.

page 2 is a subform on a tab and is tied to tableVisit


on the page is data that will be collected at a certain point in time.
So we have a date at the top of the form.
at the bottom of the form they draw 2 lines. This will be the
equipment.
BUT it might be more than 2. So I made it a subform and a new table so
the contiguous form can have as many as it needs.
The subform(page2) and the new contiguous subsubform(EQ) are linked by
ID as a 1 to many relationship.

Everything was fine until they decided they might NOT put in any data
on the subform(page2) instead they would just list the EQ in the
subsubform.

Now that this subsubform is tied to its parent form by ID since the
parent form is not populated there is no ID to link to the subsubform.

I can not think of any way to link a subsubform to the main form
without going thru the subform(its immediate parent).

Again I am sorry about a format it is so easy for me to see what is in
front of me but very hard to put it into words without pictures.



Reply With Quote
  #6  
Old   
Salad
 
Posts: n/a

Default Re: got myself in a corner with sub sub form and links - 02-28-2008 , 11:42 AM



sparks wrote:

Quote:
Well this has been a LOOOONNNNGGGGG week.

It seems that people can put something on paper no matter how it works
or doesn't work and expect a database to perform like a piece of
paper.

The main database is controlled by tableMain which has one autoID for
linking to the other tables in a 1 to 1 link.

page 2 is a subform on a tab and is tied to tableVisit


on the page is data that will be collected at a certain point in time.
So we have a date at the top of the form.
at the bottom of the form they draw 2 lines. This will be the
equipment.
BUT it might be more than 2. So I made it a subform and a new table so
the contiguous form can have as many as it needs.
The subform(page2) and the new contiguous subsubform(EQ) are linked by
ID as a 1 to many relationship.

Everything was fine until they decided they might NOT put in any data
on the subform(page2) instead they would just list the EQ in the
subsubform.

Now that this subsubform is tied to its parent form by ID since the
parent form is not populated there is no ID to link to the subsubform.

I can not think of any way to link a subsubform to the main form
without going thru the subform(its immediate parent).

Again I am sorry about a format it is so easy for me to see what is in
front of me but very hard to put it into words without pictures.


Maybe have your form for equipment tied to the main table. Add into the
equipment table a field to hold the subform key. Make equipment a
separate form. If a record is added from the subform, put in the
subform key.

You might need to change a relationship line so it's not an inner join
but a left join.

Alone
http://www.youtube.com/watch?v=CbH04pY7alA


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.