Viewing 15 posts - 1,696 through 1,710 (of 2,171 total)
Ahhh! You put numeric data in the BETWEEN? Then SQL Server tries to convert the base data to the datatype in the BETWEENS.
I use Developer Edition of SQL Server 2005...
April 8, 2007 at 10:00 am
How can this error occur?
I don't do any type of conversion here!
The only reason for this, is that you don't post the full query. You must use this and put...
April 8, 2007 at 9:20 am
SELECT
*
FROM qSoldier
WHERE regNo NOT LIKE '%[^0-9]%'
AND regNo...
April 7, 2007 at 2:23 pm
I think some sample data and expected output would be nice.
April 7, 2007 at 2:18 pm
Yes, the last part posted above
SELECT
s.EmpID,
s.ManagerID
FROM @Sample AS
April 7, 2007 at 7:39 am
Try something like this!
-- Prepare sample data
DECLARE @Sample TABLE (EmpID VARCHAR(4
April 7, 2007 at 7:03 am
You also need to check, for example
Employee A reports to Employee B.
Employee B reports to Employee A.
or
Employee A reports to Employee B.
Employee B reports to Employee C.
Employee C reports to Employee...
April 7, 2007 at 6:48 am
Check for CIRCULAR REFERENCE!!!
Either an employee who has herself/himself as manager, or a larger chain fo managers that creates a "circle".
April 7, 2007 at 6:16 am
April 7, 2007 at 12:13 am
Jason, either is equally good for now.
But... If original poster (OP) wants to extend the query to include sum of total order amount for each line, my query is easier...
April 7, 2007 at 12:11 am
The derived table y you must replace with the aggregation for you OrderHead table.
April 6, 2007 at 2:20 pm
As long as you understand what the query do, it's fine.
Thanks. And good luck!
April 6, 2007 at 2:09 pm
Try this approach
SELECT Txt, Cnt FROM ( SELECT c.Txt, COUNT(*) AS Cnt, c.Sort FROM ( SELECT '$0-$10' AS Txt, -1 AS LowLimit, 10 AS HighLimit, 0 AS Sort...
April 6, 2007 at 2:03 pm
Viewing 15 posts - 1,696 through 1,710 (of 2,171 total)