|
|
|
|
-
The challenge is to implement similarly functionality in TSQL, that works similar to TRANSLATE function of ORACLE. ...
|
|
|
-
Asif Ghanchi Answered 2 Years ago through Quizzes
It's a really simple question to answer.
In sqlserver whenever we having any select,update or delete statement it's always creating it's seperate execution plan.
In first statement we have only one execution plan and in second query we having four...
|
-
Asif Ghanchi Answered 2 Years ago through Quizzes
It's a really simple question to answer.
In sqlserver whenever we having any select,update or delete statement it's always creating it's seperate execution plan.
In first statement we have only one execution plan and in second query we having four...
|
-
Asif Ghanchi Answered 2 Years ago through Quizzes
count(*) over() is partition function and used to count of total of rows before displaying records (before any aggregate function apply and). so we can apply any aggregate function on that.
Output of this depend on **group by someField** which will p...
|
-
Asif Ghanchi Answered 2 Years ago through Quizzes
declare @float1 float = 0.1112222333444555
declare @float2 float = 0.1112222333444550
declare @diff float = 0.000000000000001
select @float1,@float2,2*(@float1 - @float2),@diff - (2*(@float1 - @float2))
output:
0.111222233344455 0.11122...
|
-
Asif Ghanchi Answered 2 Years ago through Quizzes
1) SELECT CAST(2004 AS VARCHAR(2)) o/p : *
While converting int to varchar(2), it showing overflow as *.
2) SELECT CAST('2004' as varchar(2))
While converting any string data type...it's truncating string from right....
|
-
Asif Ghanchi Answered 2 Years ago through Quizzes
1) SELECT CAST(2004 AS VARCHAR(2)) o/p : *
While converting int to varchar(2), it showing overflow as *.
2) SELECT CAST('2004' as varchar(2))
While converting any string data type...it's truncating string from right....
|
-
Asif Ghanchi Answered 2 Years ago through Quizzes
2nd query is slow.
- UDF function is executing row by row, we can find that from trace which always causing performance issue.
But it does not means that UDF is always slow.
It's depend on operation we are doing.
1) We can remove repeated op...
|