Re: 32KB Tuples
От | Jurgen Defurne |
---|---|
Тема | Re: 32KB Tuples |
Дата | |
Msg-id | 393E7CCF.F6D31441@glo.be обсуждение исходный текст |
Ответ на | RE: 32KB Tuples ("Eric Jain" <jain@gmx.net>) |
Список | pgsql-general |
Patrick Welche wrote: > On Tue, Jun 06, 2000 at 06:42:08PM +0200, Jurgen Defurne wrote: > > A 'tuple' is an element of a set. A set is also called a table. When you do N > > insertions on a table, then you get a table/set of N tuples. When you > > query a table/set, then your result is also a set. This set can consist of > > 0 to N tuples. > > > > To put it in another perspective : > > tuple <-> row <-> record > > relation <-> table <-> 'file' > > > > Since SQL manipulates sets, giving other sets, your first thought, is also > > correct. > > > > The other part of you question deals with projection, which means that > > you only take some fields. However, if you do a query like > > SELECT * FROM table WHERE select condition > > OR > > SELECT field1, field2 FROM table WHERE select condition > > > > both will return the same number of tuples, but in the second set, the > > tuples will consist of only two fields. > > So where is the 8K or 32K limit? For the > SELECT * FROM table WHERE select condition > or the > SELECT field1, field2 FROM table WHERE select condition > case? > > Cheers, > > Patrick The limit is in the length of the tuple of a base table. Counting the lengths of all fields in a tuple together may not be larger than 8192 bytes (or 32768 bytes if you changed your configuration). Suppose you have a tuple with 1 text field, then you will not be able to store more than 8192 bytes in the field. If you have two text fields, then if field 1 contains N bytes, then field 2 can only contain 8192 - N bytes. The limits are not in the SQL statements, but in the physical files which are used to create the tables. Jurgen Defurne defurnj@glo.be
В списке pgsql-general по дате отправления: