mirror of
https://github.com/postgres/postgres.git
synced 2025-07-28 23:42:10 +03:00
updated install file
updated date/time types doc fixed small psql bug removed libpq code that lower-cased db names make notice when long identifier is truncated
This commit is contained in:
@ -8,7 +8,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/backend/parser/scan.l,v 1.61 2000/01/20 05:26:53 tgl Exp $
|
||||
* $Header: /cvsroot/pgsql/src/backend/parser/scan.l,v 1.62 2000/01/23 01:27:35 petere Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -338,8 +338,11 @@ other .
|
||||
isupper(yytext[i]))
|
||||
yytext[i] = tolower(yytext[i]);
|
||||
if (i >= NAMEDATALEN)
|
||||
{
|
||||
elog(NOTICE, "identifier \"%s\" will be truncated to \"%.*s\"",
|
||||
yytext, NAMEDATALEN-1, yytext);
|
||||
yytext[NAMEDATALEN-1] = '\0';
|
||||
|
||||
}
|
||||
keyword = ScanKeywordLookup((char*)yytext);
|
||||
if (keyword != NULL) {
|
||||
return keyword->value;
|
||||
|
@ -3,7 +3,7 @@
|
||||
*
|
||||
* Copyright 2000 by PostgreSQL Global Development Team
|
||||
*
|
||||
* $Header: /cvsroot/pgsql/src/bin/psql/command.c,v 1.14 2000/01/22 14:20:51 petere Exp $
|
||||
* $Header: /cvsroot/pgsql/src/bin/psql/command.c,v 1.15 2000/01/23 01:27:37 petere Exp $
|
||||
*/
|
||||
#include <c.h>
|
||||
#include "command.h"
|
||||
@ -1198,6 +1198,7 @@ process_file(char *filename)
|
||||
{
|
||||
FILE *fd;
|
||||
int result;
|
||||
char *oldfilename;
|
||||
|
||||
if (!filename)
|
||||
return false;
|
||||
@ -1214,10 +1215,11 @@ process_file(char *filename)
|
||||
return false;
|
||||
}
|
||||
|
||||
oldfilename = pset.inputfile;
|
||||
pset.inputfile = filename;
|
||||
result = MainLoop(fd);
|
||||
fclose(fd);
|
||||
pset.inputfile = NULL;
|
||||
pset.inputfile = oldfilename;
|
||||
return (result == EXIT_SUCCESS);
|
||||
}
|
||||
|
||||
|
@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.113 2000/01/18 19:05:31 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.114 2000/01/23 01:27:39 petere Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -467,25 +467,6 @@ PQsetdbLogin(const char *pghost, const char *pgport, const char *pgoptions,
|
||||
else
|
||||
conn->dbName = strdup(dbName);
|
||||
|
||||
if (conn->dbName)
|
||||
{
|
||||
|
||||
/*
|
||||
* if the database name is surrounded by double-quotes, then don't
|
||||
* convert case
|
||||
*/
|
||||
if (*conn->dbName == '"')
|
||||
{
|
||||
strcpy(conn->dbName, conn->dbName + 1);
|
||||
conn->dbName[strlen(conn->dbName) - 1] = '\0';
|
||||
}
|
||||
else
|
||||
for (i = 0; conn->dbName[i]; i++)
|
||||
if (isascii((unsigned char) conn->dbName[i]) &&
|
||||
isupper(conn->dbName[i]))
|
||||
conn->dbName[i] = tolower(conn->dbName[i]);
|
||||
}
|
||||
|
||||
if (error)
|
||||
{
|
||||
conn->status = CONNECTION_BAD;
|
||||
|
Reference in New Issue
Block a user