Re: can I update multiple table at a time?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 9 Oct 2008 22:12:04 -0700 (PDT)
Jagadeesh <mnjagadeesh@xxxxxxxxx> wrote:

> Hello Gurus,
> 
> Is it possible to update two table using single sql statement? huh?
> let me be clear
> 
> I have table master with state and date field. And in history table I
> have same fields i.e., state and date. I'm writing an update statement
> to set 'open' state records  to 'closed' state after 7. both table can
> be joined using id.
> 
> Any thoughts?

Use a transaction?

> 
> Thanks
> 


-- 
The PostgreSQL Company since 1997: http://www.commandprompt.com/ 
PostgreSQL Community Conference: http://www.postgresqlconference.org/
United States PostgreSQL Association: http://www.postgresql.us/




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux