aboutsummaryrefslogtreecommitdiff
path: root/src/backend/commands/dbcommands.c
diff options
context:
space:
mode:
authorBruce Momjian <bruce@momjian.us>1998-08-24 01:14:24 +0000
committerBruce Momjian <bruce@momjian.us>1998-08-24 01:14:24 +0000
commitc0b01461db59a472f5817a8c6e99091b8a48ffc5 (patch)
tree8ea77fde00c4a8da22920d9d0aa7f8b8a77e67e0 /src/backend/commands/dbcommands.c
parent9438fe5d091162136e96991da391a559e078aa23 (diff)
downloadpostgresql-c0b01461db59a472f5817a8c6e99091b8a48ffc5.tar.gz
postgresql-c0b01461db59a472f5817a8c6e99091b8a48ffc5.zip
o note that now pg_database has a new attribuite "encoding" even
if MULTIBYTE is not enabled. So be sure to run initdb. o these patches are made against the latest source tree (after Bruce's massive patch, I think) BTW, I noticed that after running regression, the oid field of pg_type seems disappeared. regression=> select oid from pg_type; ERROR: attribute 'oid' not found this happens after the constraints test. This occures with/without my patches. strange... o pg_database_mb.h, pg_class_mb.h, pg_attribute_mb.h are no longer used, and shoud be removed. o GetDatabaseInfo() in utils/misc/database.c removed (actually in #ifdef 0). seems nobody uses. t-ishii@sra.co.jp
Diffstat (limited to 'src/backend/commands/dbcommands.c')
-rw-r--r--src/backend/commands/dbcommands.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/backend/commands/dbcommands.c b/src/backend/commands/dbcommands.c
index a0438129dff..80cb60f203a 100644
--- a/src/backend/commands/dbcommands.c
+++ b/src/backend/commands/dbcommands.c
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/dbcommands.c,v 1.20 1998/08/19 02:01:46 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/dbcommands.c,v 1.21 1998/08/24 01:13:40 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -43,7 +43,7 @@ static HeapTuple get_pg_dbtup(char *command, char *dbname, Relation dbrel);
static void stop_vacuum(char *dbpath, char *dbname);
void
-createdb(char *dbname, char *dbpath)
+createdb(char *dbname, char *dbpath, int encoding)
{
Oid db_id,
user_id;
@@ -90,8 +90,9 @@ createdb(char *dbname, char *dbpath)
dbname, user_id, dbname);
#endif
- sprintf(buf, "insert into pg_database (datname, datdba, datpath)"
- " values (\'%s\', \'%d\', \'%s\');", dbname, user_id, loc);
+ sprintf(buf, "insert into pg_database (datname, datdba, encoding, datpath)"
+ " values (\'%s\', \'%d\', \'%d\', \'%s\');", dbname, user_id, encoding, loc);
+
pg_exec_query(buf);
}