I am currently using GO MySQL and I have a case where the sql contains many similar parameter.
stmt, err := db.Prepare(`
SELECT id
FROM questions
WHERE description like '%?%'
UNION
SELECT id
FROM books
WHERE description like '%?%'
UNION
SELECT id
FROM sites
WHERE description like '%?%'`)
param := "golang"
stmt.Query(param, param, param)
My real life sql has about 10 similar parameters of golang
and a 2nd parameter that repeats itself a few times. Is the positional parameter the only way to construct the sql?