Ck Nitin

Ck Nitin

  • 266
  • 7.2k
  • 3.1m

How to call function postgresql? using Dapper

Jun 6 2021 5:07 AM

Is this right wy to cll function in postgresl?

 

var procedure = "vamp.SearchQuestion";
using (var connection = new NpgsqlConnection(_connectionString))
{
result = await connection.QueryAsync<QuestionSearchModel>(procedure, new { searchtext = searchText }, commandType: CommandType.StoredProcedure);
}

 


Answers (3)