Solved

an anybody point me some books or online tutorials to write  effective queries?

Posted on 2013-11-26
12
377 Views
Last Modified: 2013-12-21
I am able to write complex SQL queries but not effective ones.Can anybody point me some books or online tutorials to write  effective queries?
0
Comment
Question by:chaitu chaitu
  • 4
  • 3
  • 3
  • +2
12 Comments
 
LVL 37

Accepted Solution

by:
ValentinoV earned 125 total points
ID: 39680006
I'm a big fan of the black Microsoft books written by Itzik Ben-Gan, such as the one called Microsoft SQL Server 2012 T-SQL Fundamentals.

Here's his page on Amazon: Books by Itzik Ben-Gan

You'll not only learn how to write queries, you'll also learn how to write effective ones as mentioned in the description of the book mentioned above.
0
 
LVL 37

Expert Comment

by:ValentinoV
ID: 39680008
If you really want to find out why your queries don't perform well, you should learn about Execution Plans.  This book by Grant Fritchey should help you with that: SQL Server Execution Plans
0
 
LVL 20

Author Comment

by:chaitu chaitu
ID: 39680053
ValentinoV,

Thanks for the reply.Let me go through on it.I want such books or links for Oracle DB as well.
0
The Eight Noble Truths of Backup and Recovery

How can IT departments tackle the challenges of a Big Data world? This white paper provides a roadmap to success and helps companies ensure that all their data is safe and secure, no matter if it resides on-premise with physical or virtual machines or in the cloud.

 
LVL 37

Expert Comment

by:ValentinoV
ID: 39680057
Can't help you with Oracle, sorry...
0
 
LVL 20

Author Comment

by:chaitu chaitu
ID: 39680064
I will wait for other oracle experts..
0
 
LVL 28

Assisted Solution

by:Naveen Kumar
Naveen Kumar earned 125 total points
ID: 39680154
I use few online sites like the ones listed below :

http://www.datadisk.co.uk/html_docs/oracle/sql_optimization.htm
http://philip.greenspun.com/sql/complex-queries.html

also i use the asktom.oracle.com to read and understand the previously asked questions/forums which will help one to enhance their skills right.

additionally you can google it out and you will get plenty of them from which you can pick your choices as well.

Thanks,
0
 
LVL 20

Author Comment

by:chaitu chaitu
ID: 39680174
Thanks for the links.on which word(sql optimization or complex queries) do i need to google it?
0
 
LVL 28

Expert Comment

by:Naveen Kumar
ID: 39680203
some of the below strings/words can be searched and they get a lot of good content/urls. you need to spend time to review/pick up them which are good and store them for your frequent use etc...

oracle efficient sql statements
oracle sql optimization
oracle sql optimization techniques
oracle writing efficient sql
oracle writing efficient queries
0
 
LVL 20

Author Comment

by:chaitu chaitu
ID: 39680333
what kind of oracle books other than online links do you refer mostly while writing complex queries?
0
 
LVL 28

Expert Comment

by:Naveen Kumar
ID: 39680343
sorry, not really using books these days but used them when i started with oracle stuff in 1990s/2000s and that was a long ago. i some times refer to library reference books but do not remember authors for them.
0
 
LVL 65

Assisted Solution

by:Jim Horn
Jim Horn earned 125 total points
ID: 39680944
I'm with VV.  I won Itzik Ben-Gan's T-SQL Querying book in a local presentation he did a bunch of years ago, and have greatly enjoyed it.
0
 
LVL 23

Assisted Solution

by:David
David earned 125 total points
ID: 39681585
To the Oracle side, I'm reluctant to specify sources without knowing your focus -- for example, execution plans were mentioned above -- but at present (12c), Oracle's able to make dynamic evaluation of plans and to improve performance with each run of a statement.  Oracle Press (McGraw-Hill) and APress both present some excellent imprints to choose from.

Moreover, there's technique in one's coding style that goes beyond actual runtime performance.  Does the task require a temporary two-dimensional table, a cursor, an array?  Does overall performance benefit from altering the user resource profiles (memory, sort area) under different loads (batch vs. OLTP)?

I'll be glad to say more if any of this is helpful.

dvz
0

Featured Post

Courses: Start Training Online With Pros, Today

Brush up on the basics or master the advanced techniques required to earn essential industry certifications, with Courses. Enroll in a course and start learning today. Training topics range from Android App Dev to the Xen Virtualization Platform.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article I will describe the Backup & Restore method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
Via a live example, show how to restore a database from backup after a simulated disk failure using RMAN.

806 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question