Forum Replies Created

Viewing 15 posts - 736 through 750 (of 807 total)

  • RE: SSRS case sensitivity

    stewartc-708166 (2/22/2010)


    Good question.

    Please do not post useless thinks.

  • RE: Finding the Correct Weekday Regardless of DateFirst

    The main problem is not the format of date (dmy or mdy or ymd) nor if monday is the first day of the week, but identify the day '2010-2-1' as...

  • RE: Finding the Correct Weekday Regardless of DateFirst

    This code is indipendent from datefirst:

    Monday is 0 and Sunday is 6

    SELECT cast(cast('20100215' as datetime) as int)%7

    SELECT cast(cast('20100216' as datetime) as int)%7

    SELECT cast(cast('20100217' as datetime) as int)%7

    SELECT cast(cast('20100218' as datetime)...

  • RE: Easy Error Trapping When Using xp_cmdshell

    create table XPCmdShellOutput (OutputLine varchar(1000), ID INT IDENTITY(1,1))

    Please add an identity column, so you can have output lines in the correct order

  • RE: Rowcount

    If one omits the set nocount on statement, then the results would be 1,1.

    This assert is wrong.

    The correct answer is 0,1, but the two statement should be the first in...

  • RE: Query cost

    Volumes of data returned from tables may vary (test or production database), so a well performing query may slow down or give an error.

    FROM BOL:

    Including an extremely large number...

  • RE: Replication

    My answer is correct, but it's luck!

    The text of the question is incomprehensible and the explanation is more and more incomprehensible.

  • RE: SELECT @local_variable

    If the SELECT statement returns no rows, the variable retains its present value. If expression is a scalar subquery that returns no value, the variable is set to NULL.

    That...

  • RE: How long is a NULL?

    The question is:

    it is a BUG?

    ... or it is by design?

    ... or both: it is a BUG by design!

    Try this:

    DECLARE @v-2 char(10)

    SET CONCAT_NULL_YIELDS_NULL ON

    SELECT ISNULL('abcd'+@v,'1234567890')

    RESULT: 1234567890

    This behavior is...

  • RE: How long is a NULL?

    Also a void string take 1 CHAR:

    SET CONCAT_NULL_YIELDS_NULL ON

    SELECT ISNULL('abcd'+''+null,'1234567890')

    Result: 123456

  • RE: Clustered Index Internals

    vk-kirov, I agree with you. Question and answer is incomprehensible!!!!

  • RE: Counting spaces

    rcavill (12/7/2009)


    You need the option

    Must declare the scalar variable "@Dec".

    When running on a Case Sensitive collation.

    Once that select statement on line 2 is adjusted then it would work.

    ------

    Robert

    Have good luck...

  • RE: Fun with Scale and Precision

    Explanation is in the note.

    Try to reduce the precision.

    SELECT CAST(cast(1.67574 as decimal(38,10)) / cast(10000 as decimal(38,10)) AS DECIMAL(38,10) ) conv_factor

    returns 0.0001670000

    SELECT CAST(cast(1.67574 as decimal(29,10)) / cast(10000 as decimal(29,10)) AS...

  • RE: Datetime precision

    SQLBOT (11/29/2009)


    Comments posted to this topic are about the item <A HREF="/questions/Datetime+Manipulation/68075/">Datetime precision</A>

    Thanks. After year and years working with sql, there always is something to learn.

  • RE: Variables, Nulls and Coalesce

    Rob Goddard (11/27/2009)


    does the optimizer spot this and skip all the variable assignments and just do the last one?

    All the variable assignments are done.

Viewing 15 posts - 736 through 750 (of 807 total)