Forum Replies Created

Viewing 15 posts - 31 through 45 (of 60 total)

  • RE: CONVERT BUG ?

    This worked:

    IIF(IsNumeric(CALL_ANI)=1,CONVERT(bigint,CALL_ANI),0) AS ANI

    Strange, no ?

  • RE: ALTER AUTHORIZATION

    Thanks Grant.

    There's no way around this ? Aliases ?

  • RE: include source feature

    Alvin Ramard (9/2/2015)


    I suspect many just use COPY - PASTE to handle this.

    That's no good....what happens when that code needs to be changed ??

    If SSMS had a source code -include...

  • RE: Interesting Design Issue

    Thanks Jeff -

    you are saying that if the table is properly indexed, I really don't need to use the view which will limit the look-back period and thus the...

  • RE: t-sql for which columns spilled to row_overflow_data

    Here are some links that may help.

    Interestingly, when I ran sys.dm_db_index_physical_stats on one table that had a ton of VARCHAR(1000) columns, the report indicated nothing in the overflow.

    So this does...

  • RE: CTE within a stored proc

    CTE's also have bugs and restrictions:

    When I run this code, the rows in the newly created table are not in sorted order.

    W_CALLS AS

    (

    SELECT TOP 100 PERCENT

    C.CALL_TP_ID

    ...

  • RE: CTE within a stored proc

    Lynn Pettis (8/28/2015)

    My biggest pet peeve! The semicolon is a terminator, not a begininator. It belongs at the end of statements not the beginning.

    Exactly, another dumb rule.

    I don't...

  • RE: CTE within a stored proc

    Ed Wagner (8/28/2015)


    The statement that contains the CTE needs to end with a query that uses the CTE. Like Luis said, please post the code; that should clear up...

  • RE: CTE within a stored proc

    I want the EXEC right after the CTE.....no can do.

    I put a semicolon after the last paren of the CTE and that throws a syntax error.

    Something strange is happening here.

  • RE: My Sequences were reset

    Thanks Grant...now I wonder if "someone" sabotaged me.

    I created a stored proc to reset them to one plus the highest value in the related tables.

  • RE: My Sequences were reset

    I'm not sure....I didn't do it.

  • RE: SET TABLE VARIABLE FROM FUNCTION CALL

    Thanks Gila and Scott.....good stuff.

    Interestingly - by using a temp table instead of a declared table variable, the @@FETCH_STATUS initializes to -1 versus zero.

  • RE: PRINT bug ?

    Guys - No harm intended here. If I offended anyone, I apologize.

    Actually, this was good for me as I had to really try a couple of things and go into...

  • RE: PRINT bug ?

    Well guys, not one of you provided a solution.

    There are two:

    1) ISNULL(@ColDefaultVal,'-')

    That variable was the one preventing the PRINT from executing.

    2) RAISERROR ('ColDflt=%s',0,1,@ColDefaultVal);

    This is even better as it indicates (null)...

  • RE: Use of Default keyword as the parameter default - what value is it ?

    Thanks Guys....and yes it was a stored procedure.

    I think I'll refrain from using it.....and make the default VARCHAR as NullString

Viewing 15 posts - 31 through 45 (of 60 total)