Viewing 13 posts - 16 through 28 (of 28 total)
Now above that I have
And ((
Case
when @SoldYN = 'Y'
then (
(SELECT COUNT(Distinct(A2.ParentActivityID))
FROM Activities A2
...
April 8, 2011 at 12:58 pm
and
((
case
when @ActivityStatusID = 1
then ACS.[Description] = 'Completed'
when @ActivityStatusID <> 1
then ACS.[Description] <> 'Completed'
)
or @ActivityStatusID is null)
END
I still get Msg 102, Level 15, State 1, Line 369
Incorrect syntax near '='.
April 8, 2011 at 12:55 pm
Sorry but no joy, I get Incorrect syntax near '='. Samething for the else
April 8, 2011 at 12:54 pm
@ActivityStatusID is a paramater I am passing in.
If it is a 1 then I want to:
Select all where ... AND ACS.Description = 'Completed' --gets all that are completed
OR...
April 8, 2011 at 12:48 pm
The sample Lowell sent works just fine.
Thanks Lowell, and Derrick.
KS
September 28, 2010 at 9:00 am
Ideally I would want my results to be
agentcode agentname
1 Nolrick1
But any name...
September 28, 2010 at 8:46 am
I am using windows 7 64bit. And yes I ran windows add/remove.
I'll try ccleaner.
Thanks,
KS
September 22, 2010 at 6:19 am
SELECT orderid, orderdate, custid, empid
FROM Sales.Orders
WHERE orderdate = DATEADD(month, DATEDIFF(month, '19991231', orderdate), '19991231');
--Here our orderdate field is year, month, day
December 7, 2009 at 12:24 pm
Your a god send. You rock thanks very much.
January 22, 2009 at 12:07 pm
Forgive my ignorance, but how?
The only commonality between the two tables is the timestamp.
January 22, 2009 at 12:02 pm
One more thing. My initial problem was I left out teh weather location in the where clause.
Once I added that then all my figures were correct.
But another issue had popped...
January 22, 2009 at 11:47 am
Viewing 13 posts - 16 through 28 (of 28 total)