| Recent Answers from Jwalant Natvarlal Soneji |
 |
2008-08-26 SQL Query to Get Incremented Index based on other Column value: Dear James, There could be several types of queries leading to the same result. One of them can be like this. 1. Create temp table 2. Insert data in it. Create an extra column in it to store the...
|
2008-08-22 SQL query to fetch duplicate data only: Dear Mrinmoy, Here you can use GROUP BY with COUNT to get the desired result. For example: ### SELECT batch_code, cusip, age, salary FROM Employee WHERE cusip IN (SELECT cusip FROM Employee WHERE...
|
2008-08-21 Query for fetching 2nd largest , 2nd lowest data: Dear Mrinmay, There will be (and are) several ways to get the same results. I will illustrate one of them here. I believe it would not be the best one but can be used for your both queries, with less...
|
2008-08-14 Calculate 5 highest numbers: Dear Ola, The above given query should work for this purpose, but has to be modified according to your columns in result and in table. For example: #### SELECT TOP 5 Animal_Name, Animal_Weight...
|
2008-08-13 Query: Dear Ola, The TOP keyword, with ORDER BY can return highest values of the column. Example: #### SELECT TOP 5 Marks FROM students ORDER BY Marks DESC #### DESC will result in the values in descending...
|
| More Answers for "MS SQL" |