I screwed the 1" x 6" upright boards to the ends of the joists to keep both in place.
All images copyrighted: © Steven P. Davis; all rights reserved.