Hi,
I am new to Postgresql, so pls be patient.
I am using npgsql with C# to insert a bytea value into a
column which will serve as an encrypted password. This works
well. However, when I retrieve the value, it is different.
In other words, "select pwd from table where pwd like @pwd"
does not work.
Is it not possible to compare bytea columns?
...get dbConn...
NpgsqlCommand cmd = new NpgsqlCommand("select pwd from table
where usr = @usr and pwd like @pwd",dbConn);
cmd.Parameters.Add(new NpgsqlParameter("usr",DbType.String);
cmd.Parameters.Add(new
NpgsqlParameter("pwd",NpgsqlTypes.NpgsqlDbType.Bytea);
cmd.prepare()
... set param values, call executereader...
Thanks,
JM
----------------------------------------
Upgrade your account today for increased storage; mail
forwarding or POP enabled e-mail with automatic virus
scanning. Visit our member benefits page at
https://members.canada.com/benefits.aspx for more
information.