Forum Replies Created

Viewing 15 posts - 1,801 through 1,815 (of 5,504 total)

  • RE: Help me asap pleas

    Please help us help you by providing ready to use test data, including table def and sample data (especially if your request is "urgent"...). For the best way on how...

  • RE: CXPACKET/Parallelism question

    SQLkiwi (3/4/2011)


    Ok, so the first part of my parallelism article went out a couple of days earlier than I expected :blush:

    Link: http://www.simple-talk.com/sql/learn-sql-server/understanding-and-using-parallelism-in-sql-server/

    What a fantastic article!!! GREAT job Paul! Thank you...

  • RE: Using Cross tab updates in SQL2008

    I would recommend to perform the pivot at the application layer including the steps required to get the changed values out of the GridView and update the data in the...

  • RE: Help in trigger

    You could use UNPIVOT to transform the columns into rows for the new and updated rows and select only those where the values don't match.

    If this would have too much...

  • RE: Table Scan

    To squeeze even more performance out of it you could consider changing the data types from DATETIME to SMALLDATETIME (if the business case would allow for it).

    This would reduce the...

  • RE: T-SQL Cursor Puzzle

    ColdCoffee (3/4/2011)


    ...

    Hmmm, yeah , Lutz ; But i and Jeff can meet as we are in the same continent 🙂 I am in the US for an assignment. I am...

  • RE: How to efficiently copy million images from one table to another.

    duplicate post. no replies please.

    Discussion already started here

  • RE: How to sort using DateTime

    gemni7 (3/4/2011)


    Hi LutzM,

    I have a question about Exclusive Table Lock. What would be SQL servers behavior if my application open connection to insert data into same table while exclusive table...

  • RE: How to find average, min, max for time field

    Something like this?

    SELECT

    id,

    uri,

    CAST(DATEADD(ss,AVG(DATEDIFF(ss,0,response_time)),0) AS TIME) AS avg_response_time

    FROM #URL_Requests

    GROUP BY id,uri

    You cannot average a time data type. Therefore, it needs to be converted into...

  • RE: giving error for the calculation

    I think the root cause is a cte definition issue (or a design issue in general).

    Instead of add up various columns based on a certain limits value you should normalzie...

  • RE: T-SQL Cursor Puzzle

    Jeff Moden (3/4/2011)


    Thank you very much for the feedback... but Lutz set the stage to avoid RBAR using some very high performance code. All I did was tweek his...

  • RE: Table Scan

    Why not changing the query to get rid of the UNION?

    The only difference I see between the two UNIONed SELECTs is the value of free_runner. And this would be identical...

  • RE: Stored Proc to send an Email?

    You probably should start with searching BOL for sp_send_dbmail.

  • RE: T-SQL Cursor Puzzle

    Thank you! :blush:

    What needs to go into the ORDER BY clause of ROW_NUMBER() is sort of unclear based on the data provided so far:

    If there will ever be a chance...

  • RE: T-SQL Cursor Puzzle

    Something like this? (assuming the table is called #t and the column is col)

    ;

    WITH cte AS

    (

    SELECT col,

    CAST(STUFF(col,1,1,'') AS INT) - ROW_NUMBER() OVER(ORDER BY col ) AS grp

    FROM ...

Viewing 15 posts - 1,801 through 1,815 (of 5,504 total)