SunQuest
           MySQL Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsDatabasesMySQL Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
1200+ fellow developers rate and compare features of the top IDEs, like Visual Studio, Eclipse, RAD, Delphi and others, across 13 categories. Enjoy this FREE Download of the IDE User Satisfaction Study by Evans Data Corporation. Download Now!
  #1  
Old June 21st, 2000, 04:26 AM
gonja gonja is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: May 2000
Posts: 13 gonja User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Hi everybody...

I need to modify record.pls tell me how....

Reply With Quote
  #2  
Old June 21st, 2000, 06:04 AM
alexgreg's Avatar
alexgreg alexgreg is offline
Full Access
Dev Shed Regular (2000 - 2499 posts)
 
Join Date: Jun 2000
Location: London, UK
Posts: 2,019 alexgreg User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 3 sec
Reputation Power: 11
Please be more specific!

However you can modify a record like this using SQL:

UPDATE (tablename) SET (column_name) = '(Original_Name)' WHERE (column_name) = '(New_Name)';

The pieces in brackets you'll have to replace with something of your own. This will modify ALL the records whose names are Original_Name and change the name to New_Name

-------------------------
Alex
(http://www.alex-greg.co.uk)

Reply With Quote
  #3  
Old June 21st, 2000, 08:40 AM
rod k rod k is offline
Apprentice Deity
Dev Shed Loyal (3000 - 3499 posts)
 
Join Date: Jul 1999
Location: Niagara Falls (On the wrong side of the gorge)
Posts: 3,237 rod k User rank is Private First Class (20 - 50 Reputation Level)rod k User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 4 m 8 sec
Reputation Power: 13
Send a message via AIM to rod k
Actually, Alex, you got that backwards. The way you have written the query it will change column_name to original_name where column_name = new_name

Reply With Quote
  #4  
Old June 21st, 2000, 10:26 AM
releasedj releasedj is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jun 2000
Location: London
Posts: 46 releasedj User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 9
Let's say that you have a table called "table1", which has a column called "column1".

In this column you want to update all rows containing the value "Value1" in "column1" to contain the value "Value2"

UPDATE table1 SET column1='Value2' WHERE column1='Value1';

Kelvin

[This message has been edited by releasedj (edited June 21, 2000).]

Reply With Quote
  #5  
Old June 22nd, 2000, 11:37 PM
gonja gonja is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: May 2000
Posts: 13 gonja User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
how if the value we going to change is a string...

Reply With Quote
Reply

Viewing: Dev Shed ForumsDatabasesMySQL Help > How to modify a record


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway