简体   繁体   English

从MS访问到包含MySQL的图片导出表(BLOB)

[英]export table containing pictures (BLOB) from ms access to mysql

i have a database table in MS-ACCESS format (MDB) containing structure as 我有一个MS-ACCESS格式 (MDB)的数据库表,其中包含以下结构

Form_No   Int
Picture   OLE OBJECT

when i import this table in MySQL using navicat, then the PICTURE field converts to BLOB and the field has no images(IMAGES ARE LOST). 当我使用navicat在MySQL中导入该表时,PICTURE字段将转换为BLOB且该字段没有图像(IMAGES ARE LOST)。 what to do ? 该怎么办 ?

OLE objects are tricky beasts - it is not exactly trivial to convert them into pictures. OLE对象是棘手的野兽-将它们转换为图片并非易事。

This article is an example of C# program (about 5KB) that can convert OLE object to few supported formats (JPEG, BMP, PDF, WORD). 本文是一个C#程序(大约5KB)的示例, 程序可以将OLE对象转换为几种受支持的格式(JPEG,BMP,PDF,WORD)。

You should be able to adapt it to your needs. 您应该能够使其适应您的需求。 I would think it will be easier to create new BLOB picture column in MS Access table first, convert it to real JPEG (not OLE!) using C#, and only then export it to MySQL. 我认为先在MS Access表中创建新的BLOB图片列,使用C#将其转换为真实JPEG(而不是OLE!),然后再将其导出到MySQL,会更容易。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM