What is a hashing function, Database Management System

Assignment Help:

What is a hashing function?  What are the properties of a good hashing function?  Describe the folding technique for hashing functions.    

 Ans:  Hashing function is a method to store a file on the disk. A hash function is a function which while applied to a value of a record (hash field) gives a hash value that is the address of the disk block where the record is stored.

   The properties of a good hash function are like this:

  • It must be easy to evaluate.
  • The hash value acquired should be within the range of valid addresses for a given file.
  • The hash values should be consistently distributed over the range of addresses so that the collisions are minimum.

Folding method for hashing functions:  It includes applying an arithmetic function like addition or a logical function such as exclusive OR to different parts of a hash field to compute the hash addresses. For instance, the numeric hash field can be split into start, middle and end regions, like that the sum of the lengths of the start and end regions equivalents the length of the middle region. The start, middle and end regions' digits are added to acquire a new value, x. After that x mod s, where s is the upper limit for the hash function, provides the hash value.


Related Discussions:- What is a hashing function

Consistency error-database errors, Consistency error : These errors happen ...

Consistency error : These errors happen due to the inconsistent state of database caused may be due to wrong implementation of commands or in case of a transaction abort.  To overc

How we can implement relationships when designing tables, You want to imple...

You want to implement following relationships when designing tables. How would you do it? a.) One-to-one b.) One-to-many c.) Many-to-many a.) One-to-One relationship -

Find out the names and company names from database, Find out the names and ...

Find out the names and company names of all employees sorted in ascending order of company name and descending order of employee names of by which company. SELECT EMPLOYEE_NAME,

What is data mining?, Question 1 Define OLTP? Explain the Differences betw...

Question 1 Define OLTP? Explain the Differences between OLTP and Data Warehouse Question 2 What is Architecture? Explain various components involved in it Question

Explain the deferred update, Explain the Deferred Update The deferred ...

Explain the Deferred Update The deferred update methods do not physically update the database on disk till after a transaction reaches its commit point; after that the updates

What does data dictionary is a special file contains, What does data dictio...

What does data dictionary is a special file contains ? The data dictionary is a special file contain The name of all fields in all files.The width of all fields in all files an

What is a b+-tree index, What is a B+-Tree index? A B+-Tree index takes...

What is a B+-Tree index? A B+-Tree index takes the form of a balanced tree in which each path from the root of the root of the root of the tree to a leaf of the tree is of the

Create a new service-based database, In this assignment, you will create a ...

In this assignment, you will create a program that works with multiple tables. In this assignment, you will work with the factory and sales tables. 1. Create a new project nam

Advantages of Observation Methods, Advantages of Observation  Methods: ...

Advantages of Observation  Methods: Bailey has pointed  out four  advantages of observation: 1. Superior in Data  Collection  on Non Verbal Behavior: When  a person  a opi

Find the employee name, Example -Find the employee name, salary, department...

Example -Find the employee name, salary, department number and average salary of his/her department, for those employees whose salary is more than the average salary of that depart

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd