semicolon " : " in oracle forms [message #676179] |
Sun, 19 May 2019 08:43 |
|
spirit3d
Messages: 4 Registered: May 2019
|
Junior Member |
|
|
Dear all,
I am new to oracle and would be grateful if you could advice me.
As far as i know
If i have a form with block name "swimming_block" and field name like "swim_id", "swim_name" etc ...
In Order to insert data into database from this form, i should say
INSERT INTO SWIMMING
VALUES (:SWIMING_BLOCK.SWIM_ID, :SWIMMING_BLOCK.SWIM_NAME)
I would like to know:
(1) where do we need to use semicolon " : " in oracle forms (Pl/SQl editor)
(2) where not to use it
Many thanks
Tairon
|
|
|
Re: semicolon " : " in oracle forms [message #676180 is a reply to message #676179] |
Sun, 19 May 2019 16:04 |
|
Littlefoot
Messages: 21823 Registered: June 2005 Location: Croatia, Europe
|
Senior Member Account Moderator |
|
|
First, terminology.
- ":" is "colon"
- ";" is "semi-colon"
INSERT you wrote is correct. Though, I'd suggest you to name all columns you're inserting into, e.g.
insert into swimming (swim_id, swim_name)
values (:swimming_block.swim_id, :swimming_block.swim_name);
Use a colon when referencing form items. Don't use it in built-ins, such as
set_item_property('swimming_block.swim_name', enabled, property_false);
Furthermore, a colon is used when referencing system variables, such as
:system.message_level := 5;
as well as global variables:global.form_name := 'my_form'; or parameters:parameter.trg_rec := :system.trigger_record;
There are probably some more examples I didn't mention. If in doubt, open Forms Online Help system, search for term you're interested in and see what it says. If you can't make it work, come here & ask a question; someone will assist.
|
|
|
|
|