BookmarkSubscribeRSS Feed

Beyond Table Look-up: The Versatile SAS Hash Object

Started ‎12-22-2017 by
Modified ‎12-22-2017 by
Views 4,670

Authors: Don Henderson ( @DonH ) and Paul Dorfman ( @hashman )

 

This SAS Global Forum presentation highlights additional functionality of the SAS hash object. Soon after the advent of the SAS hash object in Version 9.0, its early adopters realized that its potential functionality is much broader than merely using its fast table look-up capability for file matching. This is because in reality, the hash object is a versatile data storage structure with a roster of standard table operations, such as create, drop, insert, delete, clear, search, retrieve, update, order, and enumerate.

 

hashnutshell.png

 

Since it is memory-resident and its key-access operations execute in O(1) time, it runs them as fast or faster than other canned SAS techniques, with the added bonus of not having to code around their inherent limitations. Another advantage of the hash object, compared to the methods that had existed before its implementation, is its dynamic, run-time nature and the ability to handle I/O all by itself, independently of the intrinsic statements of a DATA step or DS2 program calling its methods.

 

The hash object operations, or their combination thereof, lend themselves to diverse SAS programming functionalities well beyond the original focus on data search and retrieval. In this paper, which may be thought of as a preview of a SAS book being written by the authors, we aim to present this logical connection using the power of example.

 

Online resources

Comments

Hi Don,

 

Thanks for sharing. This looks like a must read. Now SAS Communities feels more &more like sascommunity.org with

such great articles. 

I noticed a small issue though,  being unable to display the Slides attached to the post. Maybe my own browser (chromium) is bugging ?

 

Ronan

 

 Edited

@ronan - try to click the download button to the right of the PDF link.  In some organizations, the file preview window might be blocked by a proxy firewall.  Downloading will get you the full PDF.

Thanks Chris, this way it works 🙂

Contributors
Version history
Last update:
‎12-22-2017 12:00 PM
Updated by:

hackathon24-white-horiz.png

The 2025 SAS Hackathon has begun!

It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.

Latest Updates

SAS AI and Machine Learning Courses

The rapid growth of AI technologies is driving an AI skills gap and demand for AI talent. Ready to grow your AI literacy? SAS offers free ways to get started for beginners, business leaders, and analytics professionals of all skill levels. Your future self will thank you.

Get started

Article Tags