The vertical line is in the same group on the equation toolbar with the parentheses and brackets, the leftmost group in the bottom row. When you open the group's dropdown, the left and right vertical bars are the first two entries in the next-to-last row.
After you insert the vertical bar, you can open the subscript/superscript group (third from the left in the bottom row) and click the entry with both superscript and subscript placeholders (rightmost in the top row).