Digital Workshop

Welcome to the Digital Workshop Message Boards
It is currently December 22nd, 2024, 6:49 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Databases - Part 4: Modifying Existing Records in a Database
PostPosted: October 25th, 2004, 3:43 pm 
Offline

Joined: October 25th, 2004, 12:27 pm
Posts: 526
Location: Digital Workshop
Q: One of the contacts in my database has recently changed jobs, so I need to modify the OCCUPATION for this person's record. How can I modify an existing record in my database?

A: To do this, you first need to search for the relevant entry in the database, so that the record which needs to be modified is the current record. You can then use the Update Current Record action to modify the existing values. The following procedure should assist you in this:

1) Open the tutorial publication into Opus Pro
2) Add a text input box to the page
3) In the properties of the text input box, select the Text Input tab
4) Select the NAME variable from the drop-down list of variables
5) Click Apply and OK
6) Now repeat steps 2-5 to create two more text input boxes, assigning the first to the existing AGE variable and the second to the existing OCCUPATION variable
7) Add a button object to the page
8) In the actions for the button, select the Database group of actions
9) Double-click on the Update Current Record action
10) Open the drop-down menu for the DSN field and select the DSN you created in Part 1
11) Open the drop-down menu for the Table field and select 'Table1' from the list provided
12) You should now see all of the fields from the database appear in the grid below the DSN and Table fields
13) Click on the NAME field to highlight it
14) Enable the Variable radio button
15) Now open the drop-down menu for the Variable field and select the NAME variable
16) Click on the AGE field to highlight it
17) Enable the Variable radio button
18) Now open the drop-down menu for the Variable field and select the AGE variable
19) Click on the OCCUPATION field to highlight it
20) Enable the Variable radio button
OCCUPATION variable
22) Click Apply and OK to confirm the changes
23) Preview the publication
24) Type a search string into the search input field and click the button to display the matching record
25) You should notice that the matching record also appears in the three text input boxes we have just added
26) Click inside the text input box which is displaying the OCCUPATION variable and edit its contents to the new occupation of your contact
27) Click the button to update the current record

To confirm that the record has been updated, simply exit out of the publication, then go back into preview mode and search for the original surname - no records will be returned. However, if you search for the new surname, a matching record should be displayed with the original NAME and AGE information.


For this message Robin Garrett has been thanked by : mackavi


Top
 Profile Visit website  
 
 Post subject: cannot update
PostPosted: November 20th, 2008, 6:05 pm 
Offline

Joined: February 25th, 2005, 7:23 pm
Posts: 12
I might be having a thick moment but I'm creating a database from scratch from the tutorials. I followed everything. I have created pages similar to your View/Add/Edit database ones.

All is working fine, adding, searching, viewing, except the button for the update record. When I go to select Query from the Actions after selecting Update Current Record there is nothing in the dropdown list. It's empty (see screenshot)

I've loaded in your database.zip to check out anything I might have missed but it looks identical. I can see the Query in the dropdown list on your database file but not in mine.

Maybe I'm missing something.

Any help appreciated.


Attachments:
Untitled.jpg
Untitled.jpg [ 93.73 KiB | Viewed 18827 times ]


For this message vrealdeal has been thanked by : mackavi
Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 15 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group