Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Differences between Microsoft SQL server and Oracle database server 1

Status
Not open for further replies.

RY

Programmer
Apr 9, 1999
10
US
I have been working on Oracle database as a developer and I may have to work on MS SQL server! I would like to know what are the major differences in Query writing and customization using stored procedures etc between Oracle and MS SQL server?
 
The queries are about the same but the functions are screwy (Conversions, substrings, dates and date formatting)
 
I'm in the middle of sorting out a very annoying problem. In Oracle, a select statement using IN will parse the query to use indexing where it exists, but SQLServer does full table scans and ignores the indexes. Using UNION in SQLServer for every component of the IN clause performs the same as Oracle. Does anyone haves any smart ideas on rewriting these queries in SQLServer ?
 
Could try splitting the query into two statements. SELECT the ids from the inner statement into a temp table, then use it as part of the join in the main SELECT.
 
Thanks for the tip - it pointed me in a direction where I realised my SQL statement was badly flawed (grouping on a dataset that was already grouped). Je suis un buffoon!
 
Bouffon, Aucun Non. Mais, deux têtes sont meilleures qu'un.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top