By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,660 Members | 1,560 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,660 IT Pros & Developers. It's quick & easy.

Append query help

P: n/a
Hi - I am trying to perform a simple append query, with no luck. I
have a table (MktPrices) that has the following fields: BondID,
PriceDate, Price. The objective is to allow the user to input a date
and have the append query create a new record for each BondID, using
the input date and the most recent price - which the user can then
update on a tabular form. I have created a totals query
(qryMostRecentPrice) which selects the most recent price (Max of Date,
group by BondID) for each BondID, but cannot work out the append
query. Thanks, John
Nov 12 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
John,

You apparently have a Bonds table with a primary key of BondID. How about
setting up a form/subform where the main table is based on the Bonds table and
the subform is based on the MktPrices table. The LinkMaster/LinkChild properties
would be BondID. In the subform you could have one textbox bound to PriceDate
and one textbox to enter Price. In the AfterUpdate event of the Price textbox
put this code: Me!NameOfPriceDateTextBox = Date()

So you could go to a Bond in the main form and the subform would automatically
go to the Price records of that Bond. You could enter today's price for the Bond
and the code would automatically enter today's date for you in the PriceDate
textbox. The PriceDate textbox would be editable so that if the price was for
another day rather than today, you could change today's date to the appropriate
date.
--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications
www.pcdatasheet.com
"John" <jo********@hotmail.com> wrote in message
news:a1*************************@posting.google.co m...
Hi - I am trying to perform a simple append query, with no luck. I
have a table (MktPrices) that has the following fields: BondID,
PriceDate, Price. The objective is to allow the user to input a date
and have the append query create a new record for each BondID, using
the input date and the most recent price - which the user can then
update on a tabular form. I have created a totals query
(qryMostRecentPrice) which selects the most recent price (Max of Date,
group by BondID) for each BondID, but cannot work out the append
query. Thanks, John

Nov 12 '05 #2

P: n/a
Hi - I actually already have the form/subform you are describing set
up. That particular form, as you describe, lists the bond description
information along with a price 'history' subform for each bond.

The new form that I am trying to create (based off of the append
query) will be a simplified tabluar form that will allow the user to
update all prices quickly by having a single row for each security:
BondID and price. I would like the user to be able to click a button,
be prompted for the date, have the append query create the new price
records, and then have the new tabular form open.
"PC Datasheet" <sp**@bellsouth.net> wrote in message news:<ig***************@newsread1.news.atl.earthli nk.net>...
John,

You apparently have a Bonds table with a primary key of BondID. How about
setting up a form/subform where the main table is based on the Bonds table and
the subform is based on the MktPrices table. The LinkMaster/LinkChild properties
would be BondID. In the subform you could have one textbox bound to PriceDate
and one textbox to enter Price. In the AfterUpdate event of the Price textbox
put this code: Me!NameOfPriceDateTextBox = Date()

So you could go to a Bond in the main form and the subform would automatically
go to the Price records of that Bond. You could enter today's price for the Bond
and the code would automatically enter today's date for you in the PriceDate
textbox. The PriceDate textbox would be editable so that if the price was for
another day rather than today, you could change today's date to the appropriate
date.
--
PC Datasheet
Your Resource For Help With Access, Excel And Word Applications
www.pcdatasheet.com
"John" <jo********@hotmail.com> wrote in message
news:a1*************************@posting.google.co m...
Hi - I am trying to perform a simple append query, with no luck. I
have a table (MktPrices) that has the following fields: BondID,
PriceDate, Price. The objective is to allow the user to input a date
and have the append query create a new record for each BondID, using
the input date and the most recent price - which the user can then
update on a tabular form. I have created a totals query
(qryMostRecentPrice) which selects the most recent price (Max of Date,
group by BondID) for each BondID, but cannot work out the append
query. Thanks, John

Nov 12 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.