?
Solved

logical vs physical reads

Posted on 2006-11-16
6
Medium Priority
?
942 Views
Last Modified: 2008-03-17
what is the difference between logical reads and physical reads?
0
Comment
Question by:yanci1179
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
  • 2
6 Comments
 
LVL 143

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 1200 total points
ID: 17959845
physical reads means the data has been read from disk into memory
logical reads means the the data was already in memory

1 logical reads means 1 page of data, ie 8KB
0
 

Author Comment

by:yanci1179
ID: 17959911
i read that in books online....but it didn't really mean much.  Ideally which one should be lower?
0
 
LVL 32

Assisted Solution

by:Brendt Hess
Brendt Hess earned 800 total points
ID: 17959980
In a perfect world, physical reads would be equal to the number of data blocks in your database, and all other reads would be logical.  So, by preference logical reads should be the higher of the two.
0
Will your db performance match your db growth?

In Percona’s white paper “Performance at Scale: Keeping Your Database on Its Toes,” we take a high-level approach to what you need to think about when planning for database scalability.

 
LVL 143

Expert Comment

by:Guy Hengel [angelIII / a3]
ID: 17960495
perfectly, the physical reads should be 0. also, logical reads as low as possible.
0
 

Author Comment

by:yanci1179
ID: 17960572
let me see if I understand this logical data read from what is already in cache.  if it's not there then it has to read the physical tables and retrieve the data?
0
 
LVL 32

Expert Comment

by:Brendt Hess
ID: 17962141
Absolutely correct.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

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

JSON is being used more and more, besides XML, and you surely wanted to parse the data out into SQL instead of doing it in some Javascript. The below function in SQL Server can do the job for you, returning a quick table with the parsed data.
In this article we will learn how to fix  “Cannot install SQL Server 2014 Service Pack 2: Unable to install windows installer msi file” error ?
Using examples as well as descriptions, and references to Books Online, show the documentation available for date manipulation functions and by using a select few of these functions, show how date based data can be manipulated with these functions.
Viewers will learn how to use the INSERT statement to insert data into their tables. It will also introduce the NULL statement, to show them what happens when no value is giving for any given column.
Suggested Courses

770 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