You obviously don't understand what vaccines are or how they work. It generally depends on the disease being prevented how effective the vaccine will be as the mimic infection by generating an immune response by any of a variety of means (live attenuated virus, dead virus, mRNA, virus antigen...