*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.139 2001/06/08 21:16:48 petere Exp $
+ * $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.140 2001/07/11 21:53:59 momjian Exp $
*
*-------------------------------------------------------------------------
*/
{ /* copy from file to database */
if (rel->rd_rel->relkind == RELKIND_SEQUENCE)
elog(ERROR, "You cannot change sequence relation %s", relname);
+ if (rel->rd_rel->relkind == RELKIND_VIEW)
+ elog(ERROR, "You cannot copy view %s", relname);
if (pipe)
{
if (IsUnderPostmaster)
}
else
{ /* copy from database to file */
+ if (rel->rd_rel->relkind == RELKIND_VIEW)
+ elog(ERROR, "You cannot copy view %s", relname);
if (pipe)
{
if (IsUnderPostmaster)