Paul is referring to a letter he wrote previously to the Corinthians. Some scholars believe this refers to the letter known as First Corinthians. Other scholars believe this refers to a letter Paul wrote after the letter known as First Corinthians and before this letter. In either case, Paul had told the church to rebuke an erring member. Paul is now encouraging them to be gracious to that person. Alternate translation: "I wrote as I did in my previous letter"
Paul is speaking about the behavior of certain Corinthian believers who caused him emotional pain. Alternate translation: "those who should have made me rejoice might not hurt me"