Solved

selectivly changing data

Posted on 2004-03-28
1
223 Views
Last Modified: 2006-11-17
Hello,

       I have an sql database that has the has incorrect data in it,  I need to go thru and replace specific data values with correct information,  I've been doing this manually so far but its just taking forever.

Can someone help with a bit of sql code to do the following ?

here is the query that I've been using to get the data that I've been manually changing...
select CPU_UTIL from PERFMON where CPU_UTIL > '100'

this gives me all the data that is incorrect (CPU_UTIL is a percentage value but some systems are screwy and giving a 324653 value I need to change everything that is above 100   to 100.


Thanks for your help!
0
Comment
Question by:PaulGibson
1 Comment
 
LVL 1

Accepted Solution

by:
raje10410 earned 125 total points
ID: 10701935
Hi Paul,

Try this:

UPDATE PERFMON
SET CPU_UTIL = 100
WHERE CPU_UTIL > 100

Cheers,

Rajesh
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I wrote this interesting script that really help me find jobs or procedures when working in a huge environment. I could I have written it as a Procedure but then I would have to have it on each machine or have a link to a server-related search that …
Nowadays, some of developer are too much worried about data. Who is using data, who is updating it etc. etc. Because, data is more costlier in term of money and information. So security of data is focusing concern in days. Lets' understand the Au…
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
Using examples as well as descriptions, and references to Books Online, show the documentation available for datatypes, explain the available data types and show how data can be passed into and out of variables.

939 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

6 Experts available now in Live!

Get 1:1 Help Now