summaryrefslogtreecommitdiff
path: root/src/include/postgres_ext.h
AgeCommit message (Collapse)Author
2017-06-21Phase 2 of pgindent updates.Tom Lane
Change pg_bsd_indent to follow upstream rules for placement of comments to the right of code, and remove pgindent hack that caused comments following #endif to not obey the general rule. Commit e3860ffa4dd0dad0dd9eea4be9cc1412373a8c89 wasn't actually using the published version of pg_bsd_indent, but a hacked-up version that tried to minimize the amount of movement of comments to the right of code. The situation of interest is where such a comment has to be moved to the right of its default placement at column 33 because there's code there. BSD indent has always moved right in units of tab stops in such cases --- but in the previous incarnation, indent was working in 8-space tab stops, while now it knows we use 4-space tabs. So the net result is that in about half the cases, such comments are placed one tab stop left of before. This is better all around: it leaves more room on the line for comment text, and it means that in such cases the comment uniformly starts at the next 4-space tab stop after the code, rather than sometimes one and sometimes two tabs after. Also, ensure that comments following #endif are indented the same as comments following other preprocessor commands such as #else. That inconsistency turns out to have been self-inflicted damage from a poorly-thought-through post-indent "fixup" in pgindent. This patch is much less interesting than the first round of indent changes, but also bulkier, so I thought it best to separate the effects. Discussion: https://postgr.es/m/[email protected] Discussion: https://postgr.es/m/[email protected]
2017-03-01Move atooid() definition to a central placePeter Eisentraut
2016-08-26Add a nonlocalized version of the severity field to client error messages.Tom Lane
This has been requested a few times, but the use-case for it was never entirely clear. The reason for adding it now is that transmission of error reports from parallel workers fails when NLS is active, because pq_parse_errornotice() wrongly assumes that the existing severity field is nonlocalized. There are other ways we could have fixed that, but the other options were basically kluges, whereas this way provides something that's at least arguably a useful feature along with the bug fix. Per report from Jakob Egger. Back-patch into 9.6, because otherwise parallel query is essentially unusable in non-English locales. The problem exists in 9.5 as well, but we don't want to risk changing on-the-wire behavior in 9.5 (even though the possibility of new error fields is specifically called out in the protocol document). It may be sufficient to leave the issue unfixed in 9.5, given the very limited usefulness of pq_parse_errornotice in that version. Discussion: <[email protected]>
2014-05-06pgindent run for 9.4Bruce Momjian
This includes removing tabs after periods in C comments, which was applied to back branches, so this change should not effect backpatching.
2013-01-29Provide database object names as separate fields in error messages.Tom Lane
This patch addresses the problem that applications currently have to extract object names from possibly-localized textual error messages, if they want to know for example which index caused a UNIQUE_VIOLATION failure. It adds new error message fields to the wire protocol, which can carry the name of a table, table column, data type, or constraint associated with the error. (Since the protocol spec has always instructed clients to ignore unrecognized field types, this should not create any compatibility problem.) Support for providing these new fields has been added to just a limited set of error reports (mainly, those in the "integrity constraint violation" SQLSTATE class), but we will doubtless add them to more calls in future. Pavel Stehule, reviewed and extensively revised by Peter Geoghegan, with additional hacking by Tom Lane.
2012-10-08Autoconfiscate selection of 64-bit int type for 64-bit large object API.Tom Lane
Get rid of the fundamentally indefensible assumption that "long long int" exists and is exactly 64 bits wide on every platform Postgres runs on. Instead let the configure script select the type to use for "pg_int64". This is a bit of a pain in the rear since we do not want to pollute client namespace with all the random symbols that pg_config.h defines; instead we have to create a separate generated header file, "pg_config_ext.h". But now that the infrastructure is there, we might have the ability to add some other stuff that's long been wanting in this area.
2012-10-06Add API for 64-bit large object access. Now users can access up toTatsuo Ishii
4TB large objects (standard 8KB BLCKSZ case). For this purpose new libpq API lo_lseek64, lo_tell64 and lo_truncate64 are added. Also corresponding new backend functions lo_lseek64, lo_tell64 and lo_truncate64 are added. inv_api.c is changed to handle 64-bit offsets. Patch contributed by Nozomi Anzai (backend side) and Yugo Nagata (frontend side, docs, regression tests and example program). Reviewed by Kohei Kaigai. Committed by Tatsuo Ishii with minor editings.
2010-09-20Remove cvs keywords from all files.Magnus Hagander
2007-02-06Move NAMEDATALEN definition from postgres_ext.h to pg_config_manual.h. ItPeter Eisentraut
used to be part of libpq's exported interface many releases ago, but now it's no longer necessary to make it accessible to clients.
2004-08-29Pgindent run for 8.0.Bruce Momjian
2004-03-21Revise syntax-error reporting behavior to give pleasant results forTom Lane
errors in internally-generated queries, such as those submitted by plpgsql functions. Per recent discussions with Fabien Coelho.
2003-11-29make sure the $Id tags are converted to $PostgreSQL as well ...PostgreSQL Daemon
2003-08-27Share PG_DIAG_* macros between client and server and use them internally.Peter Eisentraut
2003-03-18Compiling anything that uses InvalidOid under g++ yields a warning aboutBruce Momjian
the expression using an "old-style cast." Therefore, would it be okay to patch postgres_ext.h as follows: Jeroen T. Vermeulen
2002-08-13Change NAMEDATALEN to 64, INDEX_MAX_KEYS/MAX_FUNC_ARGS to 32, per ↵Bruce Momjian
discussion on hackers.
2002-04-30Document that NAMEDATALEN must be a multiple of sizeof(int).Tom Lane
2001-10-28Another pgindent run. Fixes enum indenting, and improves #endifBruce Momjian
spacing. Also adds space for one-line comments.
2001-10-25pgindent run on all C files. Java run to follow. initdb/regressionBruce Momjian
tests pass.
2001-03-22pgindent run. Make it all clean.Bruce Momjian
2001-02-10Restructure the key include files per recent pghackers discussion: thereTom Lane
are now separate files "postgres.h" and "postgres_fe.h", which are meant to be the primary include files for backend .c files and frontend .c files respectively. By default, only include files meant for frontend use are installed into the installation include directory. There is a new make target 'make install-all-headers' that adds the whole content of the src/include tree to the installed fileset, for use by people who want to develop server-side code without keeping the complete source tree on hand. Cleaned up a whole lot of crufty and inconsistent header inclusions.
2000-12-22Repair not-too-well-thought-out code to do rangechecking of OIDs onTom Lane
64-bit machines. Also, make oidvectorin use the same code as oidin.
1999-06-04Turns out OIDNAMELEN wasn't really being used at all!Tom Lane
Get rid of it to make customization of NAMEDATALEN easier.
1999-02-13Change my-function-name-- to my_function_name, and optimizer renames.Bruce Momjian
1997-09-07Massive commit to run PGINDENT on all *.c and *.h files.Bruce Momjian
1996-12-10Fix bug: libpq clients (which include libpq-fe.h) won't compile.Bryan Henderson
Plus: sigjmp_buf/jmp_buf is backwards, so backend doesn't compile.