How is second law consistent with the first law?

From second law, force F = m x a. If F = 0, then a = 0, i.e., no external force means no acceleration. It implies no change in state of rest or of uniform motion in a straight line which is nothing but first law of motion