Viewing 15 posts - 901 through 915 (of 3,957 total)
Sean Lange (1/16/2014)
pooja.sharma 54426 (1/16/2014)
Please create an empty database and run following sqls.Add some data into them .
Nice job posting the ddl. Can you post some data? Remember we are...
January 16, 2014 at 5:32 pm
raghuldrag (1/16/2014)
Thanks for ur reply.....
i need the o/p like each item wise (i.e you wrote the code for max item ,
now each item...
January 16, 2014 at 4:38 am
Sorry to tell you this but I don't open zip files from unknown sources (virus-phobia).
Post the SQL in line using the SQL code tag to make it pretty.
January 16, 2014 at 3:57 am
pooja.sharma 54426 (1/15/2014)
select @cols = STUFF((SELECT distinct ',' + QUOTENAME(c.propName)
...
January 15, 2014 at 11:47 pm
Maybe this will help then.
CREATE TABLE #TxCycle(
Cycle INT NOT NULL,
PatientID INT NOT NULL,
ALOPECIA TINYINT,
Causality1 TINYINT,
Relatedness1 TINYINT,
ANEMIA TINYINT,
Causality2 TINYINT,
Relatedness2 TINYINT,
BLOOD TINYINT,
Causality3 TINYINT,
Relatedness3 TINYINT);
SELECT OBJECT_ID('tempdb..#TxCycle')
SELECT name
FROM tempdb.sys.all_columns
WHERE object_id = OBJECT_ID('tempdb..#TxCycle') AND...
January 15, 2014 at 11:42 pm
pooja.sharma 54426 (1/15/2014)
I am not getting how to use Table valued functions as columns that i need to fetch are not constants rather they are dynamic "' + @cols +...
January 15, 2014 at 11:04 pm
pietlinden (1/15/2014)
CREATE TABLE #TxCycle(
Cycle INT NOT NULL,
PatientID INT NOT NULL,
ALOPECIA TINYINT,
Causality1 TINYINT,
Relatedness1 TINYINT,
ANEMIA TINYINT,
Causality2 TINYINT,
Relatedness2 TINYINT,
BLOOD TINYINT,
Causality3 TINYINT,
Relatedness3 TINYINT);
The one thing I was wondering was this: how do I...
January 15, 2014 at 10:59 pm
pooja.sharma 54426 (1/15/2014)
Actually my function is returning a dynamic query .
Step 1 : Create a function returning property names in CSV format
Create FUNCTION dbo.fxnGetPropertyColsQuery
(
)
RETURNS NVARCHAR(MAX)
AS
BEGIN
declare @Return ...
January 15, 2014 at 10:47 pm
pietlinden (1/15/2014)
CREATE FUNCTION [dbo].[GenerateCalendar]
(
@FromDate...
January 15, 2014 at 10:41 pm
JackG (1/14/2014)
I hope you used the CROSS APPLY VALUES approach to UNPIVOT.
You can read about it in the first article in my signature links.
I did do unpivot. I'll check...
January 14, 2014 at 9:06 pm
JackG (1/14/2014)
I unpivoted the start & end date into one date column. (had to group them to eliminate duplicates for some records) I...
January 14, 2014 at 8:50 pm
Grant Fritchey (1/14/2014)
dwain.c (1/14/2014)
Grant Fritchey (1/14/2014)
DTA!!!!!!Burn it with fire!!!
And here I thought I was the only one that felt this way. 😛
Nope. And I'm starting the rewrite on the...
January 14, 2014 at 6:35 pm
Grant Fritchey (1/14/2014)
Sean Lange (1/14/2014)
Yesterday my supervisor sent me an email regarding a view...
January 14, 2014 at 5:04 pm
Sean Lange (1/14/2014)
Of course those temp tables will be dropped implicitly when the connection closes. I know you know that but I mention it for the sake of completeness.
True enough....
January 14, 2014 at 5:01 pm
Viewing 15 posts - 901 through 915 (of 3,957 total)