Реклама:

info.krc.karelia.ru

win -:|:- koi -:|:- iso -:|:- dos -:|:- mac

Start -:|:- Проекты -:|:- О нас

Functions Associated with the COPY Command

The copy command in Postgres has options to read from or write to the network connection used by libpq++. Therefore, functions are necessary to access this network connection directly so applications may take full advantage of this capability.

As an example:

	PgDatabase data;
	data.exec("create table foo (a int4, b char16, d float8)");
	data.exec("copy foo from stdin");
	data.putline("3\etHello World\et4.5\en");
	data.putline("4\etGoodbye World\et7.11\en");
	&...
	data.putline(".\en");
	data.endcopy();