Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Queries / May 2005

Tip: Looking for answers? Try searching our database.

Changing 0 to 1 in a table

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
ChuckW - 05 May 2005 21:45 GMT
Hi,

I want to run a query that will automatically change the zeros in a field to
a 1. I know how to do this manually by replacing a 0 with a 1 but I want to
have it in a query.  

Thanks
Signature

Chuck W

Rick B - 05 May 2005 21:58 GMT
Just build an unpdate query.  Pull all the records with a "0" unsing your
criteria and change it to "1" using the Update To field.

Note:  Access uses -1 to represent a "true" value.  If you are working with
a true/false or yes/no field, you need to do a little more research before
you proceed.

Signature

Rick B

> Hi,
>
[quoted text clipped - 3 lines]
>
> Thanks
Ofer - 05 May 2005 22:08 GMT
Try that

UPDATE MyTable SET MyFieldName= 1
WHERE MyFieldName=0

> Hi,
>
[quoted text clipped - 3 lines]
>
> Thanks
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.