Append Multiple copies of each record

G

Guest

I have a table (tblBooks) like with the following fields

BookID, Quantity, Price

I want to append this to another table (tblCopies), my problem is that I
want to append each seperate copy of each book into its own record.

So for example tblBooks has the following record
11241, 5, £221

I would like to append 5 records to tblCopies with the following info:

11241, £221
11241, £221
11241, £221
11241, £221
11241, £221

Can anyone explain how I might do this?
 
D

Duane Hookom

Create a table of numbers with a single numeric field:
tblNumbers.Num
1
2
3
4
5
...
max quantity

Create an append query with tblBooks and tblNumbers. Don't create any join
lines. Set the criteria under the [Num] field to
<=[Quantity]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top