Forum Replies Created

Viewing 15 posts - 4,711 through 4,725 (of 5,394 total)

  • RE: Running update problem

    Check this great article by Jeff Moden:

    http://www.sqlservercentral.com/articles/T-SQL/68467/

    It should do the trick for you.

    Regards

    Gianluca

  • RE: How to eliminate bad data

    It could be:

    SELECT SomeColumn

    FROM SomeTable

    WHERE LEN(Name) > 1

    AND LEN(Address) > 1

    AND LEN(Phone) > 1

    ... etc

    It depends on what you want to achieve. If you set those conditions in the where...

  • RE: This SqlTransaction has completed; it is no longer usable.

    It might not be the right answer, but check your code for DDL operations inside of TRY/CATCH blocks. Even if your code runs perfectly without a transaction when it gets...

  • RE: How to eliminate bad data

    SELECT SomeColumn

    FROM SomeTable

    WHERE LEN(SomeColumn) > 1

  • RE: Are the posted questions getting worse?

    Alvin Ramard (11/17/2009)


    Steve Jones - Editor (11/17/2009)


    That's funny. I wonder how many people will go there right away and not get it?

    Probably as many as the one that wouldn't do...

  • RE: Are the posted questions getting worse?

    Is Google down?

    No, it's working. I tried google.com and google.it and it seems to work.

    Dave, looks like a good thread for lmgtfy. 😀

  • RE: Count data using condition

    Now that I see Gail's reply I understand that you need it in one single row.

    Another way to achieve it is with PIVOT:

    SELECT [Active], [Inactive], [Total] = [Active] + [Inactive]

    FROM...

  • RE: Count data using condition

    ROLLUP is what you're looking for:

    DECLARE @TempTab TABLE (

    [ID] int,

    [Status] varchar(10)

    )

    INSERT INTO @TempTab VALUES (123, 'Active')

    INSERT INTO @TempTab VALUES (234, 'Active')

    INSERT INTO @TempTab VALUES (345, 'Inactive')

    INSERT INTO @TempTab VALUES (567,...

  • RE: Best way to pull data for Crystal Report

    No there isn't. The same applies to Crystal XI, just to be clear. The reporting engine has to know which columns will be returned by the procedure, so it makes...

  • RE: Is C# Better?

    Charles Kincaid (11/16/2009)


    Gianluca Sartori (11/16/2009)


    Which is better between C# and VB.Net? ....Uhmmmm.... Java! 😀

    No, seriously, it's just a personal choice. I like languages that force...

  • RE: Is C# Better?

    Which is better between C# and VB.Net? ....Uhmmmm.... Java! 😀

    No, seriously, it's just a personal choice. I like languages that force you to think in...

  • RE: Nested Select statement

    Edited: strange double post.

    Anyway you have to test against your DB to decide which one is faster. It depends on your indexes and volumes, there's no single good answer. Check...

  • RE: Nested Select statement

    There's at least two ways to achieve it. One is the code you posted, that can be changed to match the outer query and the subquery.

    The other way that comes...

  • RE: Are the posted questions getting worse?

    You could also help him with the ADSL line if he has issues uploading the screenshot. You should be quite expert...:-P

  • RE: Are the posted questions getting worse?

    Florian Reischl (11/12/2009)


    I completely confirm Jeff! Some random values are really important to ensure some fine tests.

    I prefer this method:

    😀

    :hehe::-D:hehe::-D:hehe::-D

    Thanks Flo for starting my day with a good laugh!

Viewing 15 posts - 4,711 through 4,725 (of 5,394 total)