Change NAMEDATALEN to 64, INDEX_MAX_KEYS/MAX_FUNC_ARGS to 32, per discussion on hackers.
This commit is contained in:
parent
f8b4a2e0f0
commit
46bb23ac01
@ -560,7 +560,7 @@
|
|||||||
Table, column, type, function, and view names are stored in system
|
Table, column, type, function, and view names are stored in system
|
||||||
tables in columns of type Name. Name is a fixed-length,
|
tables in columns of type Name. Name is a fixed-length,
|
||||||
null-terminated type of NAMEDATALEN bytes. (The default value for
|
null-terminated type of NAMEDATALEN bytes. (The default value for
|
||||||
NAMEDATALEN is 32 bytes.)
|
NAMEDATALEN is 64 bytes.)
|
||||||
typedef struct nameData
|
typedef struct nameData
|
||||||
{
|
{
|
||||||
char data[NAMEDATALEN];
|
char data[NAMEDATALEN];
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<!--
|
<!--
|
||||||
$Header: /cvsroot/pgsql/doc/src/sgml/datatype.sgml,v 1.97 2002/08/05 19:43:30 petere Exp $
|
$Header: /cvsroot/pgsql/doc/src/sgml/datatype.sgml,v 1.98 2002/08/13 20:40:43 momjian Exp $
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<chapter id="datatype">
|
<chapter id="datatype">
|
||||||
@ -914,7 +914,7 @@ SELECT b, char_length(b) FROM test2;
|
|||||||
<productname>PostgreSQL</productname>. The <type>name</type> type
|
<productname>PostgreSQL</productname>. The <type>name</type> type
|
||||||
exists <emphasis>only</emphasis> for storage of internal catalog
|
exists <emphasis>only</emphasis> for storage of internal catalog
|
||||||
names and is not intended for use by the general user. Its length
|
names and is not intended for use by the general user. Its length
|
||||||
is currently defined as 32 bytes (31 usable characters plus terminator)
|
is currently defined as 64 bytes (63 usable characters plus terminator)
|
||||||
but should be referenced using the macro
|
but should be referenced using the macro
|
||||||
<symbol>NAMEDATALEN</symbol>. The length is set at compile time
|
<symbol>NAMEDATALEN</symbol>. The length is set at compile time
|
||||||
(and is therefore adjustable for special uses); the default
|
(and is therefore adjustable for special uses); the default
|
||||||
@ -943,8 +943,8 @@ SELECT b, char_length(b) FROM test2;
|
|||||||
</row>
|
</row>
|
||||||
<row>
|
<row>
|
||||||
<entry>name</entry>
|
<entry>name</entry>
|
||||||
<entry>32 bytes</entry>
|
<entry>64 bytes</entry>
|
||||||
<entry>Thirty-one character internal type</entry>
|
<entry>Sixty-three character internal type</entry>
|
||||||
</row>
|
</row>
|
||||||
</tbody>
|
</tbody>
|
||||||
</tgroup>
|
</tgroup>
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/indices.sgml,v 1.35 2002/07/30 17:34:37 tgl Exp $ -->
|
<!-- $Header: /cvsroot/pgsql/doc/src/sgml/indices.sgml,v 1.36 2002/08/13 20:40:43 momjian Exp $ -->
|
||||||
|
|
||||||
<chapter id="indexes">
|
<chapter id="indexes">
|
||||||
<title id="indexes-title">Indexes</title>
|
<title id="indexes-title">Indexes</title>
|
||||||
@ -236,7 +236,7 @@ CREATE INDEX test2_mm_idx ON test2 (major, minor);
|
|||||||
|
|
||||||
<para>
|
<para>
|
||||||
Currently, only the B-tree and GiST implementations support multicolumn
|
Currently, only the B-tree and GiST implementations support multicolumn
|
||||||
indexes. Up to 16 columns may be specified. (This limit can be
|
indexes. Up to 32 columns may be specified. (This limit can be
|
||||||
altered when building <productname>PostgreSQL</productname>; see the
|
altered when building <productname>PostgreSQL</productname>; see the
|
||||||
file <filename>pg_config.h</filename>.)
|
file <filename>pg_config.h</filename>.)
|
||||||
</para>
|
</para>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<!--
|
<!--
|
||||||
$Header: /cvsroot/pgsql/doc/src/sgml/Attic/manage.sgml,v 1.22 2002/08/10 19:35:00 tgl Exp $
|
$Header: /cvsroot/pgsql/doc/src/sgml/Attic/manage.sgml,v 1.23 2002/08/13 20:40:43 momjian Exp $
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<Chapter Id="manage">
|
<Chapter Id="manage">
|
||||||
@ -70,7 +70,7 @@ ERROR: CREATE DATABASE: Permission denied.
|
|||||||
You automatically become the
|
You automatically become the
|
||||||
database administrator of the database you just created.
|
database administrator of the database you just created.
|
||||||
Database names must have an alphabetic first
|
Database names must have an alphabetic first
|
||||||
character and are limited to 31 characters in length.
|
character and are limited to 63 characters in length.
|
||||||
<ProductName>PostgreSQL</ProductName> allows you to create any number of
|
<ProductName>PostgreSQL</ProductName> allows you to create any number of
|
||||||
databases at a given site.
|
databases at a given site.
|
||||||
</Para>
|
</Para>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<!--
|
<!--
|
||||||
$Header: /cvsroot/pgsql/doc/src/sgml/ref/create_index.sgml,v 1.35 2002/07/30 17:34:37 tgl Exp $
|
$Header: /cvsroot/pgsql/doc/src/sgml/ref/create_index.sgml,v 1.36 2002/08/13 20:40:43 momjian Exp $
|
||||||
PostgreSQL documentation
|
PostgreSQL documentation
|
||||||
-->
|
-->
|
||||||
|
|
||||||
@ -339,7 +339,7 @@ ERROR: Cannot create index: 'index_name' already exists.
|
|||||||
|
|
||||||
<para>
|
<para>
|
||||||
Currently, only the B-tree and gist access methods support multicolumn
|
Currently, only the B-tree and gist access methods support multicolumn
|
||||||
indexes. Up to 16 keys may be specified by default (this limit
|
indexes. Up to 32 keys may be specified by default (this limit
|
||||||
can be altered when building
|
can be altered when building
|
||||||
<application>PostgreSQL</application>). Only B-tree currently supports
|
<application>PostgreSQL</application>). Only B-tree currently supports
|
||||||
unique indexes.
|
unique indexes.
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<!--
|
<!--
|
||||||
$Header: /cvsroot/pgsql/doc/src/sgml/ref/Attic/current_user.sgml,v 1.6 2002/04/21 19:02:39 thomas Exp $
|
$Header: /cvsroot/pgsql/doc/src/sgml/ref/Attic/current_user.sgml,v 1.7 2002/08/13 20:40:43 momjian Exp $
|
||||||
PostgreSQL documentation
|
PostgreSQL documentation
|
||||||
-->
|
-->
|
||||||
|
|
||||||
@ -77,7 +77,7 @@ The name of the current user.
|
|||||||
Notes
|
Notes
|
||||||
</TITLE>
|
</TITLE>
|
||||||
<PARA>
|
<PARA>
|
||||||
Data type "name" is a non-standard 31-character type for storing
|
Data type "name" is a non-standard 63-character type for storing
|
||||||
system identifiers.
|
system identifiers.
|
||||||
</PARA>
|
</PARA>
|
||||||
</REFSECT2>
|
</REFSECT2>
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<!--
|
<!--
|
||||||
$Header: /cvsroot/pgsql/doc/src/sgml/ref/listen.sgml,v 1.13 2002/04/21 19:02:39 thomas Exp $
|
$Header: /cvsroot/pgsql/doc/src/sgml/ref/listen.sgml,v 1.14 2002/08/13 20:40:43 momjian Exp $
|
||||||
PostgreSQL documentation
|
PostgreSQL documentation
|
||||||
-->
|
-->
|
||||||
|
|
||||||
@ -146,7 +146,7 @@ WARNING: Async_Listen: We are already listening on <replaceable class="PARAMETE
|
|||||||
it need not correspond to the name of any actual table. If
|
it need not correspond to the name of any actual table. If
|
||||||
<replaceable class="PARAMETER">notifyname</replaceable>
|
<replaceable class="PARAMETER">notifyname</replaceable>
|
||||||
is enclosed in double-quotes, it need not even be a syntactically
|
is enclosed in double-quotes, it need not even be a syntactically
|
||||||
valid name, but can be any string up to 31 characters long.
|
valid name, but can be any string up to 63 characters long.
|
||||||
</para>
|
</para>
|
||||||
<para>
|
<para>
|
||||||
In some previous releases of
|
In some previous releases of
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<!--
|
<!--
|
||||||
$Header: /cvsroot/pgsql/doc/src/sgml/ref/notify.sgml,v 1.17 2002/04/21 19:02:39 thomas Exp $
|
$Header: /cvsroot/pgsql/doc/src/sgml/ref/notify.sgml,v 1.18 2002/08/13 20:40:44 momjian Exp $
|
||||||
PostgreSQL documentation
|
PostgreSQL documentation
|
||||||
-->
|
-->
|
||||||
|
|
||||||
@ -180,7 +180,7 @@ NOTIFY
|
|||||||
it need not correspond to the name of any actual table. If
|
it need not correspond to the name of any actual table. If
|
||||||
<replaceable class="PARAMETER">name</replaceable>
|
<replaceable class="PARAMETER">name</replaceable>
|
||||||
is enclosed in double-quotes, it need not even be a syntactically
|
is enclosed in double-quotes, it need not even be a syntactically
|
||||||
valid name, but can be any string up to 31 characters long.
|
valid name, but can be any string up to 63 characters long.
|
||||||
</para>
|
</para>
|
||||||
<para>
|
<para>
|
||||||
In some previous releases of
|
In some previous releases of
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<!--
|
<!--
|
||||||
$Header: /cvsroot/pgsql/doc/src/sgml/ref/unlisten.sgml,v 1.18 2002/04/21 19:02:39 thomas Exp $
|
$Header: /cvsroot/pgsql/doc/src/sgml/ref/unlisten.sgml,v 1.19 2002/08/13 20:40:44 momjian Exp $
|
||||||
PostgreSQL documentation
|
PostgreSQL documentation
|
||||||
-->
|
-->
|
||||||
|
|
||||||
@ -114,7 +114,7 @@ UNLISTEN { <replaceable class="PARAMETER">notifyname</replaceable> | * }
|
|||||||
<para>
|
<para>
|
||||||
<replaceable class="PARAMETER">notifyname</replaceable>
|
<replaceable class="PARAMETER">notifyname</replaceable>
|
||||||
need not be a valid class name but can be any string valid
|
need not be a valid class name but can be any string valid
|
||||||
as a name up to 32 characters long.
|
as a name up to 64 characters long.
|
||||||
</para>
|
</para>
|
||||||
<para>
|
<para>
|
||||||
The backend does not complain if you UNLISTEN something you were not
|
The backend does not complain if you UNLISTEN something you were not
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<!--
|
<!--
|
||||||
$Header: /cvsroot/pgsql/doc/src/sgml/start.sgml,v 1.23 2002/08/10 19:35:00 tgl Exp $
|
$Header: /cvsroot/pgsql/doc/src/sgml/start.sgml,v 1.24 2002/08/13 20:40:43 momjian Exp $
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<chapter id="tutorial-start">
|
<chapter id="tutorial-start">
|
||||||
@ -231,7 +231,7 @@ createdb: database creation failed
|
|||||||
You can also create databases with other names.
|
You can also create databases with other names.
|
||||||
<productname>PostgreSQL</productname> allows you to create any
|
<productname>PostgreSQL</productname> allows you to create any
|
||||||
number of databases at a given site. Database names must have an
|
number of databases at a given site. Database names must have an
|
||||||
alphabetic first character and are limited to 31 characters in
|
alphabetic first character and are limited to 63 characters in
|
||||||
length. A convenient choice is to create a database with the same
|
length. A convenient choice is to create a database with the same
|
||||||
name as your current user name. Many tools assume that database
|
name as your current user name. Many tools assume that database
|
||||||
name as the default, so it can save you some typing. To create
|
name as the default, so it can save you some typing. To create
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
<!--
|
<!--
|
||||||
$Header: /cvsroot/pgsql/doc/src/sgml/syntax.sgml,v 1.65 2002/08/10 19:01:53 tgl Exp $
|
$Header: /cvsroot/pgsql/doc/src/sgml/syntax.sgml,v 1.66 2002/08/13 20:40:43 momjian Exp $
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<chapter id="sql-syntax">
|
<chapter id="sql-syntax">
|
||||||
@ -120,8 +120,8 @@ INSERT INTO MY_TABLE VALUES (3, 'hi there');
|
|||||||
The system uses no more than <symbol>NAMEDATALEN</symbol>-1
|
The system uses no more than <symbol>NAMEDATALEN</symbol>-1
|
||||||
characters of an identifier; longer names can be written in
|
characters of an identifier; longer names can be written in
|
||||||
commands, but they will be truncated. By default,
|
commands, but they will be truncated. By default,
|
||||||
<symbol>NAMEDATALEN</symbol> is 32 so the maximum identifier length
|
<symbol>NAMEDATALEN</symbol> is 64 so the maximum identifier length
|
||||||
is 31 (but at the time the system is built,
|
is 63 (but at the time the system is built,
|
||||||
<symbol>NAMEDATALEN</symbol> can be changed in
|
<symbol>NAMEDATALEN</symbol> can be changed in
|
||||||
<filename>src/include/postgres_ext.h</filename>).
|
<filename>src/include/postgres_ext.h</filename>).
|
||||||
</para>
|
</para>
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
*
|
*
|
||||||
* Copyright 2000-2002 by PostgreSQL Global Development Group
|
* Copyright 2000-2002 by PostgreSQL Global Development Group
|
||||||
*
|
*
|
||||||
* $Header: /cvsroot/pgsql/src/bin/psql/command.c,v 1.75 2002/08/10 03:56:23 tgl Exp $
|
* $Header: /cvsroot/pgsql/src/bin/psql/command.c,v 1.76 2002/08/13 20:40:44 momjian Exp $
|
||||||
*/
|
*/
|
||||||
#include "postgres_fe.h"
|
#include "postgres_fe.h"
|
||||||
#include "command.h"
|
#include "command.h"
|
||||||
@ -1513,7 +1513,7 @@ editFile(const char *fname)
|
|||||||
sys = malloc(strlen(editorName) + strlen(fname) + 32 + 1);
|
sys = malloc(strlen(editorName) + strlen(fname) + 32 + 1);
|
||||||
if (!sys)
|
if (!sys)
|
||||||
return false;
|
return false;
|
||||||
sprintf(sys, "exec %s %s", editorName, fname);
|
snprintf(sys, 32, "exec %s %s", editorName, fname);
|
||||||
result = system(sys);
|
result = system(sys);
|
||||||
if (result == -1)
|
if (result == -1)
|
||||||
psql_error("could not start editor %s\n", editorName);
|
psql_error("could not start editor %s\n", editorName);
|
||||||
|
@ -37,7 +37,7 @@
|
|||||||
* Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
|
* Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
|
||||||
* Portions Copyright (c) 1994, Regents of the University of California
|
* Portions Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: catversion.h,v 1.147 2002/08/09 16:45:14 tgl Exp $
|
* $Id: catversion.h,v 1.148 2002/08/13 20:40:44 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -53,6 +53,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/* yyyymmddN */
|
/* yyyymmddN */
|
||||||
#define CATALOG_VERSION_NO 200208091
|
#define CATALOG_VERSION_NO 200208131
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
* or in pg_config.h afterwards. Of course, if you edit pg_config.h, then your
|
* or in pg_config.h afterwards. Of course, if you edit pg_config.h, then your
|
||||||
* changes will be overwritten the next time you run configure.
|
* changes will be overwritten the next time you run configure.
|
||||||
*
|
*
|
||||||
* $Id: pg_config.h.in,v 1.26 2002/07/31 17:19:54 tgl Exp $
|
* $Id: pg_config.h.in,v 1.27 2002/08/13 20:40:44 momjian Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef PG_CONFIG_H
|
#ifndef PG_CONFIG_H
|
||||||
@ -162,7 +162,7 @@
|
|||||||
* switch statement in fmgr_oldstyle() in src/backend/utils/fmgr/fmgr.c.
|
* switch statement in fmgr_oldstyle() in src/backend/utils/fmgr/fmgr.c.
|
||||||
* But consider converting such functions to new-style instead...
|
* But consider converting such functions to new-style instead...
|
||||||
*/
|
*/
|
||||||
#define INDEX_MAX_KEYS 16
|
#define INDEX_MAX_KEYS 32
|
||||||
#define FUNC_MAX_ARGS INDEX_MAX_KEYS
|
#define FUNC_MAX_ARGS INDEX_MAX_KEYS
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -15,7 +15,7 @@
|
|||||||
* use header files that are otherwise internal to Postgres to interface
|
* use header files that are otherwise internal to Postgres to interface
|
||||||
* with the backend.
|
* with the backend.
|
||||||
*
|
*
|
||||||
* $Id: postgres_ext.h,v 1.10 2002/04/30 19:53:03 tgl Exp $
|
* $Id: postgres_ext.h,v 1.11 2002/08/13 20:40:44 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
@ -41,6 +41,6 @@ typedef unsigned int Oid;
|
|||||||
*
|
*
|
||||||
* NOTE that databases with different NAMEDATALEN's cannot interoperate!
|
* NOTE that databases with different NAMEDATALEN's cannot interoperate!
|
||||||
*/
|
*/
|
||||||
#define NAMEDATALEN 32
|
#define NAMEDATALEN 64
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -61,7 +61,7 @@ postgresql.res.colname:The column name {0} not found.
|
|||||||
postgresql.res.colrange:The column index is out of range.
|
postgresql.res.colrange:The column index is out of range.
|
||||||
postgresql.res.nextrequired:Result set not positioned properly, perhaps you need to call next().
|
postgresql.res.nextrequired:Result set not positioned properly, perhaps you need to call next().
|
||||||
postgresql.serial.interface:You cannot serialize an interface.
|
postgresql.serial.interface:You cannot serialize an interface.
|
||||||
postgresql.serial.namelength:Class & Package name length cannot be longer than 32 characters. {0} is {1} characters.
|
postgresql.serial.namelength:Class & Package name length cannot be longer than 64 characters. {0} is {1} characters.
|
||||||
postgresql.serial.noclass:No class found for {0}
|
postgresql.serial.noclass:No class found for {0}
|
||||||
postgresql.serial.table:The table for {0} is not in the database. Contact the DBA, as the database is in an inconsistent state.
|
postgresql.serial.table:The table for {0} is not in the database. Contact the DBA, as the database is in an inconsistent state.
|
||||||
postgresql.serial.underscore:Class names may not have _ in them. You supplied {0}.
|
postgresql.serial.underscore:Class names may not have _ in them. You supplied {0}.
|
||||||
|
@ -57,7 +57,7 @@ import java.sql.*;
|
|||||||
* There are a number of limitations placed on the java class to be
|
* There are a number of limitations placed on the java class to be
|
||||||
* used by Serialize:
|
* used by Serialize:
|
||||||
* <ul>
|
* <ul>
|
||||||
* <li>The class name must be less than 32 chars long and must be all lowercase.
|
* <li>The class name must be less than 64 chars long and must be all lowercase.
|
||||||
* This is due to limitations in Postgres about the size of table names.
|
* This is due to limitations in Postgres about the size of table names.
|
||||||
* The name must be all lowercase since table names in Postgres are
|
* The name must be all lowercase since table names in Postgres are
|
||||||
* case insensitive and the relname is stored in lowercase. Unless some
|
* case insensitive and the relname is stored in lowercase. Unless some
|
||||||
@ -577,7 +577,7 @@ public class Serialize
|
|||||||
*
|
*
|
||||||
* Because of this, a Class name may not have _ in the name.<p>
|
* Because of this, a Class name may not have _ in the name.<p>
|
||||||
* Another limitation, is that the entire class name (including packages)
|
* Another limitation, is that the entire class name (including packages)
|
||||||
* cannot be longer than 32 characters (a limit forced by PostgreSQL).
|
* cannot be longer than 64 characters (a limit forced by PostgreSQL).
|
||||||
*
|
*
|
||||||
* @param name Class name
|
* @param name Class name
|
||||||
* @return PostgreSQL table name
|
* @return PostgreSQL table name
|
||||||
@ -590,16 +590,16 @@ public class Serialize
|
|||||||
if (name.indexOf("_") > -1)
|
if (name.indexOf("_") > -1)
|
||||||
throw new PSQLException("postgresql.serial.underscore");
|
throw new PSQLException("postgresql.serial.underscore");
|
||||||
|
|
||||||
// Postgres table names can only be 32 character long.
|
// Postgres table names can only be 64 character long.
|
||||||
// Reserve 1 char, so allow only up to 31 chars.
|
// Reserve 1 char, so allow only up to 63 chars.
|
||||||
// If the full class name with package is too long
|
// If the full class name with package is too long
|
||||||
// then just use the class name. If the class name is
|
// then just use the class name. If the class name is
|
||||||
// too long throw an exception.
|
// too long throw an exception.
|
||||||
//
|
//
|
||||||
if ( name.length() > 31 )
|
if ( name.length() > 63 )
|
||||||
{
|
{
|
||||||
name = name.substring(name.lastIndexOf(".") + 1);
|
name = name.substring(name.lastIndexOf(".") + 1);
|
||||||
if ( name.length() > 31 )
|
if ( name.length() > 63 )
|
||||||
throw new PSQLException("postgresql.serial.namelength", name, new Integer(name.length()));
|
throw new PSQLException("postgresql.serial.namelength", name, new Integer(name.length()));
|
||||||
}
|
}
|
||||||
return name.replace('.', '_');
|
return name.replace('.', '_');
|
||||||
|
@ -19,86 +19,86 @@ SELECT name 'name string' = name 'name string ' AS "False";
|
|||||||
--
|
--
|
||||||
--
|
--
|
||||||
CREATE TABLE NAME_TBL(f1 name);
|
CREATE TABLE NAME_TBL(f1 name);
|
||||||
INSERT INTO NAME_TBL(f1) VALUES ('ABCDEFGHIJKLMNOP');
|
INSERT INTO NAME_TBL(f1) VALUES ('1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR');
|
||||||
INSERT INTO NAME_TBL(f1) VALUES ('abcdefghijklmnop');
|
INSERT INTO NAME_TBL(f1) VALUES ('1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqr');
|
||||||
INSERT INTO NAME_TBL(f1) VALUES ('asdfghjkl;');
|
INSERT INTO NAME_TBL(f1) VALUES ('asdfghjkl;');
|
||||||
INSERT INTO NAME_TBL(f1) VALUES ('343f%2a');
|
INSERT INTO NAME_TBL(f1) VALUES ('343f%2a');
|
||||||
INSERT INTO NAME_TBL(f1) VALUES ('d34aaasdf');
|
INSERT INTO NAME_TBL(f1) VALUES ('d34aaasdf');
|
||||||
INSERT INTO NAME_TBL(f1) VALUES ('');
|
INSERT INTO NAME_TBL(f1) VALUES ('');
|
||||||
INSERT INTO NAME_TBL(f1) VALUES ('1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ');
|
INSERT INTO NAME_TBL(f1) VALUES ('1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ');
|
||||||
SELECT '' AS seven, NAME_TBL.*;
|
SELECT '' AS seven, NAME_TBL.*;
|
||||||
seven | f1
|
seven | f1
|
||||||
-------+---------------------------------
|
-------+-----------------------------------------------------------------
|
||||||
| ABCDEFGHIJKLMNOP
|
| 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQ
|
||||||
| abcdefghijklmnop
|
| 1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopq
|
||||||
| asdfghjkl;
|
| asdfghjkl;
|
||||||
| 343f%2a
|
| 343f%2a
|
||||||
| d34aaasdf
|
| d34aaasdf
|
||||||
|
|
|
|
||||||
| 1234567890ABCDEFGHIJKLMNOPQRSTU
|
| 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQ
|
||||||
(7 rows)
|
(7 rows)
|
||||||
|
|
||||||
SELECT '' AS six, c.f1 FROM NAME_TBL c WHERE c.f1 <> 'ABCDEFGHIJKLMNOP';
|
SELECT '' AS six, c.f1 FROM NAME_TBL c WHERE c.f1 <> '1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR';
|
||||||
six | f1
|
six | f1
|
||||||
-----+---------------------------------
|
-----+-----------------------------------------------------------------
|
||||||
| abcdefghijklmnop
|
| 1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopq
|
||||||
| asdfghjkl;
|
| asdfghjkl;
|
||||||
| 343f%2a
|
| 343f%2a
|
||||||
| d34aaasdf
|
| d34aaasdf
|
||||||
|
|
|
|
||||||
| 1234567890ABCDEFGHIJKLMNOPQRSTU
|
(5 rows)
|
||||||
(6 rows)
|
|
||||||
|
|
||||||
SELECT '' AS one, c.f1 FROM NAME_TBL c WHERE c.f1 = 'ABCDEFGHIJKLMNOP';
|
SELECT '' AS one, c.f1 FROM NAME_TBL c WHERE c.f1 = '1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR';
|
||||||
one | f1
|
one | f1
|
||||||
-----+------------------
|
-----+-----------------------------------------------------------------
|
||||||
| ABCDEFGHIJKLMNOP
|
| 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQ
|
||||||
|
| 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQ
|
||||||
|
(2 rows)
|
||||||
|
|
||||||
|
SELECT '' AS three, c.f1 FROM NAME_TBL c WHERE c.f1 < '1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR';
|
||||||
|
three | f1
|
||||||
|
-------+----
|
||||||
|
|
|
||||||
(1 row)
|
(1 row)
|
||||||
|
|
||||||
SELECT '' AS three, c.f1 FROM NAME_TBL c WHERE c.f1 < 'ABCDEFGHIJKLMNOP';
|
SELECT '' AS four, c.f1 FROM NAME_TBL c WHERE c.f1 <= '1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR';
|
||||||
three | f1
|
|
||||||
-------+---------------------------------
|
|
||||||
| 343f%2a
|
|
||||||
|
|
|
||||||
| 1234567890ABCDEFGHIJKLMNOPQRSTU
|
|
||||||
(3 rows)
|
|
||||||
|
|
||||||
SELECT '' AS four, c.f1 FROM NAME_TBL c WHERE c.f1 <= 'ABCDEFGHIJKLMNOP';
|
|
||||||
four | f1
|
four | f1
|
||||||
------+---------------------------------
|
------+-----------------------------------------------------------------
|
||||||
| ABCDEFGHIJKLMNOP
|
| 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQ
|
||||||
| 343f%2a
|
|
||||||
|
|
|
|
||||||
| 1234567890ABCDEFGHIJKLMNOPQRSTU
|
| 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQ
|
||||||
(4 rows)
|
|
||||||
|
|
||||||
SELECT '' AS three, c.f1 FROM NAME_TBL c WHERE c.f1 > 'ABCDEFGHIJKLMNOP';
|
|
||||||
three | f1
|
|
||||||
-------+------------------
|
|
||||||
| abcdefghijklmnop
|
|
||||||
| asdfghjkl;
|
|
||||||
| d34aaasdf
|
|
||||||
(3 rows)
|
(3 rows)
|
||||||
|
|
||||||
SELECT '' AS four, c.f1 FROM NAME_TBL c WHERE c.f1 >= 'ABCDEFGHIJKLMNOP';
|
SELECT '' AS three, c.f1 FROM NAME_TBL c WHERE c.f1 > '1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR';
|
||||||
four | f1
|
three | f1
|
||||||
------+------------------
|
-------+-----------------------------------------------------------------
|
||||||
| ABCDEFGHIJKLMNOP
|
| 1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopq
|
||||||
| abcdefghijklmnop
|
| asdfghjkl;
|
||||||
| asdfghjkl;
|
| 343f%2a
|
||||||
| d34aaasdf
|
| d34aaasdf
|
||||||
(4 rows)
|
(4 rows)
|
||||||
|
|
||||||
|
SELECT '' AS four, c.f1 FROM NAME_TBL c WHERE c.f1 >= '1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR';
|
||||||
|
four | f1
|
||||||
|
------+-----------------------------------------------------------------
|
||||||
|
| 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQ
|
||||||
|
| 1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopq
|
||||||
|
| asdfghjkl;
|
||||||
|
| 343f%2a
|
||||||
|
| d34aaasdf
|
||||||
|
| 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQ
|
||||||
|
(6 rows)
|
||||||
|
|
||||||
SELECT '' AS seven, c.f1 FROM NAME_TBL c WHERE c.f1 ~ '.*';
|
SELECT '' AS seven, c.f1 FROM NAME_TBL c WHERE c.f1 ~ '.*';
|
||||||
seven | f1
|
seven | f1
|
||||||
-------+---------------------------------
|
-------+-----------------------------------------------------------------
|
||||||
| ABCDEFGHIJKLMNOP
|
| 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQ
|
||||||
| abcdefghijklmnop
|
| 1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopq
|
||||||
| asdfghjkl;
|
| asdfghjkl;
|
||||||
| 343f%2a
|
| 343f%2a
|
||||||
| d34aaasdf
|
| d34aaasdf
|
||||||
|
|
|
|
||||||
| 1234567890ABCDEFGHIJKLMNOPQRSTU
|
| 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQ
|
||||||
(7 rows)
|
(7 rows)
|
||||||
|
|
||||||
SELECT '' AS zero, c.f1 FROM NAME_TBL c WHERE c.f1 !~ '.*';
|
SELECT '' AS zero, c.f1 FROM NAME_TBL c WHERE c.f1 !~ '.*';
|
||||||
@ -108,11 +108,13 @@ SELECT '' AS zero, c.f1 FROM NAME_TBL c WHERE c.f1 !~ '.*';
|
|||||||
|
|
||||||
SELECT '' AS three, c.f1 FROM NAME_TBL c WHERE c.f1 ~ '[0-9]';
|
SELECT '' AS three, c.f1 FROM NAME_TBL c WHERE c.f1 ~ '[0-9]';
|
||||||
three | f1
|
three | f1
|
||||||
-------+---------------------------------
|
-------+-----------------------------------------------------------------
|
||||||
|
| 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQ
|
||||||
|
| 1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopq
|
||||||
| 343f%2a
|
| 343f%2a
|
||||||
| d34aaasdf
|
| d34aaasdf
|
||||||
| 1234567890ABCDEFGHIJKLMNOPQRSTU
|
| 1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQ
|
||||||
(3 rows)
|
(5 rows)
|
||||||
|
|
||||||
SELECT '' AS two, c.f1 FROM NAME_TBL c WHERE c.f1 ~ '.*asdf.*';
|
SELECT '' AS two, c.f1 FROM NAME_TBL c WHERE c.f1 ~ '.*asdf.*';
|
||||||
two | f1
|
two | f1
|
||||||
|
@ -14,9 +14,9 @@ SELECT name 'name string' = name 'name string ' AS "False";
|
|||||||
|
|
||||||
CREATE TABLE NAME_TBL(f1 name);
|
CREATE TABLE NAME_TBL(f1 name);
|
||||||
|
|
||||||
INSERT INTO NAME_TBL(f1) VALUES ('ABCDEFGHIJKLMNOP');
|
INSERT INTO NAME_TBL(f1) VALUES ('1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR');
|
||||||
|
|
||||||
INSERT INTO NAME_TBL(f1) VALUES ('abcdefghijklmnop');
|
INSERT INTO NAME_TBL(f1) VALUES ('1234567890abcdefghijklmnopqrstuvwxyz1234567890abcdefghijklmnopqr');
|
||||||
|
|
||||||
INSERT INTO NAME_TBL(f1) VALUES ('asdfghjkl;');
|
INSERT INTO NAME_TBL(f1) VALUES ('asdfghjkl;');
|
||||||
|
|
||||||
@ -26,22 +26,22 @@ INSERT INTO NAME_TBL(f1) VALUES ('d34aaasdf');
|
|||||||
|
|
||||||
INSERT INTO NAME_TBL(f1) VALUES ('');
|
INSERT INTO NAME_TBL(f1) VALUES ('');
|
||||||
|
|
||||||
INSERT INTO NAME_TBL(f1) VALUES ('1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ');
|
INSERT INTO NAME_TBL(f1) VALUES ('1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ');
|
||||||
|
|
||||||
|
|
||||||
SELECT '' AS seven, NAME_TBL.*;
|
SELECT '' AS seven, NAME_TBL.*;
|
||||||
|
|
||||||
SELECT '' AS six, c.f1 FROM NAME_TBL c WHERE c.f1 <> 'ABCDEFGHIJKLMNOP';
|
SELECT '' AS six, c.f1 FROM NAME_TBL c WHERE c.f1 <> '1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR';
|
||||||
|
|
||||||
SELECT '' AS one, c.f1 FROM NAME_TBL c WHERE c.f1 = 'ABCDEFGHIJKLMNOP';
|
SELECT '' AS one, c.f1 FROM NAME_TBL c WHERE c.f1 = '1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR';
|
||||||
|
|
||||||
SELECT '' AS three, c.f1 FROM NAME_TBL c WHERE c.f1 < 'ABCDEFGHIJKLMNOP';
|
SELECT '' AS three, c.f1 FROM NAME_TBL c WHERE c.f1 < '1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR';
|
||||||
|
|
||||||
SELECT '' AS four, c.f1 FROM NAME_TBL c WHERE c.f1 <= 'ABCDEFGHIJKLMNOP';
|
SELECT '' AS four, c.f1 FROM NAME_TBL c WHERE c.f1 <= '1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR';
|
||||||
|
|
||||||
SELECT '' AS three, c.f1 FROM NAME_TBL c WHERE c.f1 > 'ABCDEFGHIJKLMNOP';
|
SELECT '' AS three, c.f1 FROM NAME_TBL c WHERE c.f1 > '1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR';
|
||||||
|
|
||||||
SELECT '' AS four, c.f1 FROM NAME_TBL c WHERE c.f1 >= 'ABCDEFGHIJKLMNOP';
|
SELECT '' AS four, c.f1 FROM NAME_TBL c WHERE c.f1 >= '1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890ABCDEFGHIJKLMNOPQR';
|
||||||
|
|
||||||
SELECT '' AS seven, c.f1 FROM NAME_TBL c WHERE c.f1 ~ '.*';
|
SELECT '' AS seven, c.f1 FROM NAME_TBL c WHERE c.f1 ~ '.*';
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user