Click here to Skip to main content
15,920,217 members
Home / Discussions / Database
   

Database

 
GeneralRe: how to find string existence in the another string . Pin
Ashfield27-Aug-08 2:55
Ashfield27-Aug-08 2:55 
AnswerRe: how to find string existence in the another string . Pin
Blue_Boy27-Aug-08 3:12
Blue_Boy27-Aug-08 3:12 
AnswerRe: how to find string existence in the another string . Pin
Wendelius27-Aug-08 6:50
mentorWendelius27-Aug-08 6:50 
QuestionHow to read sql server2000/2005 transaction log user friendly way? Pin
Tridip Bhattacharjee27-Aug-08 1:56
professionalTridip Bhattacharjee27-Aug-08 1:56 
AnswerReading the transaction log - Nope Pin
David Mujica27-Aug-08 3:55
David Mujica27-Aug-08 3:55 
GeneralRe: Reading the transaction log - Nope Pin
Netblue27-Aug-08 8:27
Netblue27-Aug-08 8:27 
AnswerAudit table format Pin
David Mujica27-Aug-08 10:16
David Mujica27-Aug-08 10:16 
Questionneed help with inner join and oount sql server 2005 Pin
VijayVishwakarma27-Aug-08 0:19
VijayVishwakarma27-Aug-08 0:19 
hi,
I m trying to get values from three tables.
1) its has the sale id and product id
2) it has the product details based on id from 1st table,
3) it has the quantity of product being selected by the query.
My problem is I need to check the count of the product based on various sizes and if its more than 0 i need to display available else sold out.

I tried the following query.

if I remove the count it works well to get the details but If I m gonna get the count it throws error.

any suggestion where this query is wrong??


SELECT SaleProduct_tb.ProductId, Product_tb.BasePrice, Product_tb.SalePrice, Product_tb.PName, Product_tb.Image1, COUNT(ProductSizeQty.Quantity)
AS Expr1
FROM SaleProduct_tb INNER JOIN
Product_tb ON SaleProduct_tb.ProductId = Product_tb.ProductId INNER JOIN
ProductSizeQty ON Product_tb.ProductId = ProductSizeQty.ProductId
WHERE (SaleProduct_tb.SaleId = @SaleId) AND (SaleProduct_tb.CatId = @CatId) AND (SaleProduct_tb.SubCatId = @SubCatId) AND
(Product_tb.BrandId = @BrandId) ORDER BY saleProduct_tb.ProductId

Vijay V.

Yash Softech

AnswerRe: need help with inner join and oount sql server 2005 Pin
Ashfield27-Aug-08 1:33
Ashfield27-Aug-08 1:33 
GeneralRe: need help with inner join and oount sql server 2005 Pin
neilmajithia27-Aug-08 4:15
neilmajithia27-Aug-08 4:15 
GeneralRe: need help with inner join and oount sql server 2005 Pin
VijayVishwakarma27-Aug-08 4:37
VijayVishwakarma27-Aug-08 4:37 
AnswerRe: need help with inner join and oount sql server 2005 Pin
NeverHeardOfMe27-Aug-08 2:03
NeverHeardOfMe27-Aug-08 2:03 
GeneralRe: need help with inner join and oount sql server 2005 Pin
VijayVishwakarma27-Aug-08 4:36
VijayVishwakarma27-Aug-08 4:36 
QuestionUploading results in to an Excel Pin
joemonvarghese80@yahoo.co.in27-Aug-08 0:07
joemonvarghese80@yahoo.co.in27-Aug-08 0:07 
AnswerRe: Uploading results in to an Excel Pin
Manas Bhardwaj27-Aug-08 0:22
professionalManas Bhardwaj27-Aug-08 0:22 
AnswerRe: Uploading results in to an Excel Pin
Chris Quinn27-Aug-08 2:55
Chris Quinn27-Aug-08 2:55 
AnswerStart from Excel Pin
David Mujica27-Aug-08 3:50
David Mujica27-Aug-08 3:50 
Questionsql server (multplie column value as one row value) Pin
vjvjvjvj26-Aug-08 23:38
vjvjvjvj26-Aug-08 23:38 
AnswerRe: sql server (multplie column value as one row value) Pin
Ashfield27-Aug-08 0:39
Ashfield27-Aug-08 0:39 
QuestionRe: sql server (multplie column value as one row value) Pin
vjvjvjvj27-Aug-08 2:00
vjvjvjvj27-Aug-08 2:00 
AnswerRe: sql server (multplie column value as one row value) Pin
Ashfield27-Aug-08 2:33
Ashfield27-Aug-08 2:33 
GeneralRe: sql server (multplie column value as one row value) Pin
vjvjvjvj27-Aug-08 3:03
vjvjvjvj27-Aug-08 3:03 
GeneralRe: sql server (multplie column value as one row value) Pin
Ashfield27-Aug-08 3:09
Ashfield27-Aug-08 3:09 
QuestionAt a loss with stored procedure for SQL 2005 [modified] Pin
Sunset Towers26-Aug-08 13:58
Sunset Towers26-Aug-08 13:58 
AnswerRe: At a loss with stored procedure for SQL 2005 Pin
Mycroft Holmes26-Aug-08 14:25
professionalMycroft Holmes26-Aug-08 14:25 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.