Forum Replies Created

Viewing 15 posts - 1,816 through 1,830 (of 2,462 total)

  • RE: Growing Your SQL Server Skills without Breaking the Bank

    Koen Verbeeck (8/5/2013)


    Great overview. I'll refer to this post every time someone asks for free training 😀

    Ditto that. Me too!

    "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: Parsing HTML to SQL using SQLDOM

    taylor_benjamin (12/29/2014)


    This is a really cool exercise. However, it should remain simply that.

    SQL is not HTML

    HTML is not SQL

    I can't believe nobody else has raised a warning flag on...

    "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 Server 2014 Checklist for Performance

    Sorry if I am repeating what anyone else said - I have not had a chance to read through all the comments. Here's my 2 cents:

    Normalize the data as it...

    "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: Parsing HTML to SQL using SQLDOM

    Great article. We'll done sir!

    I do, however, disagree a little with this line (emph. mine)...

    But HTML is often not well-formed XML. Some tags are "singleton" tags--that do not require end...

    "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: reset running total to x amount

    CELKO (12/22/2014)


    Please follow basic Netiquette and post the DDL we need to answer this. Follow industry and ANSI/ISO standards in your data. You should follow ISO-11179 rules for naming data...

    "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: Use LIKE in SQL SERVER to XML record

    I believe this could be done more efficiently using the XQuery Substring method but I could not quickly figure out how.

    In the meantime, here's a solution...

    -- (1) create...

    "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: reset running total to x amount

    I have a partial solution, that will get you in the right direction. I created some DDL for you. This solution is based on the technique described in this article:...

    "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 to resize an SSRS report with a 0 height page footer

    No prob. Glad to help. 😎

    "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 to resize an SSRS report with a 0 height page footer

    Back up your RDL before doing this...

    In Visual Studio right-click on the report and select "View Code". In the code you will see a footer section. I'm pretty sure...

    "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: Digits only

    Eugene Elutin (12/11/2014)


    Alan.B (12/10/2014)


    I'm curious (general question to everyone)...

    Wouldn't this be faster?

    -- the function

    CREATE FUNCTION dbo.DIGITSONLYAB(@pstring varchar(8000))

    RETURNS TABLE WITH SCHEMABINDING AS

    RETURN SELECT ISALLDIGITS = CASE PATINDEX('%[^0-9]%',@pstring) WHEN 0...

    "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: Digits only

    I'm curious (general question to everyone)...

    Wouldn't this be faster?

    -- the function

    CREATE FUNCTION dbo.DIGITSONLYAB(@pstring varchar(8000))

    RETURNS TABLE WITH SCHEMABINDING AS

    RETURN SELECT ISALLDIGITS = CASE PATINDEX('%[^0-9]%',@pstring) WHEN 0 THEN 1 ELSE...

    "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 to format unformated phone numbers Please...,

    Using this PatReplace8K function:

    CREATE FUNCTION dbo.PatReplace8K

    (

    @String VARCHAR(8000),

    @Pattern VARCHAR(50),

    @Replace VARCHAR(1)

    )

    /*

    Created by Alan Burstein Nov(ish)/2014

    With help by Eirikur Eiriksson 😉

    */

    RETURNS TABLE WITH SCHEMABINDING

    AS

    RETURN

    WITH E1(N) ...

    "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: Question on Stored Procedure

    Sean Lange (12/9/2014)


    Alan what you posted is almost exactly what I had envisioned. I refrained from posting simply because this seems so much like homework. Let's hope the OP reads...

    "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: Question on Stored Procedure

    I put something a little more simple together.

    USE tempdb

    GO

    -- Sample Data

    IF OBJECT_ID('tempdb..items') IS NOT NULL DROP TABLE items;

    CREATE TABLE items (Price int);

    GO

    INSERT items

    SELECT ABS(CHECKSUM(newid()))%10+6--5 to 15

    FROM (VALUES (NULL),(NULL),(NULL),(NULL)) t(c);

    GO

    --...

    "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: Using variable to evaluate part of file name?

    Removed... (Did not see that this was an Integration Services thread). What I put together would be wrong. :doze:

    "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 - 1,816 through 1,830 (of 2,462 total)