Limit Topic Title Characters

I’m looking to limit the amount of characters that can be input for the length of the topic title. Where can I achieve this? I imagine it’s somewhere in the database but not being a database guru I’m a little lost.