2
与TDS库存储过程
我收到以下错误尝试使用Tds库药剂HOW TO:调用药剂
存储过程get_account
存在调用存储过程并有且只有一个参数@id
iex(5)>Tds.Connection.query(pid, "get_account",[%Tds.Parameter{name: "@id", value: 1}])
{:error,
%Tds.Error{message: nil,
mssql: %{class: 16, length: 252, line_number: 0, msg_text: "Procedure or function 'get_account' expects parameter '@id', which was not supplied.", number: 201, proc_name: "get_account",
server_name: "localhost\\SQLEXPRESS", state: 4}}}
iex(6)>
试图用这种Tds.proc(pid, "get_account",[1])
无法正常工作或
这大概是那些情况下,它更容易下到二郎ODBC层下降,做你想要做什么的。看到这个问题(http://stackoverflow.com/questions/18929391/how-to-call-stored-procedure-taking-array-using-odbcparam-query-in-erlang)了解更多详情。 –