longblob 形式を表示するにはどうすればよいですか?
c# を使用して、MYSQL で「コンテンツ」ロングブロブ形式を取得したいと考えています。
string MyConnectionString = "Server=localhost;Database=newsborad;Uid=root;Pwd=root;";
//this is the connection with the MYSQL
MySqlConnection conn = new MySqlConnection(MyConnectionString); //communicate MYSQL
MySqlCommand cmd = conn.CreateCommand();
conn.Open();
//content is longblob format in MYSQL
cmd.CommandText = "Select content from message where msg_id = @id";
cmd.Parameters.AddWithValue("@id", "1");
while (reader.Read())
{
//how i should code?
}
conn.Close();