* Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/backend/commands/user.c,v 1.147 2004/12/31 21:59:42 pgsql Exp $
+ * $PostgreSQL: pgsql/src/backend/commands/user.c,v 1.147.4.1 2005/10/26 13:43:28 momjian Exp $
*
*-------------------------------------------------------------------------
*/
errmsg("could not write to temporary file \"%s\": %m", tempname)));
/*
- * Read pg_group and write the file. Note we use SnapshotSelf to
- * ensure we see all effects of current transaction. (Perhaps could
- * do a CommandCounterIncrement beforehand, instead?)
+ * Read pg_group and write the file
*/
- scan = heap_beginscan(grel, SnapshotSelf, 0, NULL);
+ CommandCounterIncrement(); /* see our current changes */
+ scan = heap_beginscan(grel, SnapshotNow, 0, NULL);
while ((tuple = heap_getnext(scan, ForwardScanDirection)) != NULL)
{
Datum datum,
errmsg("could not write to temporary file \"%s\": %m", tempname)));
/*
- * Read pg_shadow and write the file. Note we use SnapshotSelf to
- * ensure we see all effects of current transaction. (Perhaps could
- * do a CommandCounterIncrement beforehand, instead?)
+ * Read pg_shadow and write the file
*/
- scan = heap_beginscan(urel, SnapshotSelf, 0, NULL);
+ CommandCounterIncrement(); /* see our current changes */
+ scan = heap_beginscan(urel, SnapshotNow, 0, NULL);
while ((tuple = heap_getnext(scan, ForwardScanDirection)) != NULL)
{
Datum datum;
* Set flag to update flat password file at commit.
*/
user_file_update_needed();
+ group_file_update_needed();
}
* Set flag to update flat password file at commit.
*/
user_file_update_needed();
+ group_file_update_needed();
}
heap_close(rel, NoLock);
user_file_update_needed();
+ group_file_update_needed();
}