• And digging a bit further (cause it's more fun than doing performance reviews)

    http://www.sqlserverpeoples.com/SearchFaq.aspx?source=home&fpi=sql&fl=bas

    Truncate Truncate command is used to remove all rows of the column. The removed records are not recorded in the transaction log. It is the fast way to remove all the records from the table. The records once removed can’t be rolled back. It can’t activate trigger. It resets the identity of the column.

    I guess 3 out of 5 correct is a pass, but still shows that minimal research has been done and myths are believed at face value.

    SELECT * FROM

    WHERE [date column]>='2012-02-05 12:34:34.000' and [date column]<='2012-02-06 10:04:58.999'

    Shows a lovely lack of understanding of SQL Server datetime data types.

    A primary key is a constraint on a column whose values uniquely identifies in a table. Primary key values can never be reused/reinserted in the column on which it is defined. If a row is deleted from the table, its primary key may not be assigned to any new rows in the future.

    One out of those three statements is correct, the rest, I have no clue where they came from. This would have been trivial to test and see that it's false, so again, no research or testing done.

    5. Values in primary key columns can never be modified or updated.

    What is this? I don't even.

    http://www.sqlserverpeoples.com/SearchFaq.aspx?source=home&fpi=rdbms&fl=adv

    This page is plagiarised. Copied without attribution from http://en.wikipedia.org/wiki/Data_independence

    In case you were unaware, the text on Wikipedia is all under the Creative Commons Attribution-ShareAlike License; This means that it can be shared but attribution must be given.

    3. The WHERE clause may or may not contain aggregate functions. The HAVING clause can contain aggregate functions.

    The WHERE clause may contain aggregate functions? I really want to see a working example of that...

    Where

    select employee, sum(bonus) from emp_bonus

    group by employee where sum(bonus) > 1000;

    Msg 156, Level 15, State 1, Line 2

    Incorrect syntax near the keyword 'where'.

    So, not even tested.

    Also example shows how to apply "nolock". nolock is normally applied while querying on production servers.

    Right, because we normally want duplicate and missing rows when querying production.

    How many non-clustered indexes can create in a table?

    Maximum 249 non-clustered indexes can be created in a table.

    Little bit out of date here? Like 7 years out of date.

    What is the use of DBCC commands?

    DBCC stands for database consistency checker.

    Not since around SQL 7 it hasn't.

    What is heap or heap table in SQL Server ?

    A table without any clustered index is called a heap table in sql server. In such table rows of the data are stored in un-organized manner and also not linked to the adjacent pages in the table.

    In a heap, the only links between pages are between the adjacent pages in the table.

    Rahul, if you're going to post 'interview' questions, you really should do some work to ensure their technical accuracy before promoting the site.

    Gail Shaw
    Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
    SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

    We walk in the dark places no others will enter
    We stand on the bridge and no one may pass