点 (.) 正在从 MySQL 数据库中检索©

本文关键字:数据库 检索 MySQL | 更新日期: 2023-09-27 18:35:11

>我已经将图像的路径存储在MYSQL表中。现在,当我尝试检索路径时,除了.jpg的点(.)作为jpg检索©之外,所有路径都被正确检索,因此出现了不存在此类文件的异常。

string fileName =Convert.ToString(dt.Rows[rowIndex]["photo"]);    //File name with Exstension and Path
        FileInfo fi = new FileInfo(fileName);
        BitmapImage img = new BitmapImage();    //BitmapImage for showing in the image control
        img.BeginInit();
        img.UriSource = new Uri(fileName);
        img.EndInit();
        imgPic.Source = img;

我的问题窗口的屏幕截图

点 (.) 正在从 MySQL 数据库中检索©

我发现了问题。我实际上已将该特定列的排序规则从ascii_general_ci更改为armscii8_general_ci