summaryrefslogtreecommitdiff
path: root/src/backend/utils/adt/arrayfuncs.c
AgeCommit message (Collapse)Author
2001-01-24Change Copyright from PostgreSQL, Inc to PostgreSQL Global Development Group.Bruce Momjian
2000-12-27Fix portability problems recently exposed by regression tests on Alphas.Tom Lane
1. Distinguish cases where a Datum representing a tuple datatype is an OID from cases where it is a pointer to TupleTableSlot, and make sure we use the right typlen in each case. 2. Make fetchatt() and related code support 8-byte by-value datatypes on machines where Datum is 8 bytes. Centralize knowledge of the available by-value datatype sizes in two macros in tupmacs.h, so that this will be easier if we ever have to do it again.
2000-12-03Ensure that all uses of <ctype.h> functions are applied to unsigned-charTom Lane
values, whether the local char type is signed or not. This is necessary for portability. Per discussion on pghackers around 9/16/00.
2000-11-16Change SearchSysCache coding conventions so that a reference count isTom Lane
maintained for each cache entry. A cache entry will not be freed until the matching ReleaseSysCache call has been executed. This eliminates worries about cache entries getting dropped while still in use. See my posting to pg-hackers of even date for more info.
2000-11-14Clean up array-dimensions parser a bit.Tom Lane
This code still needs a lot of love, however ...
2000-07-27Ensure that values stored within arrays are not toasted, perTom Lane
discussion on pghackers a few days ago.
2000-07-23Further cleanup of array behavior. Slice assignments to arrays withTom Lane
varlena elements work now. Allow assignment to previously-nonexistent subscript position to extend array, but only for 1-D arrays and only if adjacent to existing positions (could do more if we had a way to represent nulls in arrays, but I don't want to tackle that now). Arrange for assignment of NULL to an array element in UPDATE to be a no-op, rather than setting the entire array to NULL as it used to. (Throwing an error would be a reasonable alternative, but it's never done that...) Update regress test accordingly.
2000-07-22Arrays are toastable. (At least if you initdb, which I didn't force.)Tom Lane
Remove a bunch of crufty code for large-object-based arrays, which is superseded by TOAST and likely hasn't worked in a long time anyway. Clean up array code a little, and in particular eliminate its habit of scribbling on the input array (ie, modifying the input tuple :-().
2000-07-17Revise aggregate functions per earlier discussions in pghackers.Tom Lane
There's now only one transition value and transition function. NULL handling in aggregates is a lot cleaner. Also, use Numeric accumulators instead of integer accumulators for sum/avg on integer datatypes --- this avoids overflow at the cost of being a little slower. Implement VARIANCE() and STDDEV() aggregates in the standard backend. Also, enable new LIKE selectivity estimators by default. Unrelated change, but as long as I had to force initdb anyway...
2000-07-03TOASTJan Wieck
WARNING: This is actually broken - we have self-deadlocks due to concurrent changes in buffer management. Vadim and me are working on it. Jan
2000-06-14Big warnings cleanup for Solaris/GCC. Down to about 40 now, butPeter Eisentraut
we'll get there one day. Use `cat' to create aclocal.m4, not `aclocal'. Some people don't have automake installed. Only run the autoconf rule in the top-level GNUmakefile if the invoker specified `make configure', don't run it automatically because of CVS timestamp skew.
2000-06-14I had overlooked the fact that some fmgr-callable functions return voidTom Lane
--- ie, they're only called for side-effects. Add a PG_RETURN_VOID() macro and use it where appropriate. This probably doesn't change the machine code by a single bit ... it's just for documentation.
2000-06-13Another batch of fmgr updates. I think I have gotten all old-styleTom Lane
functions that take pass-by-value datatypes. Should be ready for port testing ...
2000-06-09Another round of updates for new fmgr, mostly in the datetime code.Tom Lane
2000-06-02Remove NT-specific file open defines by defining our own open macros forBruce Momjian
"rb" and "wb".
2000-05-30Third round of fmgr updates: eliminate calls using fmgr() andTom Lane
fmgr_faddr() in favor of new-style calls. Lots of cleanup of sloppy casts to use XXXGetDatum and DatumGetXXX ...
2000-05-29Convert array_map to use new fmgr interface.Tom Lane
2000-01-26Add:Bruce Momjian
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc to all files copyright Regents of Berkeley. Man, that's a lot of files.
2000-01-15Fix a passel of problems with incorrect calls to typinput and typoutputTom Lane
functions, which would lead to trouble with datatypes that paid attention to the typelem or typmod parameters to these functions. In particular, incorrect code in pg_aggregate.c explains the platform-specific failures that have been reported in NUMERIC avg().
1999-12-09Update for QNX from Kardos, Dr. AndreaBruce Momjian
1999-11-22Add system indexes to match all caches.Bruce Momjian
Make all system indexes unique. Make all cache loads use system indexes. Rename *rel to *relid in inheritance tables. Rename cache names to be clearer.
1999-07-19Install new alignment code to use MAXALIGN rather than DOUBLEALIGN whereBruce Momjian
approproate.
1999-07-17 Move some system includes into c.h, and remove duplicates.Bruce Momjian
1999-07-16Final cleanup.Bruce Momjian
1999-07-15Remove un-needed #include's from *.c files.Bruce Momjian
1999-07-15Clean up #include in /include directory. Add scripts for checking includes.Bruce Momjian
1999-05-25pgindent run over code.Bruce Momjian
1999-05-10Change error messages to oids come out as %u and not %d. Change has noBruce Momjian
real affect now.
1999-05-05I have two patches for 6.5.0:Bruce Momjian
arrayfuncs.patch fixes a small bug in my previous patches for arrays array-regress.patch adds _bpchar and _varchar to regression tests -- Massimo Dal Zotto
1999-05-03Correct declaration of array_map() so that it doesn't makeTom Lane
gcc quite so unhappy.
1999-05-03here are some patches for 6.5.0 which I already submitted but have neverBruce Momjian
been applied. The patches are in the .tar.gz attachment at the end: varchar-array.patch this patch adds support for arrays of bpchar() and varchar(), which where always missing from postgres. These datatypes can be used to replace the _char4, _char8, etc., which were dropped some time ago. block-size.patch this patch fixes many errors in the parser and other program which happen with very large query statements (> 8K) when using a page size larger than 8192. This patch is needed if you want to submit queries larger than 8K. Postgres supports tuples up to 32K but you can't insert them because you can't submit queries larger than 8K. My patch fixes this problem. The patch also replaces all the occurrences of `8192' and `1<<13' in the sources with the proper constants defined in include files. You should now never find 8192 hardwired in C code, just to make code clearer. -- Massimo Dal Zotto
1999-02-13Change my-function-name-- to my_function_name, and optimizer renames.Bruce Momjian
1999-02-03Cleanup of source files where 'return' or 'var =' is alone on a line.Bruce Momjian
1999-01-17TCL_ARRAYS option patches from Massimo Dal ZottoTom Lane
1999-01-17Apply Win32 patch from Horak Daniel.Bruce Momjian
1998-09-01OK, folks, here is the pgindent output.Bruce Momjian
1998-09-01Renaming cleanup, no pgindent yet.Bruce Momjian
1998-08-19heap_fetch requires buffer pointer, must be released; heap_getnextBruce Momjian
no longer returns buffer pointer, can be gotten from scan; descriptor; bootstrap can create multi-key indexes; pg_procname index now is multi-key index; oidint2, oidint4, oidname are gone (must be removed from regression tests); use System Cache rather than sequential scan in many places; heap_modifytuple no longer takes buffer parameter; remove unused buffer parameter in a few other functions; oid8 is not index-able; remove some use of single-character variable names; cleanup Buffer variables usage and scan descriptor looping; cleaned up allocation and freeing of tuples; 18k lines of diff;
1998-07-12Change atttypmod from int16 to int32, for Thomas.Bruce Momjian
1998-06-15Remove un-needed braces around single statements.Bruce Momjian
1998-03-30There's a patch attached to fix gcc 2.8.x warnings, except for theBruce Momjian
yyerror ones from bison. It also includes a few 'enhancements' to the C programming style (which are, of course, personal). The other patch removes the compilation of backend/lib/qsort.c, as qsort() is a standard function in stdlib.h and can be used any where else (and it is). It was only used in backend/optimizer/geqo/geqo_pool.c, backend/optimizer/path/predmig.c, and backend/storage/page/bufpage.c > > Some or all of these changes might not be appropriate for v6.3, since we > > are in beta testing and since they do not affect the current functionality. > > For those cases, how about submitting patches based on the final v6.3 > > release? There's more to come. Please review these patches. I ran the regression tests and they only failed where this was expected (random, geo, etc). Cheers, Jeroen
1998-03-20> > I'm using text[] arrays. Some of my array elements have '"'Bruce Momjian
> > characters in them. Dumping and reloading using pg_dumpall > > doesn't work with this and dumping the entire array and > > then trying to parse it is hopeless. Doug Gibson
1998-02-26pgindent run before 6.3 release, with Thomas' requested changes.Bruce Momjian
1998-02-14From: Tom I Helbekkmo <tih@Hamartun.Priv.NO>Marc G. Fournier
The file 'backend/utils/adt/arrayfuncs.c' won't compile with the February 14th snapshot, because of an inconsistency between the declaration and implementation of ReadArrayStr(). As far as I can tell, the predeclaration is wrong. I assume this is what was meant:
1998-02-13Atttypmod cleanup.Bruce Momjian
1998-01-15Thank god for searchable mail archives.PostgreSQL Daemon
Patch by: wieck@sapserv.debis.de (Jan Wieck) One of the design rules of PostgreSQL is extensibility. And to follow this rule means (at least for me) that there should not only be a builtin PL. Instead I would prefer a defined interface for PL implemetations.
1998-01-05Change some ABORTS to ERROR. Add line number when COPY Failure.Bruce Momjian
1998-01-05Change elog(WARN) to elog(ERROR) and elog(ABORT).Bruce Momjian
1997-12-06Add VARHDRSZ where needed. Many places just used 4.Bruce Momjian
1997-09-18Inline memset() as MemSet().Bruce Momjian