How to automate change to 500 scripts

I have about 500 sql scripts that I need to make the same change too. Is there a way to automate this?

are these scripts stored in the database?

if not, then i’m having trouble understanding how this is a database question and not a general programming question