Skip site navigation (1) Skip section navigation (2)

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search for
  Advanced Search

Insert vs Update syntax



When inserting into a table and there are many columns to be inserted
it is hard to synchronize columns to values:

insert into my_table (
	a,
	b,
	c,
	...many more columns
)values(
	@a,
	@b,
	@c,
	... the corresponding values
)

Is there some reason for the insert syntax to be the way it is in
instead of the much easier to get it right Update syntax?:

update my_table
set a = @a,
b = @b,
c = @c,
...

Regards, Clodoaldo Pinto Neto



Home | Main Index | Thread Index

Privacy Policy | PostgreSQL Archives hosted by Command Prompt, Inc. | Designed by tinysofa
Copyright © 1996 – 2008 PostgreSQL Global Development Group