Forum Replies Created

Viewing 15 posts - 616 through 630 (of 819 total)

  • RE: Order By Clause

    I immediately get it right, because I often fall in these kind of errors.

  • RE: Inserted Identity

    INSERTED pulls from what is entered into table, not from the select list.

    Of course!

  • RE: Exists

    OCTom (8/3/2011)


    ronmoses (8/3/2011)


    Carlo Romagnano (8/3/2011)


    EXISTS check if subquery returns ROWS and does not execute EXPRESSION or read column value. So, in this case divide by zero is never executed, but...

  • RE: Exists

    paul s-306273 (8/3/2011)


    DugyC (8/3/2011)


    Interesting question, and something definitely to be aware of.

    Thanks

    I'm not convinved that I need to be aware of this.

    Interesting question though.

    I agree with you.

  • RE: Exists

    EXISTS check if subquery returns ROWS and does not execute EXPRESSION or read column value. So, in this case divide by zero is never executed, but ONE ROW exists.

  • RE: How to use temporary table in function

    I like dirty "solutions". In extreme cases, I know that a way exists. 😀

  • RE: That case filter

    I would replace the question "How many rows returned by executing all of the following?" in "How many rows returned by the last SELECT?" and add another answer: "None, because...

  • RE: That case filter

    But if that is not the case then the answer should be "There is NO query returning rows."

    I agree with you!

  • RE: SELECT and WHERE without FROM

    Toreador (6/24/2011)


    I wonder which of the following (if either) is more efficient:

    select @a = 1 where @b = 0

    or

    if @b = 0 set @a = 1

    The best one seems to...

  • RE: SELECT and WHERE without FROM

    Toreador (6/24/2011)


    I wonder which of the following (if either) is more efficient:

    select @a = 1 where @b = 0

    or

    if @b = 0 set @a = 1

    "if" runs better

    declare @d datetime

    ,@a...

  • RE: SELECT and WHERE without FROM

    If the condition of the WHERE clause validates to true then the result set is returned. If it does not, the result set is empty.

    This is true only if...

  • RE: Bad Passwords

    Do you mean that for SA you get e.g. 2011-05-26 14:15:37 and for CARLO you get 1900-01-01 02:00:00?

    Yes, exactly!

  • RE: Bad Passwords

    michael.kaufmann (5/26/2011)


    Carlo Romagnano (5/26/2011)


    In sql2005, I tried with other logins than sa and I get always the following:

    1900-01-01 02:00:00.000

    Step 1: bad password attempt

    Step 2: correct login

    I run the query: SELECT...

  • RE: Bad Passwords

    -- to see all bad attempts

    SELECT l.name, loginproperty(l.name, 'BadPasswordTime')

    FROM sys.syslogins l

  • RE: Bad Passwords

    In sql2005, I tried with other logins than sa and I get always the following:

    1900-01-01 02:00:00.000

    Step 1: bad password attempt

    Step 2: correct login

    I run the query: SELECT loginproperty('carlo', 'badpasswordtime')

    The result:...

Viewing 15 posts - 616 through 630 (of 819 total)