Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
ani07in
Starting Member
5 Posts |
Posted - 2007-01-13 : 08:21:58
|
| I have a product table with list of products and different prices (depending on quantity of item selected, prices for single product(1,2 and 10 Dozen) as inthe table belowProducts Table Id Product Single 1Dozen 2Dozen 10Dozen1 ABC 5 50 80 4002 XYZ 10 100 180 8003 HHHH 2 20 30 180how do i get the result in the following format after user selects the productsOrder Table User Product Quantity TotalMyName XYZ 24 (2 Dozen) 180MyName HHH 120 (10 Dozen) 180MyName ABC 12(1 Dozen) 50also how do i get totalvalue (410)i apologise for the display format of above tables on screen....Thanx in advance |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2007-01-13 : 08:28:40
|
| To get Dozen valueselect '(' + cast(144 / 12 as varchar) + ' Dozen)' AS Dozen.Peter LarssonHelsingborg, Sweden |
 |
|
|
|
|
|