Can I replace the file with a change string? I want to read changelog from the database

Can you provide some more details? For example, if you explain what you are trying to achieve with some sample data, then we may be able to give a solution faster.

Also, if you are using any framework like spring, please mention that too.