如何转储PGresult [英] How to dump PGresult

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

问题描述

我正在尝试调试访问postgres数据库的C程序。

I am trying to debug my C program that accesses a postgres database.

我想使用提供的一些postgres例程转储PGresult的内容。

I would like to dump the contents of PGresult using some postgres provided routine.

是否有一个postgres提供的例程可以以人类可读的方式转储PGresult?

Is there a postgres provided routine that will dump PGresult in a human readable way?

我将其添加为一个选项

以下是非SELECT命令的相关问题:
如何为非SELECT命令转储PGresult

Here is a related question for non-SELECT commands: How to dump PGresult for non-SELECT commands

推荐答案

src / interfaces / libpq / fe-print.c 中,有一个公共功能 PQprint ;在手册中

In src/interfaces/libpq/fe-print.c there is a public function PQprint; it's in the manual.

这篇关于如何转储PGresult的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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