|
|
-
Be advised in advance that this is a bit of a "trick question".
You are asked to review this query:
select
a.base_id,
coalesce(b.order_Id, c.order_Id
) as Order_Id
from kaw_ref xRef
left join kaw_Base a
on a.base_id = xref.base_Id
left join kaw_subtype1 b
on b.base_id = a.base_Id
left join kaw_subtype2 c
on c.base_id = a.base_Id
where a.base_Id is not null
You respond by modifying it to something like this:
select
a.base_id,
coalesce(b.order_Id, c.order_Id
|
-
Question on COUNT function
|
-
Using Indexed view in SQL Server comes with a cost. But there are places which it perfectly fits in and at the same time there are places where it create problem than solution. So, what all are the pros and cons of using Indexed view
|
-
The question looks for the real time applicability of Sql Server 2011's With Result Set Statement
|
-
In SQL Server, a page is 8K (8192 bytes) and what is the largest data size [when storing one or many rows] that can be stored in a page if you exclude LOB data?
|
-
Imagine you want to automate Human Resources department's operations. One of the reports the HR Manager will like to run is to get the following information for any given employee: The people who manage this employee and all the people whom he/she manages.
I'd like you to define the database model and present a solution for this report. If you'd like, you can try various models and explain advantages/disadvantages of each. Explain if your solution will be different depending on the size of th
|
-
This question invites you to share your thoughts on writing reporting queries that deals with more than one databases.
|
-
An invoice table contains order information such as order date and order amount. Your job is to find the best
way to calculate the total amount of orders created today. Your query should run in SQL Server 2008 or later versions.
|
-
Your task is to generate a single TSQL statement to fetch the difference between the SYSTNODE value without having the need to use EXCEL.
|
-
Look at the query given below which uses GROUP BY ALL which is a deprecated feature. Your task is to write a query that accomplishes the same functionality without using GROUP BY ALL.
|
|