Professional Documents
Culture Documents
Sort Key Functionalities - SAP Blogs
Sort Key Functionalities - SAP Blogs
Products
Products Industries
Industries Support
Support Training
Training Community
Community Developer
Developer Partner
Partner
About
About
Home / Community / Blogs + Actions
G. Ajit Kumar
more by this author
FIN (Finance)
SAP ERP | allocation | assignment | enterprise resource planning | erp financials | finance solutions | Financial Excellence | item
overview
share
0 share
0 tweet share
0
Follow
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 1/18
11/27/2017 Sort Key Functionalities | SAP Blogs
Sort Keys:
Sort Keys are used to populate the Assignment number field in the line items
of customers or vendors or general ledgers.
either manually
or automatically by the system
Whenever any standard reports are executed for displaying the line items of
customers or vendors or general ledgers, SAP uses the content of the
Assignment number field as one of the criteria to sort and display the line
items.
The contents of the fields available in the database tables BKPF or BSEG or
BSEC or BSED can be populated automatically in the Assignment number
field of the document, either completely or partially.
The logic defined in the Sort Key is applicable across the client.
Step 1:
But custom sort keys can also be defined if the requirements of the client
cannot be met with the standard sort keys available.
For example, if the standard sort key 002 is assigned to the customer or
vendor or general ledger master record, it would populate the Assignment
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 3/18
11/27/2017 Sort Key Functionalities | SAP Blogs
number field of the document with the document number (BELNR) followed by
the fiscal year (GJAHR).
Similarly, the standard sort key 001, would populate the Assignment number
field of the document with the posting date.
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 4/18
11/27/2017 Sort Key Functionalities | SAP Blogs
Step 2:
In the example, the standard sort key 001 has been assigned to the
customer master.
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 5/18
11/27/2017 Sort Key Functionalities | SAP Blogs
Step 3:
After the document is saved, if the Assignment number field is checked, it can
be seen that the field is automatically populated with the posting date of the
document.
In the example below, the sort key assigned in the customer master record is
001 Posting Date.
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 6/18
11/27/2017 Sort Key Functionalities | SAP Blogs
Step 4:
When the transaction code is executed to display the customer line items, it
can be observed that the line items are displayed sorted on the basis of the
content of the Assignment number field.
Step 5:
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 7/18
11/27/2017 Sort Key Functionalities | SAP Blogs
Step 6:
When the transaction code is re-executed to display the customer line items, it
can be observed that the line items are displayed sorted on the basis of the
content of the modified Assignment number fields.
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 8/18
11/27/2017 Sort Key Functionalities | SAP Blogs
Conclusion:
The content that will be populated in the Assignment number field will
be derived from the database tables BKPF or BSEG or BSEC or
BSED.
The customer line items are displayed in standard SAP reports after
being sorted on the basis of the content of the Assignment number
field.
Alert Moderator
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 9/18
11/27/2017 Sort Key Functionalities | SAP Blogs
30 Comments
You must be Logged on to comment or reply to a post.
Debarun Sinha
Thanks Debarun!
Sankar AK
Hi Ajit kumar,
Helped me to understand the functionaries of Sort key and also helped me to analyse
our clients issue in this regards. Thanks for this nice document.
Thanks
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 10/18
11/27/2017 Sort Key Functionalities | SAP Blogs
Cecil D'Souza
I am a newbie and I found that it is impossible to get to the sort key screen by entering
SPRO and Enter. I then used tcode SM30 and it asks for the table name. Can you
please adjust the procedural steps to fill the gap?.
Hi Cecil,
Please use the transaction code OB16 to access the details of Sort Keys.
Ajit
Cecil D'Souza
Thank you very much Ajit for your timely help. Its great to get
professional help and guidance like this. What a system this
internet has created.
Ranu Eugene
Hi Ajit,
Very well described by you and it made very clear the use of sort keys in Master Data.
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 11/18
11/27/2017 Sort Key Functionalities | SAP Blogs
Best of Luck.
Regards
Eugene
Thanks Eugene
deepa p
Hi Ajit,
Nice doument of sort keys i guess its really helpful for beginners like me, mainly
sharing the knowledge on customization of sort keys is appreciated.
regards
Deepa
Krishna Bhandari
Lakshmi Sama
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 12/18
11/27/2017 Sort Key Functionalities | SAP Blogs
Hello Arjit,
Very helpful and a good concept. And very well explained. Thanks for sharing the
knowledge on a new concept and keep sharing
Regards,
Lakshmi S
narin kamuni
Very well documented Very useful document Thanks for the efforts.
Regards,
Narin Kamuni
Arvind Pereira
Hello Arjit,
Thanks
Arvind
Pankaj Bansal
Arjit,
Very helpful !
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 13/18
11/27/2017 Sort Key Functionalities | SAP Blogs
pulak samantaray
thanks ajit,
nice document
regards
pulak
Karteek k
Kiran T
Thanks
Regards
KIran
eliud maina
Kiran MMD
Thank you very much for the detailed explanation regarding Sort key. Its self explanatory
and really helpful.
Suresh B
Hi Ajith
Regards
Prasad
Sethuraman Ganesamurthy
Hi Ajith,
Regards,
GSR
Prakash Sutar
Hi Ajit,
Thanks,
Prakash
Selvakumar Natarajan
very very useful info.. the area often user fail to do the appropriate sort key thank u for
your efforts..
Karteek k
Hi Ajit,
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 16/18
11/27/2017 Sort Key Functionalities | SAP Blogs
Regards
Karthi
Hoysala SAP
Can you pls clarify my doubt. We will need to populate #Shipment number in Assignment
field and that Shipment number is available in Material document. However, I do not find
any Logistic related fields in OB16. Can you pls let me know how can we achieve this
requirement.
Thank you.
Vishwanath Gamanagatti
Its very informative and very well documented. Thanks for taking affects and sharing
with us.
Sateesh Suripally
Well explained
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 17/18
11/27/2017 Sort Key Functionalities | SAP Blogs
https://blogs.sap.com/2013/01/16/sort-key-functionalities/ 18/18