Forums
This topic is locked
keeping current price current
23 Aug 2001 13:13:25 jon badda posted:
When a user adds a product to thier order form, it inserts product, price, userID, orderID etc..But what im needing is for the price to be kept current.
I think my dilemma is when the order is inserted, its keeps the price static.
Is there a way, either in the database itself (access) or in filtering an already filtered recordset?
i hope this is clear...post if you want any clarification.
Replies
Replied 23 Aug 2001 16:37:45
23 Aug 2001 16:37:45 Joel Martinez replied:
hmm, unless you don't have a products table, just store the productID in the order table. Then you can refer to it using an INNER JOIN to the two tables.
That way, if the price changes, the price will be what's currently in the product table.
but that poses another problem, then the customer will want the original price, so maybe storing the price in the order table isn't such a bad Idea...
Really it's all about what your program needs.
If this isn't your issue, post again with some clarification.
Joel Martinez [ ]
----------
set rs = conn.execute("SELECT answer FROM brain WHERE question = "& forumPost &"
'2nd place is just 1st Loser
That way, if the price changes, the price will be what's currently in the product table.
but that poses another problem, then the customer will want the original price, so maybe storing the price in the order table isn't such a bad Idea...
Really it's all about what your program needs.
If this isn't your issue, post again with some clarification.
Joel Martinez [ ]
----------
set rs = conn.execute("SELECT answer FROM brain WHERE question = "& forumPost &"
'2nd place is just 1st Loser
Replied 26 Aug 2001 13:22:37
26 Aug 2001 13:22:37 jon badda replied:
<BLOCKQUOTE id=quote><font size=1 face="Verdana, Arial, Helvetica" id=quote>quote:<hr height=1 noshade id=quote>
hmm, unless you don't have a products table, just store the productID in the order table. Then you can refer to it using an INNER JOIN to the two tables.
That way, if the price changes, the price will be what's currently in the product table.
but that poses another problem, then the customer will want the original price, so maybe storing the price in the order table isn't such a bad Idea...
<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>
actually, sounds exactly like what i need...
thanks.
hmm, unless you don't have a products table, just store the productID in the order table. Then you can refer to it using an INNER JOIN to the two tables.
That way, if the price changes, the price will be what's currently in the product table.
but that poses another problem, then the customer will want the original price, so maybe storing the price in the order table isn't such a bad Idea...
<hr height=1 noshade id=quote></BLOCKQUOTE id=quote></font id=quote><font face="Verdana, Arial, Helvetica" size=2 id=quote>
actually, sounds exactly like what i need...
thanks.
Replied 26 Aug 2001 14:06:27
26 Aug 2001 14:06:27 jon badda replied:
hrm, after much painstaking reading through Access tutorials (kill me) i finally ound out that an inner join is the default and is not what i needed after all...bummer.
I'll clarify and see if you can help again...
i have a Products Table.
i have a Orders Table.
the orders table contains most of the information from the products table but also information from the User table.
what i need is: when an order is placed, a productID number is added (along with all the other user details) to the Orders table. What i want the database to do is to pull all the relevant info from the Products table that matches the productID and display in the relevant in fields.
I had a play around with queries but couldnt tell if they were what i needed or not...
(quasi-newbie) at access.
I'll clarify and see if you can help again...
i have a Products Table.
i have a Orders Table.
the orders table contains most of the information from the products table but also information from the User table.
what i need is: when an order is placed, a productID number is added (along with all the other user details) to the Orders table. What i want the database to do is to pull all the relevant info from the Products table that matches the productID and display in the relevant in fields.
I had a play around with queries but couldnt tell if they were what i needed or not...
(quasi-newbie) at access.