Forum Replies Created

Viewing 15 posts - 286 through 300 (of 8,416 total)

  • RE: Time as a high precision difference of dates

    Updated my SQLCLR function to produce the results needed in this thread:

    [font="Courier New"]

        public static TimeSpan GetIntervalAsTime(DateTime Start, DateTime End)

        {

            return

                (Start <= End) ?

                End.Subtract(Start) :

                End.AddDays(1).Subtract(Start);

        }

    [/font]

    Test data:

    With MyCTE (ID, aTime, bTime)

    AS

    (

    SELECT 1, CONVERT(datetime2,'1900-01-01...

  • RE: Time as a high precision difference of dates

    ScottPletcher (9/7/2012)


    TimeResult1 = -- ChrisR (5 date functions, 2 datatype conversions)

    TimeResult2 = -- ChrisM (5 date functions, 2 datatype conversions)

    ...

  • RE: UPDATE when the values are the same

    Sergiy (9/7/2012)


    Because if I'd see anything what would show CLEARLY "that there is NO ROW MODIFICATION where the object of the update is unchanged" I'd happily accept it.

    In SQL Server...

  • RE: UPDATE when the values are the same

    Sergiy (9/7/2012)


    Because if I'd see anything what would show CLEARLY "that there is NO ROW MODIFICATION where the object of the update is unchanged" I'd happily accept it.

    Try this:

    USE tempdb;

    GO

    IF...

  • RE: Release Total Server Memory in SQL 2008

    sqldba4u (9/7/2012)


    Max and Min memory have been setup and few GBs are left for OS. Clearing up cache is not releasing server memory.

    Why do you want to 'release server memory'?

  • RE: select * returning no rows , but select 1 returning the result from a table selection

    Usman Butt (9/7/2012)


    I would also run DBCC against such databases, and if the corruption is the problem then would look into the root cause. But that is only me 🙂

    DBCC...

  • RE: UPDATE when the values are the same

    Sergiy (9/7/2012)


    MissTippsInOz (9/7/2012)

    You have had numerous genuine responses from people who are trying to help you to understand the behaviour of a 'non-updating update'. You have been given code...

  • RE: UPDATE when the values are the same

    Sergiy (9/7/2012)


    SQL Kiwi (9/7/2012)


    I have said, over and over again, that I don't know whether the in-memory page is written to or not. A page that is exactly...

  • RE: UPDATE when the values are the same

    Sergiy,

    If the only point you are trying to make is that non-updating updates do write to a clustered index or heap page (without changing it in any way) I will...

  • RE: UPDATE when the values are the same

    Sergiy (9/7/2012)


    Key word - changes. No matter if it's rolled back - there was a change. IO operation.

    Even if everything remained like it was before - there was a...

  • RE: UPDATE when the values are the same

    Sergiy (9/7/2012)


    SQL Kiwi (9/7/2012)


    If you don't stop being snarky in your replies

    You may notice I just quoted you. Word to word.

    And that is exactly the problem. My question...

  • RE: UPDATE when the values are the same

    Sergiy (9/7/2012)


    So, there are modifications? SQL Server givees you another prove that the row is actually written to. Can you agree now?

    A modification counter used by statistics update...

  • RE: UPDATE when the values are the same

    Sergiy (9/6/2012)


    SQL Kiwi (9/6/2012)

    The logical update operation.

    What exactly is logical update operation and what other kind of update operatios are there?

    I am trying to help you distinguish between a logical...

  • RE: UPDATE when the values are the same

    Sergiy (9/6/2012)


    Is it your case? "Potentially updating resources"? So, why don't we see U locks in our examples?

    Update locks are taken when reading rows that might qualify for a change...

  • RE: UPDATE when the values are the same

    Sergiy (9/6/2012)


    You said there is no update because SQL Server can figure out that the is no change in data before hand and do not proceed with any update. ...

Viewing 15 posts - 286 through 300 (of 8,416 total)