Help query in database

Hello, I need help, I am new to programming in shiny, I would like to know how I could transform a textInput to a string, I want to use what textinput saves to make a query in a database, I cannot find another solution.

Example
I have (textInput ("userName", "Username")

and I want to occupy userName
my_usernames = paste0 ("select id_g from participant WHERE NAME = '",' here_here ', "'")

I appreciate your help