View Single Post
  #5  
Old March 8th, 2010, 02:48 PM posted to microsoft.public.access.tablesdbdesign
Maulwy
external usenet poster
 
Posts: 22
Default Creating new row in other table

Dear All,

Sorry, the example should be:

TransID Model Qty
1 AAA 2
2 BBB 3

TransID SerialNumber
1 AAAXXX01
1 AAAXXX02
2 BBBXXX01
2 BBBXXX50
2 BBBXXX65 (null?)

Many Thanks,
Maulwy

"Maulwy" wrote:


Dear Jeff & John,

For example, if we do a sales order, where there is a column for the model,
quantity and serial number. To model and quantity, comes from one table,
while for the serial number, which I want, be inputted in the other table.
But not all existing models, has a serial number, this is the basic one, the
serial number I did not join in a single table. To avoid input mistakes
serial number, if the quantity, I suppose input 2, then automatically, the
database will add the 2 lines at the next table (the serial number tables).
Database like this is what I mean. Example data:
Model TransID Qty
1 AAA 2
2 BBB 3

TransID SerialNumber
1 AAAXXX01
1 AAAXXX02
2 BBBXXX01
2 BBBXXX50
2 BBBXXX65

Rgds,
Maulwy

"John W. Vinson" wrote:

On Sun, 7 Mar 2010 04:46:01 -0800, Maulwy
wrote:

Dear All,

Please teach me, how to make a new row/list in other table by entering
number in other table. Sample, In the table A and in the field "Details", I
put the number 2 and it automatically creates two rows in table B. Can this
be done in MS Access? Thank you for your help.

Regards,
Maulwy


As Jeff says, it's very rarely either necessary nor a good idea to create
empty "placeholder" records in a table. They have an unpleasant habit of never
getting filled in.

The normal way to do this is to use a Form based on TableA, with a Subform
based on TableB, using the subform's Master/Child Link Field properties to
link them. When you enter data into the form and then the subform, Access will
automatically fill in the link, *when it is needed* and not before.

If you have some special need to do it the other way please explain.
--

John W. Vinson [MVP]
.