Index: command.c =================================================================== RCS file: /projects/cvsroot/pgsql-server/src/bin/psql/command.c,v retrieving revision 1.74 diff -c -r1.74 command.c *** command.c 2002/07/18 02:02:30 1.74 --- command.c 2002/08/09 00:42:31 *************** *** 749,754 **** --- 749,766 ---- free(opt); } + /* \v -- prints server and client version information */ + else if (strcmp(cmd, "v") == 0) + { + PGresult *res; + puts("Client: "); + puts(GetVariable(pset.vars, "VERSION")); + puts("Server: "); + res = PSQLexec("SELECT version();"); + puts(PQgetvalue(res, 0, 0)); + PQclear(res); + } + /* \w -- write query buffer to file */ else if (strcmp(cmd, "w") == 0 || strcmp(cmd, "write") == 0) {