Viewing 15 posts - 4,111 through 4,125 (of 10,144 total)
freecoder (8/20/2013)
oops! lol
Heh no worries 😀
Post back if you get stuck.
August 20, 2013 at 6:20 am
Never mind. Try this:
SELECT @retvalOUT = CONVERT(TINYINT,x.OutputColumn)
FROM [dbo].[SLADCSchedule]
CROSS APPLY (
SELECT OutputColumn =
CASE @DayOfWeek
WHEN 1 THEN Sunday
WHEN 2 THEN Monday
WHEN 3 THEN Tuesday
WHEN 4 THEN Wednesday
WHEN 5 THEN Thursday
WHEN...
August 20, 2013 at 6:18 am
Here's the query generated by your very strange code:
Select @retvalOUT = Convert(TinyInt,Sunday)
from [dbo].[SLADCSchedule]
where ScheduleStart <= 'Apr 1 2012 12:00AM'
and ScheduleEnd >= 'Apr 1 2012 12:00AM'...
August 20, 2013 at 6:12 am
Much the same question was posted here and another three or four threads on ssc in the last two or three weeks. Chopping and changing threads in this manner is...
August 20, 2013 at 5:38 am
dwain.c (8/19/2013)
SELECT set_id, product, attribute=CAST(item AS INT)
FROM (
SELECT set_id=MIN(set_id), product, allattributes
...
August 20, 2013 at 5:21 am
Hi Walton
How many sets will you have?
How many rows will each set have?
Thanks.
August 20, 2013 at 4:07 am
LinksUp (8/18/2013)
select d.name, d.packsize, doc.doctorname, doc.location
from Doctor_Prescribed_Drugs dpd
left join Doctor doc on dpd.doctorref = doc.doctorref
left join Drugs...
August 20, 2013 at 1:25 am
This looks straightforward. If you can set up the sample data as a CREATE TABLE/INSERT INTO script, I'm sure someone will help.
August 20, 2013 at 1:17 am
robert.gerald.taylor (8/19/2013)
ChrisM@Work (8/19/2013)
robert.gerald.taylor (8/19/2013)
SET @start = COALESCE(@startdate, DATEADD(yy, -1, @endDate), GETDATE());
SET @end = COALESCE(@enddate, DATEADD(yy, 1, @startdate), DATEADD(yy, 1,...
August 19, 2013 at 8:50 am
robert.gerald.taylor (8/19/2013)
SET @start = COALESCE(@startdate, DATEADD(yy, -1, @endDate), GETDATE());
SET @end = COALESCE(@enddate, DATEADD(yy, 1, @startdate), DATEADD(yy, 1, GETDATE()));
Seems cleaner...
August 19, 2013 at 7:19 am
vignesh.ms (8/19/2013)
Hi jethrow ..if the all the marks are same need to show all the column names
Here's a CROSS APPLY VALUES version. CAV is a longhand UNPIVOT, it's a little...
August 19, 2013 at 5:01 am
santhosh411 (8/19/2013)
Again i got this error today and this error came from the HP monitoring tool.I don't have any more details.
Why are you posting this in a SQL Server 2008...
August 19, 2013 at 4:28 am
sgmunson (8/18/2013)
Anyway, you appear to...
August 19, 2013 at 3:35 am
Viewing 15 posts - 4,111 through 4,125 (of 10,144 total)