Viewing 15 posts - 1,891 through 1,905 (of 2,458 total)
Steve Jones - SSC Editor (9/10/2014)
Jeff Moden (9/10/2014)
Solomon Rutzky (9/9/2014)
In the end, isn't this why Microsoft gave us CLR Integration?
Heh... yeah... just like they gave us the ability to write...
September 10, 2014 at 9:33 am
I will also recommend Gail's article.
The logic for your query will look like this (note that you did not detail the expected behavior for if only @enddate has a...
September 10, 2014 at 9:31 am
IF @user > '' --This checks for not null and not empty
Cool. I never knew you could do that, very interesting :laugh:
Edit: sql code tag messed up my "greater than"...
September 9, 2014 at 10:51 pm
Ok, I had a few minutes to kill. There will be a little more work to get this to work with what you have done thus far.
The Function:
CREATE FUNCTION...
September 9, 2014 at 8:34 pm
I don't have access to a pc at the moment otherwise I would give a better example...
You could accomplish this using a splitter and splitting the strings using the space...
September 9, 2014 at 7:25 pm
To be fair, Microsoft did give us master data services which has a CLR udf splitter (an awful one) that still requires enabling CLR on so most DBAs just say...
September 9, 2014 at 2:54 pm
First, for what it's worth - I started as a network guy and moved into SQL because I loved it (I liked Cisco). I even took a little pay cut...
September 4, 2014 at 9:22 am
gbritton1 (9/3/2014)
select * from dbo.[DelimitedSplit8K](' ', ' ')...
September 3, 2014 at 1:07 pm
I am having some problem understanding joins (Specially left,right and outer apply)when it comes to more then 3 tables.... which result set is formed first and then second...
When you join...
September 2, 2014 at 1:01 pm
First I would see if the query returns anything when you replace
o.StatusID in (Select osl.val from dbo.SplitStringToIntegerArray(@OrderStatusList, ',') osl ) and
o.OrderTypeID = 1
with
where o.OrderTypeID = 1
If you...
September 2, 2014 at 12:21 pm
If I understand your question correctly you need to do what is referred to as a Left Anti Join Semi Join.
There are a couple ways you can do this:
DECLARE...
August 12, 2014 at 5:15 pm
The company I work for has offices in a lot of markets (Seattle, NY, San Fran, Chicago, Houston, L.A., etc...). I have seen compensation fluctuate a lot based on cost...
August 12, 2014 at 2:49 pm
SSAS is the Analysis part of the Microsoft BI stack (SSRS, SSIS and SSAS). Pre-2012 the only components were OLAP cubes (Dimensional model) and Data mining. In 2012 they...
August 12, 2014 at 10:01 am
First let's create a function called topn...
CREATE FUNCTION topn(@n int, @x int)
RETURNS TABLE AS
RETURN
(
WITH
E1(n) AS (SELECT 1 FROM (VALUES (1),(1),(1),(1),(1),(1),(1),(1),(1),(1)) t(n)),--10
E2(n) AS (SELECT 1 FROM E1 a CROSS JOIN...
August 11, 2014 at 6:56 pm
Just a quick note about duplicates.
If the possibility exists for duplicate values then you would use DENSE_RANK instead of ROW_NUMBER. In the examples below I took Lutz' code...
August 11, 2014 at 4:07 pm
Viewing 15 posts - 1,891 through 1,905 (of 2,458 total)