pgAdmin III:如何查看blob? [英] pgAdmin III: How to view a blob?

查看:127
本文介绍了pgAdmin III:如何查看blob?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我了解PostgreSQL将BLOB内容写到一个单独的表中,但是有什么方法可以从pgAdmin内部以简便的方式查看blob内容?

I understand that PostgreSQL writes BLOB content to a separate table, but is there any way to view the blob contents in an easy and convenient way from inside pgAdmin?

推荐答案

我不确定您所说的简单便捷"是什么意思,但是最好的办法是lo_read(...)

I am not sure what you mean by "easy and convenient" but the best you can do is lo_read(...)

这将lob表示为bytea.

从获取数据的角度来看,这很容易和方便,但是pgAdmin不会为您将转义的字符串转换回原始二进制文件,因此您只需要查看二进制文件的文本表示形式,就可以了如果要以png格式或其他格式显示lob中包含的图像,则简单方便".

This is easy and convenient in the sense of getting data out but you pgAdmin won't convert from an escaped string back into the original binary for you so you are left looking at the textual representation of the binary, so it is not "easy and convenient" if you want to show the image contained in a lob when that is in png format or anything.

这篇关于pgAdmin III:如何查看blob?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆