Home » Developer & Programmer » Forms » [FORMS] HOW MAKE UPDATE VIEW in FORMS??
icon5.gif  [FORMS] HOW MAKE UPDATE VIEW in FORMS?? [message #351111] Mon, 29 September 2008 05:42 Go to next message
dudrms81
Messages: 1
Registered: September 2008
Location: South KOREA Rep.
Junior Member

I make a simple view
--------------------------------------
create or replace view as IS_CS01_V
Select .....
--------------------------------------
and make datablock -> IS_CS01_V
and datablock is displayed...

but i can`t insert text in recoard.
i set block property -> databse

insert allowed = yes,
update allowed = yes,
locking mode = immediate,
delete allowed = yes,
key mode = automatic...

and item property is same setting...
and item type : Text item.

but when i run form, i can`t insert item (in IS_CS01_V)
i want to only insert. no query!

but after query [Ctrl + F4], all items in BLOCK(IS_CS01_V) is changed display item.. so i can`t use update view..

what is the problem???
Help me !!


Re: [FORMS] HOW MAKE UPDATE VIEW in FORMS?? [message #351113 is a reply to message #351111] Mon, 29 September 2008 06:02 Go to previous messageGo to next message
rajy_salim
Messages: 204
Registered: January 2008
Location: Beirut - Lebanon
Senior Member
You cannot insert in a view since it's not a physical object. A view, as its name means, is to view data, you cannot neither insert nor update.
To insert the data you want, base your datablock on a table where you can use all the DML statements.

Rajy
Re: [FORMS] HOW MAKE UPDATE VIEW in FORMS?? [message #351118 is a reply to message #351113] Mon, 29 September 2008 06:23 Go to previous messageGo to next message
Littlefoot
Messages: 21823
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
I probably don't know all possible ways to do that, but - you could perform what you'd like to do by use of (database, not Forms) INSTEAD OF trigger(s).

A form data block may be based on a view, all items would be "text items"; check use of the ON-LOCK form trigger, as well as previously mentioned INSTEAD OF database triggers.
Re: [FORMS] HOW MAKE UPDATE VIEW in FORMS?? [message #351202 is a reply to message #351111] Mon, 29 September 2008 19:00 Go to previous message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
You can only insert into a view under certain circumstances.

Search this forum for 'all_updatable_columns' and 'user_updatable_columns'.

David
Previous Topic: Front End Forms6i, Back End Others
Next Topic: Casting single letter as char(1)
Goto Forum:
  


Current Time: Sun Feb 09 07:52:03 CST 2025