website design – Should I use alert box or just helper?

I have a case, related to inquiring a sequence of number. User can look up to that number and processed that into another task. But not all number can be inquired in this system (due to some rules). I thought to give it notifications if that number can’t be inquired using helper (because user can still also filled the fields when you clear the number and type another one). Is it right?

enter image description here

or should I use alert box (which can be gone in few seconds)?
enter image description here

this number is inquired when user done typing the number (not when submitting the form). Thank You!