Forum Replies Created

Viewing 15 posts - 4,771 through 4,785 (of 5,502 total)

  • RE: How do I extract numbers from a text field?

    @jeff:

    Well, I didn't post it for three reasons:

    1) The function I'm using is mostly copied from one of the articles I referred to several dozen times in other posts so...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Are the posted questions getting worse?

    Sorry to interrupt with a different subject:

    It looks like the RAQ Report promoter is back (he/she must have been too busy over the last month ;-)).

    If you...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Update statement get executed but table remains the same

    SQL Server does exactly what you told to do:

    update #TempTotalTable

    set NoOfCol = NoOfCol

    from #ColumnPerTable

    where #TempTotalTable.TBName = #ColumnPerTable.TBName

    This basically means to update NoOfCol with its original values, resulting in a unchanged...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: How do I extract numbers from a text field?

    Attached please find a sample code.

    Some notes:

    If you already have a unique value (like an ID) assigned to each row, the first CTE can be omitted.

    Also, if you can guarantee,...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: RiskIdShortName IN (select * from dbo.fn_ParseString2(@P_RISKID,','))

    I think if you need somebody to work on more than (!!)1100(!!) lines of code, you should get a consultant in to help you.

    If you'd like us to help you...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: How do I extract numbers from a text field?

    Would you please provide a (few) sample line(s) and your expected result?

    Would make it easier for some of than talking plain theory...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Split a single Record into multiple lines

    Peter Brinkhaus (11/13/2009)


    I did that test also. It requires less coding but, based on the 3 rows input, there are less rows generated within the cross apply to join with...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Minor Error during Insert

    Is there any specific reason to make the table name colum wider than it ever can get and at the same time making the DBname smalller than it might get?

    I...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: How to Prevent DBA's from viewing the data

    GSquared (11/13/2009)


    If you can't trust your DBAs with the data, for whatever reason, then you need to encrypt it. It's as simple as that.

    It's nothing more than that. But...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Split a single Record into multiple lines

    Just a tiny change to Peters excellent sample:

    I moved the WHERE clause from the UNION ALL part to the outer part of the query.

    Performance seems to be the same (query...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: row as column

    Well, we're getting closer...

    Following please find a proposal:

    SET dateformat dmy

    SELECT Emp_Id,

    MAX(CASE

    WHEN [Shift_Date] = '12/11/2009'

    THEN ISNULL(Shift_Regular,'')

    + CASE

    WHEN Shift_OnCall IS NOT NULL

    THEN ' and ' +ISNULL(Shift_Regular,'')

    ELSE...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Minor Error during Insert

    Seems like you have database and/or table names that are longer than the 50 char you defined for your temp table.

    As per BOL

    database_name can be a maximum of 128 characters

    table_name...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Is there anyother way to eliminate the BOOKMARK LOOKUP , a part from changing the Indexes

    I wonder why you focus on not having that bookmark lookup - there might be other ways to help performance, too...

    Example:

    What is the reason to do a sum aggregation over...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: row as column

    sudarsanan.kaliyamurthy (11/13/2009)


    I have attached the sample data and the required table.

    Well, doesn't really look like it...

    A table definition would be something along CREATE TABLE... and sample data would be INSERT...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • RE: Summarise multiple columns to a single results Column - Are there better ways than this? (Fx Trade Amounts to Exposures)

    Do you have any chance to modify the table structure?

    It would be a lot easier to query if you'd have a table with

    ID, DateValue, Curr, and Amt.

    To differentiate between...



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

Viewing 15 posts - 4,771 through 4,785 (of 5,502 total)