Re: Update field value

From: "Phillip Smith" <phillip(dot)smith(at)weatherbeeta(dot)com(dot)au>
To: "'roody senecal'" <roodysenecal(at)yahoo(dot)com>, <pgsql-novice(at)postgresql(dot)org>
Subject: Re: Update field value
Date: 2007-11-26 02:26:27
Message-ID: 00d901c82fd3$bf4e3e00$9b0014ac@wbaus090
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

In psql or pgAdmin, connect to your database then.

UPDATE table_name_here SET wrong_field = TRUE WHERE wrong_field = FALSE;

-----Original Message-----
From: pgsql-novice-owner(at)postgresql(dot)org
[mailto:pgsql-novice-owner(at)postgresql(dot)org] On Behalf Of roody senecal
Sent: Monday, 26 November 2007 13:23
To: pgsql-novice(at)postgresql(dot)org
Subject: [NOVICE] Update field value

Hello, this question maybe a bit simple: I just migrated to postgres, One of
my table with over 10,000 records have one field who's value should be True,
however when the data was imported it was set to False. How can I automated
changing this value. If I need to write a script can you please give me an
example I can follow.

Thanks
Roody

THINK BEFORE YOU PRINT - Save paper if you don't really need to print this

*******************Confidentiality and Privilege Notice*******************

The material contained in this message is privileged and confidential to
the addressee. If you are not the addressee indicated in this message or
responsible for delivery of the message to such person, you may not copy
or deliver this message to anyone, and you should destroy it and kindly
notify the sender by reply email.

Information in this message that does not relate to the official business
of Weatherbeeta must be treated as neither given nor endorsed by Weatherbeeta.
Weatherbeeta, its employees, contractors or associates shall not be liable
for direct, indirect or consequential loss arising from transmission of this
message or any attachments
e-mail.

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Brian Hurt 2007-11-26 16:08:54 Re: Big copy slowdown
Previous Message roody senecal 2007-11-26 02:23:08 Update field value