What is this Site!!

All about Real time requirements in Orale Stay Tune!!

Friday, February 8, 2008

SQL Server


>>Previous>>


Using Distinct to Eliminate duplicate Information


One can eliminate duplicates using Distinct keyword in the SELECT clause

SELECT DISTINCT column_list FROM table_Name
Where search_condition

Example

SELECT DISTINCT city
FROM authors

OR

SELECT DISTINCT city, state
FROM authors



Using ORDER BY clause



ORDER BY clause is used in SELECT statement to sort data

SELECT column_name
From Table_List
[order by column_name[ASC|DES]]

Example

SELECT title_id, au_id
FROM titleauthor
ORDER BY title_id, au_id

  • Default Order is Ascending
  • Since sort order being used by SQL Server can make difference in the ORDER BY clause, one should check default sort order of SQL Server using sp_helpsort
  • ORDER BY clause can not be used on text or image columns


SQL Order of Logical Operations (each operates from left to right)

NOT
AND
OR


>>>Next>>>

3 comments:

12345 said...

Nice blog Thanks for sharing this Informative.
Oracle Fusion HCM Online Training
Oracle Fusion SCM Online Training
Oracle Fusion Financials Online Training
Big Data and Hadoop Training In Hyderabad

shaik shah said...

Brilliant blog I visit this blog it's incredibly awesome. Curiously, in this blog content formed doubtlessly and sensible. The substance of information is helpful.
Oracle Fusion HCM Online Training
Oracle Fusion Financials Online Training

Tech Leads IT said...

Thanks for sharing valuable information.
Tech Leads IT is the best training institute for Oracle Fusion cloud.
Fusion training here is comprised of modules like Oracle Fusion SCM, Oracle Fusion financials, Fusion HCM, Fusion Technical etc. with Corporate trainers along with placement assistance.
We provide Online Fusion cloud classes and classroom training also in Hyderabad and Bangalore.

oracle fusion financials training