D
D
Dmitry Gavrilenko2017-10-30 14:52:12
go
Dmitry Gavrilenko, 2017-10-30 14:52:12

How to pass a table parameter to a database in Go?

Actually a subject.
Working with the database is done by calling stored procedures. I learned how to pass ordinary parameters (numbers, strings) to parameters, but I don’t understand how to pass a table-valued parameter.
Natively using "database/sql" package
Thanks for the help.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Andrey Skorzhinsky, 2017-10-30
@AndyKorg

Guidelines for Transact-SQL procedures.
.....
All Transact-SQL data types can be used as parameters.
You can use a user-defined table type to create table-valued parameters. Table-valued parameters can only be INPUT and must be followed by the READONLY keyword. For more information, see Using Table-Valued Parameters (Database Engine).
....

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question