Forum Replies Created

Viewing 15 posts - 1,396 through 1,410 (of 3,348 total)

  • RE: Getting Distinct

    Bob Cullen-434885 (1/23/2015)


    Hmm. Not sure about this. I tried select distinct * from mytable, and it returned all the rows, which was correct. So you can use * with distinct,...

  • RE: Distinct Counts

    DTML (1/22/2015)


    So, I would like to ask the more experienced SQL Server users the following question(s):

    (1) The default for the option ANSI_NULL_DEFAULT is off so, is this option typically changed...

  • RE: Distinct Counts

    DTML (1/22/2015)


    The only problem I have with this QoD, is that the INSERT statement fails as the column 'myid' does not allow nulls, as it is treated as a primary...

  • RE: COUNT NULLs

    g.britton (1/22/2015)


    Hugo Kornelis (1/22/2015)


    g.britton (1/22/2015)


    you may be right but the effect is exactly same so the fact that behind the scenes the process is different is probably irrelevant

    The shorter explanation...

  • RE: Distinct Counts

    jclementz (1/22/2015)


    Steve Jones - SSC Editor (1/21/2015)


    They return the same value. Althought COUNT does consider NULL rows, it does so only when the * is used. If an expression is...

  • RE: COUNT NULLs

    g.britton (1/22/2015)


    you may be right but the effect is exactly same so the fact that behind the scenes the process is different is probably irrelevant

    The shorter explanation is that your...

  • RE: IMPLICIT_TRANSACTIONS vs BEGIN TRAN

    Carlo Romagnano (1/22/2015)


    Hugo Kornelis (1/22/2015)


    Not too thrilled with this question. Lots of work and thinking for a feature that should have been deprecated and removed twenty years ago. Or failing...

  • RE: The Identity Limit

    After reading the discussion, I guess it's a good thing I didn't have time to answer when the question was first released.

    Got it right, thanks to other people complaining and...

  • RE: IMPLICIT_TRANSACTIONS vs BEGIN TRAN

    Shame - I am sure I selelcted the correct answers, but the site tells me I am wrong and that the correct answer is what I selected. (Or think I...

  • RE: COUNT NULLs

    g.britton (1/21/2015)


    Just though I'd dispel the notion that only count(*) counts nulls:

    select count('null') as count_null from (select null n union all select null) countnull

    returns:

    count_null

    2

    This code is not counting NULLs. The...

  • RE: Distinct Counts

    Too bad the explanation claims that NULL values are considered with * is used. Using * makes COUNT use rows, not values, and rows cannot be NULL.

    Other then that, the...

  • RE: IMPLICIT_TRANSACTIONS & BEGIN TRAN

    I never liked implicit transaction, and I never will.

    I am also glad that Carlo used PRINT, not SELECT. I thought that using SELECT would have started the implicit transaction, but...

  • RE: Error messages

    Jeff Moden (1/11/2015)


    Reminds me of a question I once saw on a non-MS exam...

    Which of the following Recovery Models will allow for minimally logged index rebuilds?

    A. Bulk Logged

    B. Bulk-Logged

    C. Bulk_Logged

    D....

  • RE: Filestream files

    Good question.

    What I missed in the explanation is that the filestream filegroup does have a physical path, but this is to a directory, not a file. And directories normally don't...

  • RE: NULL Aggregates

    jbwa (1/8/2015)


    Ditto

    The question asked if count would ignore values not ignore counting the row. I think the stated answer is wrong.

    Max, in effect, handles Nulls as a lower possible...

Viewing 15 posts - 1,396 through 1,410 (of 3,348 total)