The closer comparison to make is between oratorio and opera. Oratorios were originally created to be the church's response to opera which the 17th century church considered somewhat sinful. Therefore, oratorios are really unstaged operas. As a matter of fact, they can be quite similar musically and there have been a few oratorios that have been staged from time to time. Loosely speaking, a cantata is a short oratorio.