In ASCE 7-16 there is a load combination as: 1.2D + 1.0E + L + 0.2S but then there is also another combination as: 0.9D + 1.0E In both of them earthquake load is the same so why would we use the second one, while the first one would create the worse combination with 1.2 instead of 0.9 for dead load? What am I missing exactly?
Dead loads can, in some cases, be beneficial to the structure's safety.
For instance, say you have a simply-supported beam with a cantilever and you want to find its bending moment envelope. Depending on the length of the cantilever, it's possible the simply supported segment will mostly be under negative bending moment. So when calculating the positive bending moment envelope (from dead and live loads), the dead loads will actually "cancel out" some of the live load's results. In such cases, you'd then want to use 0.9 instead of 1.2 as the dead load factor.