How do find out particular record in partition by using PBK?

I have 400 records in my in0 file, its 4-way multifile system. How can I find out particular 150th record will goes to which partition using Partition by Key?

Questions by vijayv   answers by vijayv

Showing Answers 1 - 21 of 21 Answers

anvit agarwal

  • Feb 15th, 2012
 

It will go to the 3rd partition. Divide 150/4, then remainder is 2 i.e to the partition 3rd

  Was this answer useful?  Yes

manishekhar

  • Feb 26th, 2012
 

If the Key you are using for partitioning the data is unique then 150th record will go to 3rd partition. But if the key is not unique its hard to say which partition the record will go.

  Was this answer useful?  Yes

amey

  • Feb 26th, 2012
 

Use hash_value to determine which partition the record goes into.

  Was this answer useful?  Yes

RAM

  • Aug 17th, 2012
 

There is no guarantee for particular partition will get particular record but we will tell one thing suppose we r having records like 1,1,1,2,2,3,4,4,5,5,6,7,7,8,9,10 in this records reach to first partition like all ones definitely will go to first partition may be there is a chance for twos ,threes ,fours,fives,.......

so on end else only ones will go first part only twos will go second only three is in third like in this manner but iam telling one thing suppose first will goes to first part then all ones are in first partition suppose first two goes to second partition then all twos are in second partition like ................

  Was this answer useful?  Yes

kumar

  • Oct 2nd, 2012
 

Yes, exactly, we can find out by using hash formula.

  Was this answer useful?  Yes

Sjn

  • Nov 26th, 2020
 

hash_value(this_record,key)% no. of output partition = no of output partition for this record

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions