|
-
May 10th, 2003, 02:48 PM
#1
Why wont this INNER JOIN work
I am joining two tables together using INNER join. I want some of the feilds from one table (stockLevels) and some fields from the other (productFile).
When select all fields it works fine:
SELECT * FROM stockLevels INNER JOIN productFile ON productFile.ProductID = stockLevels.productID;
but when I start to choose the fields Even one I get an error.
Dim sqlQuery2 As String = "select stoclLevels.name, productFile.costPrice from stockLevels INNER JOIN productFile ON productFile.ProductID = stockLevels.productID"
No value givern fore one or more paramiters.
The SQL command I would like to execute is:
Dim sqlQuery2 As String = "SELECT productFile.supplierID, productFile.productID, productFile.ProdctName, productFile.costPrice, productFile.servingsPerUnit, stockLvels.servings, stockLevels.reorderLevel, stockLevels.NormaLevel FROM productFile INNER JOIN stockLevels ON productFile.ProductID = stockLevels.productID ;"
Thanks for reading an please help
scottie.uk
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|