Simplifying prefix+pattern join