Returning number of rows - Copy In function - Mailing list pgsql-hackers

From mike g
Subject Returning number of rows - Copy In function
Date
Msg-id 1080274814.21249.39.camel@localhost.localdomain
Whole thread Raw
List pgsql-hackers
Hello,

I was looking at putting the code for this in copy.c
CopyReadLineFunction.

If I do a printf at point A it compiles, installs, runs, doesn't display
any data after running initdb and returns a result when a COPY FROM is
executed in psql.

If I do a printf at point B it compiles, installs, and then crashes when
executing initdb.


loading pg_description ... initdb: child process exited with exit code
139
initdb: failed


Thoughts on why A is ok but B is not?

I don't really want to send any results to the screen if it is called
when first creating a database.  I have looked for something like
CMD_SELECT to identify when Initdb is executed.

Is their an existing variable I can check that I have not found?


Attachment

pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Per database users/admins, handy for database virtual hosting...
Next
From: Sean Chittenden
Date:
Subject: Re: Per database users/admins, handy for database virtual hosting...