Code: Select all
using (var command = new PgSqlCommand("alter role @user test with password @pw", MyConnection))
{
command.Parameters.AddWithValue("@user", user);
command.Parameters.AddWithValue("@pw", pw);
result = (command.ExecuteNonQuery() == -1);
}
I tried hardcoding the password (i.e. i.e. alter role @user test with 'test') and this fails too. It works fully hardcoded (i.e. alter role test with 'test').
c#, VS2013, latest dotConnect