Viewing 15 posts - 31 through 45 (of 60 total)
This worked:
IIF(IsNumeric(CALL_ANI)=1,CONVERT(bigint,CALL_ANI),0) AS ANI
Strange, no ?
September 3, 2015 at 11:08 am
Thanks Grant.
There's no way around this ? Aliases ?
September 3, 2015 at 10:54 am
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...
September 2, 2015 at 3:18 pm
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...
September 2, 2015 at 1:32 pm
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...
September 2, 2015 at 7:40 am
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
...
August 28, 2015 at 4:23 pm
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...
August 28, 2015 at 10:40 am
Ed Wagner (8/28/2015)
August 28, 2015 at 9:28 am
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.
August 28, 2015 at 8:37 am
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.
August 26, 2015 at 11:54 am
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.
August 19, 2015 at 7:01 am
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...
August 12, 2015 at 1:47 pm
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)...
August 12, 2015 at 8:58 am
Thanks Guys....and yes it was a stored procedure.
I think I'll refrain from using it.....and make the default VARCHAR as NullString
August 11, 2015 at 2:11 pm
Viewing 15 posts - 31 through 45 (of 60 total)