|
|
-
Bihag Thaker Answered 2 Years ago through Quizzes
If I understand the requirement properly, we are supposed to create a new table which contains multiple records for an OrderID and TestName combination. I am replacing TestList column with new TestName column which will store only a single TestName. I a...
|
-
Bihag Thaker Answered 2 Years ago through Quizzes
In order to support my previous answer I had posted, I would like to add one more point to it.
**(3)** In order to get better performance, if you decide to add one calculated column named ExtPrice to your table that is based on Quantity*Rate calculat...
|
-
Bihag Thaker Answered 2 Years ago through Quizzes
SQL Server is mainly a Relational Database Management System (RDBMS). An RDBMS is the one that stores and manipulates data by following the rules of relational model. The relational model has been built upon one of the strong Mathematical branches and t...
|
-
Bihag Thaker Answered 2 Years ago through Quizzes
OVER() clause is used with window functions (ranking functions) and aggregate functions to define a set of rows on which the window function or aggregate function is applied. OVER() clause is accompanied with PARTITION BY clause which actually defines t...
|
-
Bihag Thaker Answered 2 Years ago through Quizzes
If we put all the assumptions aside like “available indexes” or “number of records in table“ and only consider the mentioned function GetExtPrice() the way it is along with the provided two queries, I would say the first query is bad. Following are the ...
|
-
Bihag Thaker Answered 2 Years ago through Quizzes
In SQL Server, CAST() function is used to explicitly convert an expression of one datatype to another datatype. While casting, depending upon the source and target expressions, SQL Server may perform truncation or rounding on resulting value or returns ...
|
-
Bihag Thaker Answered 2 Years ago through Quizzes
There is no any thumb rule to decide whether to use Table Variable or Temporary Table. It depends upon the requirement of the application and different situations.
Following are some of the facts for Table Variable and Temporary Table:
**(1)** Onc...
|