Solved

hash partition

Posted on 2011-03-16
3
667 Views
Last Modified: 2012-05-11
Is a hash partition better suited for a table's column with high or low cardinality?
0
Comment
Question by:msimons4
[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
3 Comments
 
LVL 48

Accepted Solution

by:
schwertner earned 500 total points
ID: 35148826
Oracle says:

Hash partitioning maps data to partitions based on a hashing algorithm that Oracle applies to the partitioning key that you identify. The hashing algorithm evenly distributes rows among partitions, giving partitions approximately the same size.

Hash partitioning is the ideal method for distributing data evenly across devices. Hash partitioning is also an easy-to-use alternative to range partitioning, especially when the data to be partitioned is not historical or has no obvious partitioning key.

My comment is that if you have big amount of data that is randomly used you can spread the data on different disk devices to reduce the contention. But if you can somehow to range the data and the select statements in your application use data grouped in ranges, intervals and so on the hash partitioning is not a good decission.

The cardinality can affect the hash partitioning only by high cardinality. In this case if you select rows thre is no waranty that they sit in same partition. So spreading them on different devices can paralelize the query and be winning.

But if you can group the rows belonging to one search criteria in one partition - this will be the best solution. But this is range hashing.....
0
 

Author Comment

by:msimons4
ID: 35148886
Range hashing is not an option since there is no range in the search condition. So I have this table with 45 columns, do I list every column in the hash partition or do I list the columns in the index or do I list the columns in the PK ect? How do I determine which columns to list in the hash partition?
0
 
LVL 48

Assisted Solution

by:schwertner
schwertner earned 500 total points
ID: 35151658
The index(es) depend(s) on the select statement(s) you use.

The primary key (PK) is a must if this is not a datewarehouse.
In OLTP is row has to have PK. Even in DW the rows have to have PK because references will be almost impossible.
0

Featured Post

Instantly Create Instructional Tutorials

Contextual Guidance at the moment of need helps your employees adopt to new software or processes instantly. Boost knowledge retention and employee engagement step-by-step with one easy solution.

Question has a verified solution.

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

Introduction A previously published article on Experts Exchange ("Joins in Oracle", http://www.experts-exchange.com/Database/Oracle/A_8249-Joins-in-Oracle.html) makes a statement about "Oracle proprietary" joins and mixes the join syntax with gen…
From implementing a password expiration date, to datatype conversions and file export options, these are some useful settings I've found in Jasper Server.
This video shows syntax for various backup options while discussing how the different basic backup types work.  It explains how to take full backups, incremental level 0 backups, incremental level 1 backups in both differential and cumulative mode a…
This video shows how to configure and send email from and Oracle database using both UTL_SMTP and UTL_MAIL, as well as comparing UTL_SMTP to a manual SMTP conversation with a mail server.

739 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