Forum Replies Created

Viewing 15 posts - 646 through 660 (of 2,458 total)

  • RE: Function to get Number from word

    If you go the mapping table route do a search for "cardinal ordinal number list" or "... chart"... You may get lucky as someone out there may have already done...

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: SQL Calendar Table based on Start and End Date Help

    For a work-table free, sort-free, purely set-based way of handling this you could use getnumsAB[/url] and do this:

    DECLARE @STARTDATE DATETIME = '06/05/2016',

    @ENDDATE...

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: T-SQL find unique records

    durga.palepu (6/13/2016)


    Thanks, that's awesome solution.

    Your approach to provide hints so that I would work on actual solution is excellent so that I could learn my self.

    Here follow's my solution implementations:

    using...

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: FOR XML PATH

    Just to add to what R.P. Rozema said...

    Here is a good article about this technique for concatenating a string using this method: Creating a comma-separated list (SQL Spackle)[/url].

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: Join of two tables with sums of two different fields grouped by CustomerID

    briancampbellmcad (6/13/2016)


    I'm not following the placing of the literal amounts into the SQL. Shouldn't I just be using field names

    He's putting the example data into CTEs... It's the same as...

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: DBA career advice

    MikeS. (6/10/2016)


    It's funny you should bring up the subject of 'nolock' -- at most places I've worked, it's a big no-no. At my current job, you'll get your hand...

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: UDF slow even when used as a persisted computed column

    Comment removed.

    I missed the whole second page of this discussion...

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: Nasty Fast PERCENT_RANK

    Mike Is Here (6/9/2016)


    Great article.

    Thank you very much. πŸ˜€

    So now we know the window aggregate function is the culprit. Since we’re not partitioning the data yet (but will in a...

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: How Long Before Your Database Runs Out of Space?

    Nice article John. Well done.

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: Stairway To SQL Server Columnstore Indexes Level 1: A First Look At Columnstore Indexes

    Great article Hugo. Very well researched and written. I just started the series and look forward to the rest.

    I have neen reading up on columnstore indexes recently and just read...

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: Nasty Fast PERCENT_RANK

    Jeff Moden (6/7/2016)


    From the Article:


    Bring on the one million row test harness!!!

    Heh... I love it! It's like a war cry! πŸ˜€

    Very cool article, Alan. Well done.

    Hat's off...

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: Nasty Fast PERCENT_RANK

    Ken Hiatt (6/7/2016)


    Thanks Alan, it's always fun to learn faster ways to do things, even if it's not something I expect to be using πŸ™‚

    While my SQL programming skills are...

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: Nasty Fast PERCENT_RANK

    Thank you Kevin and Mauricio.

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: Nasty Fast PERCENT_RANK

    Thanks Eirikur!

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

  • RE: UDF slow even when used as a persisted computed column

    Lowell (6/6/2016)


    DennisPost (6/6/2016)


    Hi Lowell,

    Thanks for taking the time to read and reply.

    That approach won't work for us as the server is set to UTC and we need to be able...

    "I cant stress enough the importance of switching from a sequential files mindset to set-based thinking. After you make the switch, you can spend your time tuning and optimizing your queries instead of maintaining lengthy, poor-performing code."

    -- Itzik Ben-Gan 2001

Viewing 15 posts - 646 through 660 (of 2,458 total)