Forum Replies Created

Viewing 15 posts - 256 through 270 (of 5,503 total)

  • RE: Simulate message poisoning in Service Broker

    A poisoned message is a message leading to an error because of the message itself and not a database condition.

    For instance, a message leading to a deadlock is not a...

  • RE: Error altering field spec in a table

    It seems like you mixed the NULL and NOT NULL terms in your post... (e.g. 4 rows were not null, we changed it to NULL)

    What is the result of the...

  • RE: Cursor fetch loops endlessly

    The STATIC option basically does exactly what you described as "your own cursor": it makes a copy of the cursor definition in tempdb

    The set based solution we're talking about would...

  • RE: SQL Server 2012 licensing options

    The term "user" refers to a person sitting in front of a PC.

    A "device" is a system not directly used or influenced by a person (e.g. a robot in a...

  • RE: Cursor fetch loops endlessly

    Just a probably totally silly question:

    What is the CURSOR_DEFAULT database setting for the DB in question?

    Reason for asking:

    If it's set to GLOBAL and you're not specifically declare the c.u.r.s.o.r. *cough*...

  • RE: How will get distinct records in SQL table?

    I don't think a simple DISTINCT will do it since it would return two rows ("Test." and "Test..") where one ("Test") is expected.

    Maybe one of the following approaches will work:

    SELECT...

  • RE: i want to have my primary key as out put , when i insert a record!

    nazaninahmady_sh (12/28/2013)


    I really wish that our friends in this forum , FIRST READ CAREFULLY THE QUESTIONS AND THEN ANSWER.

    I herewith apologize to provide an additional information on how to improve...

  • RE: SQL 2008 R2 and custom application built with C# very slow query times causing errors and timeouts

    Banks, do you have a detailed description what has been changed compared to the previous version (that seems to have performed as expected)? Especially in terms of communication between app...

  • RE: Sql Server Express 2008 R2 Error on XP but not on Windows 7

    Did you verify that all files (data and log files) are succesfully copied to the very same folder (and drive!)?

    It seems like the log file either does not match the...

  • RE: Need to Merge text in a cell

    You could split the string using the Delimited Split Function refernced in my signature and the "FOR XML PATH" approach together with a DISTINCT to build te final string.

    If the...

  • RE: Problem with Dates !!!!!!!!!!!!

    I strongly vote against a NVARCHAR data type to store date values (especially, with a length of 50 characters being allowed).

    What's the reason for using NVARCHAR instead of DATETIME?

  • RE: How will get distinct records in SQL table?

    Would you mind being a little more specific?

    What is the "business logic" to get to the result you're looking for?

    It's unknown, whether the value is "2.Test." or "Test.".

    It is also...

  • RE: Complex Query

    alhakimi (12/26/2013)


    waiting for your kind help

    Sending a "reminder" just a few minutes after the original post implies some kind of urgency on your side...

    But you might want to respect that...

  • RE: Get MAX Timestamp

    Here are two more alternatives:

    more than one Server:

    ;

    WITH cte AS

    (

    SELECT DISTINCT ServerName FROM #Time

    )

    SELECT sub.MaxTime, sub.Status, sub.ServerName

    FROM cte

    CROSS APPLY

    (

    SELECT TOP 1 t.Date AS MaxTime,t.Status,t.ServerName

    FROM #Time t

    WHERE t.ServerName=cte.ServerName

    AND Date >= '12/1/2013'...

  • RE: Concept of Data and Index pages

    I recently came across an index defintion I thought to be inefficient:

    CREATE TABLE myTable (myId INT IDENTITY(1,1))

    CREATE CLUSTERED INDEX weird_index ON myTable(myId DESC)

    The reson for being inefficient from my point...

Viewing 15 posts - 256 through 270 (of 5,503 total)