The main uses of the subjunctive include:
1. After the verb querer when
there is a change of subject (but use the infinitive
if there is no change of subject)
2. When one person tells (decir)
or asks (pedir) another person to do something.
3. After expressions of emotion, such
as esperar (to hope), sentir (to be
sorry), temer (to fear), alegarse
(to be glad), when there is a change of subject.
4. After dudar (to doubt) and
other verbs expressing uncertainty.
5. After most impersonal expressions,
such as es posible (it's possible), es
importante (it's important), es necesario
(it's necessary) if there is a subject for the subordinate
verb.
6. In adjective clauses is the antecedent
is indefinite
7. After certain conjunctions, such
as para que (in order that), sin que
(without), and antes que (before)
8. After time conjunctions, such as
cuando (when), en cuanto (as soon
as), hasta que (until), when futurity is
implied.
9. In contrary-to-fact conditions, the
past subjunctive must be used in the if-clause (and
the main clause is in a conditional tense)