This question already has an answer here:
Imagine a wire with current I flowing through it. If we take a closed loop that doesnt contain the I the line integral will be zero. Does this means magnetic field is zero ? Also does Ampere law calculating the total magnetic field or only the sum of magnetic fields from the currents that are enclosed in the loop?