Viewing 15 posts - 2,986 through 3,000 (of 3,957 total)
So what happens next when someone comes along and runs:
INSERT INTO @PhoneTable_New
(phone, phonecount, contactname, contactnamecount, tablesource)
SELECT '003', '0', 'Mr Jones', '0', 'contactperson'
Do...
August 21, 2012 at 7:53 pm
Stefan Krzywicki (8/21/2012)
dwain.c (8/21/2012)
Yesterday I was called...
August 21, 2012 at 7:12 pm
Steve Jones - SSC Editor (8/21/2012)
Brandie Tarvin (8/21/2012)
At my workplace, we forbid the Devs to use cursors. It's part of our db standards. Any time they want to go against...
August 21, 2012 at 7:05 pm
WayneS (8/21/2012)
dwain.c (8/21/2012)
Yesterday I was called upon...
August 21, 2012 at 7:02 pm
SQL Kiwi (8/21/2012)
dwain.c (8/21/2012)
August 21, 2012 at 4:00 am
SQL Kiwi (8/21/2012)
dwain.c (8/21/2012)
August 21, 2012 at 3:43 am
Jeff Moden (8/9/2012)
I have to tell you that if you haven't gone to one of these...
August 21, 2012 at 2:40 am
GilaMonster (8/21/2012)
Cursors are tools. Use them where they work, don't use them where they don't. Statements like 'you should never use a <whatever>' are just shortsighted
If we count while loops...
August 21, 2012 at 2:27 am
ChrisM@Work (8/21/2012)
dwain.c (8/21/2012)
Yesterday I was called upon...
August 21, 2012 at 1:46 am
You don't actually need to split the strings as long as they're all unique and don't contain substrings of each other:
;WITH SampleData (UserID, WhatTechnology) AS (
SELECT 1,'home,car'
UNION ALL SELECT 2,'home,car,dj'
UNION...
August 21, 2012 at 1:36 am
The first thing that I would do is improve the readability of your query (slightly) by rewriting it as:
;WITH main AS (
SELECT pat1.PatID, pat1.DocID, pat1.Site, doc.RefDate, doc.Report
FROM PatMapTable AS pat1...
August 21, 2012 at 1:18 am
Will this work for you?
SELECT acc_no, [count]=COUNT(number), c_name=MAX(c_name)
, R_Value=SUM(R_Value), time_spent=SUM(time_spent)
FROM #TESTING
GROUP BY acc_no
August 21, 2012 at 1:02 am
Not sure but you may be able to do something like this assuming there is no overlap in dates in your @Vehicle_Depreciations table:
;WITH Tally (n) AS (
SELECT TOP 1000 ROW_NUMBER()...
August 21, 2012 at 12:55 am
It has been a rare experience for me to post a question to this forum, but I will now. How about a poll?
Yesterday I was called upon to go...
August 21, 2012 at 12:03 am
Great article Gus!
I haven't had a chance to play around with HiearchyIDs myself yet but I must put it on my agenda to try it out. And your examples...
August 20, 2012 at 11:54 pm
Viewing 15 posts - 2,986 through 3,000 (of 3,957 total)