пуста?
func insertSelectionText(pdb **sql.DB, schema string, param p0selectionText) {
fmt.Println("add selectionsText")
db := *pdb
/*
`CREATE TABLE ` + schema + `.selectiontexts
(
id BIGSERIAL NOT NULL PRIMARY KEY,
"id_selection" bigint,
"language" varchar(2),
"selectiont_text" varchar(200)) ;`,
*/
var INSERT_QUERY string = `insert into ` + schema + `.selectiontexts (
id_selection,
language,
selectiont_text)
values ($1, $2, $3) returning id;`
/*
*/
var id int
e := db.QueryRow(INSERT_QUERY,
param.idSelection,
param.language,
param.selectiontText).Scan(&id)
if e != nil {
fmt.Println(e)
}
fmt.Println("--->", id)
}
вам в голанг чат наверн
Обсуждают сегодня