Viewing 15 posts - 1,666 through 1,680 (of 3,957 total)
Isn't that just a LEFT JOIN?
SELECT a.Col1, a.Col2, a.Col3, a.Col4
FROM #TableA a
LEFT JOIN #TableB b
ON a.Col1 = b.Col1 AND a.Col2 = b.Col2 AND
...
July 23, 2013 at 6:53 pm
Here's another way that eliminates the need for the outer query:
SELECT TeamID, AssignedTask
,r=RANK() OVER (ORDER BY AssignedTask) +
...
July 23, 2013 at 6:45 pm
Let's start by correcting your DDL and sample data so that it will run in MS SQL (converted to temp tables to reduce clutter in my sandbox):
CREATE TABLE #TABLE_1
(
Field1...
July 23, 2013 at 6:27 pm
wolfkillj (7/23/2013)
Brandie Tarvin (7/23/2013)
dwain.c (7/23/2013)
1. There is a concept called (and forgive me for making this sound so formal) illusory superiority.
I don't know why you're making this reference in regards...
July 23, 2013 at 8:43 am
Brandie Tarvin (7/23/2013)
July 23, 2013 at 6:49 am
volkankoc2000 (7/23/2013)
my database sqlite
As this is a MS SQL forum, I couldn't help but make the assumption that your db is MS SQL.
I can't imagine there'd be much syntactical...
July 23, 2013 at 5:50 am
I'm as big an advocate of DelimitedSplit8K in the SQLverse as you're gonna find, but in this case I'd say there's a simpler way:
;WITH SampleData (ID,PartNumber)
AS
...
July 23, 2013 at 12:01 am
Oracle765 (7/22/2013)
select substring(expirydate,1,(charindex(' ',expirydate) -1)) as expirydate
from newtable
this query looks through my expiry date field and looks...
July 22, 2013 at 11:57 pm
LutzM (4/14/2010)
Maybe this link will be of some help, too:http://www.sqlservercentral.com/Forums/Topic679572-338-2.aspx
Barry did a great job explaining how the STUFF ... FOR XML PATH actually works.
SQLRNNR (4/15/2010)
July 22, 2013 at 8:56 pm
Matt,
Since you're new here, I'm going to help you out and show you how to post a question so as to get a decent answer. Articles abound throughout the...
July 22, 2013 at 8:30 pm
rackerland (7/22/2013)
SELECT C.Name, SUM(P.Total), SUM(O.Total)
FROM Customer AS C
LEFT OUTER JOIN [Order] AS O
ON O.CustomerID = C.CustomerID
...
July 22, 2013 at 7:52 pm
L' Eomot Inversé (7/22/2013)
Sean Lange (7/22/2013)
Gosh Tom, how do you really feel about that article??? :w00t:
Just as described, but if I'd realised who wrote it I would have made the...
July 22, 2013 at 6:35 pm
HanShi (7/19/2013)
create procedure search_row
(
@skills nvarchar(100) = null
, @position nvarchar(40) = null
, @location nvarchar(50)...
July 19, 2013 at 1:41 am
July 19, 2013 at 12:57 am
jace.bennett (7/18/2013)
Particulars of the projection aside, my original question was about how this style query plays with views....
July 18, 2013 at 8:47 pm
Viewing 15 posts - 1,666 through 1,680 (of 3,957 total)