|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stay one step ahead of the competition. Evaluate and give feedback
on some of the hottest web development tools on the market today.
Make your opinion heard! Click
Here
|
|
#1
|
||||
|
||||
|
Computed field SQL Query in Access 2000
I am trying to run a SQL query in Access 2000
From the a table called Item, I want to display the following fields
I only want to display those items where the difference between the cost of the item and the selling price is less than $2.00 I use this first line to determine the difference between cost and selling price no problems Code:
SELECT [Item Id], [Description], [Selling Price] - [Cost] AS [Difference] I use this line to define which table the data comes from Code:
FROM [Item] How do I then define to only display those items where the difference is less than $2.00?? |
|
#2
|
||||
|
||||
|
Doh!!
I figured it out, I was approaching it all wrong and in the end it was very simple Code:
SELECT [Item Id], [Description], [Selling Price], [Cost] FROM [Item] WHERE [Selling Price] - [Cost] <2; |
![]() |
| Viewing: Dev Shed Forums > Databases > Database Management > Computed field SQL Query in Access 2000 |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|