A party may join several causes of action as long as they arise out of the same transaction or occurrence, or series of transactions or occurrences. This transactional test applies whether the second claim is brought by a plaintiff against a defendant, by a defendant against a plaintiff (counterclaim), or by one party against a co-party (cross-claim).
Defendant asserts a claim against a plaintiff. If the defendant’s claim is not transactionally related to the claim asserted by the plaintiff, the judge has the discretion not to unduly complicate the case by refusing the joinder.
Some jurisdictions require all transactionally related counterclaims to be brought by the defendant. A compulsory counterclaim that has not been asserted cannot be raised in a subsequent lawsuit in federal court and compulsory counterclaim jurisdictions.
Parties to a lawsuit (either plaintiffs or defendants) can assert cross-claims against their co-parties (co-plaintiffs or codefendants, respectively) if the claims arise out of the same transaction as the case at hand.