ColdFusion Tutorial

Update records in database

 This will update data in the database.

The first query adds the record 'Tom Jackson' to the database.

<cfset First_Name = "Tom">

<cfset Last_Name = "Jackson">

<cfquery name="add_person" datasource="persondb" username="" password="">

INSERT INTO person

(Person_First_Name,

Person_Last_Name)

VALUES

('#First_Name#',

'#Last_Name#')

</cfquery>

This query look for all records where 'Person_First_Name' is Tom, and update those records to 'Person_First_Name' is 'Jim' using the WHERE statement.

<cfquery name="add_person" datasource="persondb" username="" password="">

UPDATE person

SET Person_First_Name = 'Jim'

WHERE

Person_First_Name = 'Tom'

</cfquery>

ColdFusion Tutorial test

Update records in database

No test is available or implemented for this ColdFusion Tutorial.

No User Comments.

No User Comments, be the first one to write your comments?

Add your comments

Your Name*:
Your Email:
Site URL:
Site Name:
Comemt Title*:
Your Comment*:
Key Phrase*:
Xd5
Your IP Address: 38.103.63.62
 

ScandicWeb is own by Scandic Systems LTD [UK] Company No. 5984000. All other trademarks and copyrights are the property of their respective holders.

[Home [Site Map [Privacy Statement [Site Feedback] [About ScandicWeb]


[ColdFusion [Flash [Search Engine Optimization [Graphics [Cascading Style Sheets (CSS) [JavaScript (JS) [Software]

Partner sites: ScandicSoft


Server time: 19. November 2008 Wednesday