Q.Can I cut in half?
I have a pencil cactus that is over 7ft tall but healthy. I can’t get it to stand up straight. Can I cut it in half and cap it with something to prevent disease?

Easy peasy. Cut it wherever you want, don't worry about "capping." You can pat a bunch of dirt from the pot to keep the sap from making a mess. (Sounds weird I know, but I do it all the time with ficus trees.) Not only that, you can plant the cutting, or cut it up to make several cuttings, and you'll have new plants. This article has more information: https://www.gardeningknowhow.com/ornamental/cacti-succulents/pencil-cactus/care-pencil-cactus.htm