Home » Developer & Programmer » Forms » Updating data Without Update command (Oracle Forms)
icon5.gif  Updating data Without Update command [message #669120] Tue, 03 April 2018 10:59 Go to next message
Ani747
Messages: 11
Registered: March 2018
Junior Member
Hi All,

Need some help here.

I am using a DB Block and Control block in my form and want to Insert/Update records in the DB block.

I am able to insert new record using commit command, but how do I update an existing record?

I don't want to use the inbuilt toolbar.

Please suggest
Re: Updating data Without Update command [message #669121 is a reply to message #669120] Tue, 03 April 2018 14:10 Go to previous messageGo to next message
Littlefoot
Messages: 21806
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
- execute query
- update values you want
- commit

I've noticed that you keep saying that you "don't want to use toolbar"; why not? It isn't evil; actually, it is rather useful. I'd suggest you to accept the fact that you're using Oracle Forms and start behaving accordingly.
Re: Updating data Without Update command [message #669122 is a reply to message #669121] Tue, 03 April 2018 20:07 Go to previous messageGo to next message
Ani747
Messages: 11
Registered: March 2018
Junior Member
Thanks for your reply Sir,
However, when I am using the Execute_query command, I am getting the "Do you want to save Changes you have made?" pop-up. Is there any way I can change the content of this pop-up? Or better still, ensure it does not come up at all.

Apologies for creating the impression that I don't want to use the toolbar, its just that I want to explore alternate options for doing the same. Just in case, I work on a project where in the in-built tool-bar has to be replaced by another toolbar.

Please guide here
Re: Updating data Without Update command [message #669123 is a reply to message #669122] Wed, 04 April 2018 00:14 Go to previous messageGo to next message
Littlefoot
Messages: 21806
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
The message you got means that there are some changes in the data block (for example, you entered a value manually, or set it via a trigger), so Forms warns you that those changes will be lost unless you save them. You have to decide whether you do (or do not) want to do that.

As of changing that message: it is an alert, so you'd have to substitute it with your own. I've never done that, but - if you want to try it, here's an article which shows you how to do it.

Toolbar: so, you'll remove the built-in one and replace it with your own? OK. What improvement do you expect from doing it?
Re: Updating data Without Update command [message #669131 is a reply to message #669123] Wed, 04 April 2018 03:34 Go to previous messageGo to next message
cookiemonster
Messages: 13917
Registered: September 2008
Location: Rainy Manchester
Senior Member
I wouldn't try changing the message.
If you're getting the message without typing anything into fields in the block then go find the trigger code you wrote that sets values in the block and remove it.
Re: Updating data Without Update command [message #669173 is a reply to message #669123] Fri, 06 April 2018 20:55 Go to previous messageGo to next message
Ani747
Messages: 11
Registered: March 2018
Junior Member
Thanks for the Article Sir,

I will use it and let you know.

I am not expecting any improvements Sir, i am just checking if its possible to insert data without using insert command and the inbuilt toolbar.

Regards,
Ani
Re: Updating data Without Update command [message #669174 is a reply to message #669131] Fri, 06 April 2018 20:59 Go to previous message
Ani747
Messages: 11
Registered: March 2018
Junior Member
Sir,

I am not getting it without typing anything.

I get the pop-up only when I try and update the record. Anyways, I will try and use the link given by Littlefoot and check if it works

Regards,
Ani
Previous Topic: ora-40735
Next Topic: Oracle Form in Client System
Goto Forum:
  


Current Time: Thu Mar 28 16:53:24 CDT 2024