All the boys / All boys

  1. All the boys and girls were singing the national anthem.
  2. All boys and girls were singing the national anthem.
    Which sentence is more appropriate?
    Thanks.

Both are possible.
Using ‘the’ indicates a specific group of boys and girls.
Common sense therefore, indicates that this is the most appropriate in the majority of situations, as usually a sentence such as yours would be used by someone referring to a particular group.
However, ultimately it depends on context

There is a bit of a clash in this sentence:

.

because the absence of the article ‘the’ suggests that this would be a regular/habitual process but the tense ‘were singing’ suggests otherwise. This absence of the article would work if the tense was in a simple form as:

All boys and girls sing/sang the national anthem

Good point.