• Skip to main content

Tech Honey

The #1 Website for Oracle PL/SQL, OA Framework and HTML

  • Home
  • HTML
    • Tags in HTML
    • HTML Attributes
  • OA Framework
    • Item in OAF
    • Regions in OAF
    • General OAF Topics
  • Oracle
    • statement
    • function
    • clause
    • plsql
    • sql

Message Radio Group In OAF

October 27, 2012 by techhoneyadmin

Oracle Apps Framework creates the messageRadioGroup item style as a combination of the radioGroup and inlineMessage controls. You can have many radio buttons in the messageRadioGroup but only one of the radio buttons can be selected at a time. This is used wherever you want user to select only one value from many choices available. Suppose in your OAF page you want the user to select a payment method out of the three available options namely Credit Card, Pay Pal or Cash on Delivery (COD), then either you can use messageChoice bean or you can use the messageRadioGroup to achieve the same.

Corresponding web bean: OAMessageRadioGroupBean

Import Path: import oracle.apps.fnd.framework.webui.beans.message.OAMessageRadioGroupBean;

Filed Under: Items Tagged With: Message Radio Group in OA Framework, Message Radio Group in OAF, OA Framework Message Radio Group, OAF Message Radio Group, OAMessageRadioGroupBean, What is Message Radio Group in OAF

Message Rich Text Editor in OAF

October 27, 2012 by techhoneyadmin

The messageRichTextEditor item style in Oracle Apps Framework page provides rich text editing capability within the OAF page.

Using this region the users can format the text same as MS Word or other word processing tools. It has the capacity to hold the text in bold, italics, underlined, colored or any other format. A user can even add bullets, numbers etc to his text. Also, the user can highlight the text or write the text in different colors, is also gives the user the functionality to copy the text from any word processing tools and paste the same.

The only condition that Oracle Application Framework puts for the messageRichTextEditor is that it can be placed within any region except search regions or tables. Also, the browser should support IFRAMES for the rich text editor to work.

Corresponding web bean: OAMessageRichTextEditorBean

Import Path: import oracle.apps.fnd.framework.webui.beans.message.OAMessageRichTextEditorBean;

Filed Under: Items Tagged With: Message Rich Text Editor in OA Framework, Message Rich Text Editor in OAF, OA Framework Message Rich Text Editor, OAF Message Rich Text Editor, OAMessageRichTextEditorBean, What is Message Rich Text Editor in OAF

VIEWS in Oracle SQL – PLSQL

October 26, 2012 by techhoneyadmin

A VIEW in Oracle SQL / PLSQL is like a virtual table, there is no physical existence of a view. A VIEW can be created using a SELECT statement by forming a valid SQL query.

Syntax for creation of a VIEW in Oracle SQL / PLSQL is :

CREATE VIEW view_name
AS
SELECT column(s)
FROM table_name(s)
WHERE condition(s);

Let’s take an example for understanding
Suppose have a table named ‘employee’ in the database as shown below.

Employee_Id Employee_Name Salary Department Commission
101 Emp A 10000 Sales 10
102 Emp B 20000 IT 20
103 Emp C 28000 IT 20
104 Emp D 30000 Support
105 Emp E 32000 Sales 10

Scenario 1:

Creating a VIEW

Suppose we want to create a view so that we can see the data only for those employees who are having ‘salary’ > 25000, we can achieve the same as:

CREATE VIEW employee_view
AS
SELECT *
FROM employee
WHERE salary > 25000;

The above query will create a view named as ‘employee_view’. If we query the ‘employee_view’ as:

SELECT *
FROM employee_view;

We will get the following result:

Employee_Id Employee_Name Salary Department Commission
103 Emp C 28000 IT 20
104 Emp D 30000 Support
105 Emp E 32000 Sales 10

Here we can understand that we have created a view named ‘employee_view’ based on ‘employee’ table which shows us the records of employees having ‘salary’ > 25000 using CREATE VIEW and SELECT statement.


Scenario 2:

Updating an already existing view:

Syntax for updating a view is:

CREATE OR REPLACE VIEW view_name
AS
SELECT column(s)
FROM table(s)
WHERE condition(s);

Suppose we want to update the view named ‘employee_view’ created in the previous scenario so that the ‘employee_view’ can display the records of employees having ‘salary’ < 30000.

The same can be achieved as:

CREATE OR REPLACE VIEW employee_view
AS
SELECT *
FROM employee
WHERE salary < 30000;

The above statement will alter or change the definition of ‘employee_view’ so that it will show record of employees from ‘employee’ table having ‘salary’ < 30000.

If we query the ‘employee_view’ as:

SELECT *
FROM employee_view;

We will get the following result:

Employee_Id Employee_Name Salary Department Commission
101 Emp A 10000 Sales 10
102 Emp B 20000 IT 20
103 Emp C 28000 IT 20

Here we can see that the view definition for ‘employee_view’ has been updated and the view is now displaying the records of employees having salary < 30000.


Scenario 3:

Deleting or dropping a view

The syntax for deleting or dropping view is

DROP VIEW view_name;

E.g.

DROP VIEW employee_view;

The above statement will delete or drop the definition of ‘employee_view’ from the database.


Important Points about VIEWS in SQL / PLSQL:

  1. The data in the VIEWS can be updated if the user has the privileges for doing the same.
  2. If the data in the VIEW is updated, it updates the data in the tables on which the VIEW  is based upon.
  3. If the table (on which the view is based) is dropped or deleted from the database the definition if the view still remains i.e. the VIEW continues to exist, but if we query the view we will get a message that VIEW has errors.
  4. If we create the base table again the VIEW become alright as it was before the deletion if the base table.

Filed Under: sql Tagged With: create views in oracle plsql, create views in oracle sql, how to create views in oracle database query, how to create views in oracle plsql, how to create views in oracle sql, syntax and example of create views in oracle database query, syntax and example of create views in oracle plsql, syntax and example of create views in oracle sql, using create views in oracle database query, using create views in oracle plsql, using create views in oracle sql, VIEWSPLSQL

MINUS in Oracle SQL – PLSQL

October 26, 2012 by techhoneyadmin

A MINUS in Oracle SQL / PLSQL query is used to join or combine results from 2 or more SELECT statements, a MINUS returns only those rows which are found in the first SELECT statement but are not found in the second SELECT statement.

Also, each SELECT statement must have the same number of column(s)/field(s) with similar data-types for the MINUS to work.

Syntax for MINUS in Oracle SQL / PLSQL is:

SELECT column_name1
,column_name2
.
.
,column_nameN
FROM table_name(s)
MINUS
SELECT column_name1
,column_name2
.
.
,column_nameN
FROM table_name(s);

Suppose have a table named ‘employee’ in the database as shown below:

Employee_Id Employee_Name Salary Department Commission
101 Emp A 10000 Sales 10
102 Emp B 20000 IT 20
103 Emp C 28000 IT 20
104 Emp D 30000 Support
105 Emp E 32000 Sales 10

Also we have one more table ‘comm’ as shown below:

Emp_Id Commission_Percent
102 20
103 20
104
105 10
106 15
107 25

Let’s take an example to understand MINUS, suppose we write our SQL query using MINUS as:

SELECT employee_id
FROM employee
MINUS
SELECT emp_id
FROM comm;

The result of the above query will be:

Employee_Id
101

Here we can see that the records for ‘employee_id’ = ‘102’,’103,’104’ and ‘105’ do not appear in the result set because they are present in both (‘employee’ and ‘comm’) tables.

The record for ‘employee_id’ = ‘101’ is present in employee table but is not present in ‘comm’ table and hence is placed in the result.

Suppose we change our SQL query for MINUS as:

SELECT emp_id
FROM comm
MINUS
SELECT employee_id
FROM employee;

The result of the above query will be:

Emp_Id
106
107

Here we can see that the records for ‘employee_id’ = ‘102’,’103,’104’ and ‘105’ do not appear in the result set because they are present in both (‘employee’ and ‘comm’) tables.
The record for ‘employee_id’ = ‘101’ is present in employee table(second table) but is not present in ‘comm’ table (first table)and hence is not placed in the result.


Filed Under: sql Tagged With: how to use minus query in oracle database query, how to use minus query in oracle plsql, how to use minus query in oracle sql, minus query in oracle plsql, minus query in oracle sql, MINUSPLSQL, syntax and example of minus query in oracle database query, syntax and example of minus query in oracle plsql, syntax and example of minus query in oracle sql, using minus query in oracle database query, using minus query in oracle plsql, using minus query in oracle sql

INTERSECT in Oracle SQL – PLSQL

October 26, 2012 by techhoneyadmin

An INTERSECT in Oracle SQL / PLSQL query is used to join or combine results from 2 or more SELECT statements, an INTERSECT fetches only the common rows returned by SQL SELECT statements.
Also, each SELECT statement must have the same number of column(s)/field(s) with similar data-types for the INTERSECT to work.

Syntax for INTERSECT in Oracle SQL / PLSQL is:
SELECT column_name1
,column_name2
.
.
,column_nameN
FROM table_name(s)
INTERSECT
SELECT column_name1
,column_name2
.
.
,column_nameN
FROM table_name(s);

Suppose have a table named ‘employee’ in the database as shown below:

Employee_Id Employee_Name Salary Department Commission
101 Emp A 10000 Sales 10
102 Emp B 20000 IT 20
103 Emp C 28000 IT 20
104 Emp D 30000 Support
105 Emp E 32000 Sales 10

Also we have one more table ‘comm’ as shown below:

Emp_Id Commission_Percent
102 20
103 20
104
105 10
106 15
107 25

Let’s take an example to understand INTERSECT, suppose we write our SQL query using INTERSECT as:

SELECT employee_id
FROM employee
INTERSECT
SELECT emp_id
FROM comm;

The result of the above query will be:

Employee_Id
102
103
104
105

Here we can see that the records for employee_id = ‘102’,’103,’104’ and ‘105’ only appear in the result set because they are present in both (‘employee’ and ‘comm’) tables.


Filed Under: sql Tagged With: how to use intersect query in oracle database query, how to use intersect query in oracle plsql, how to use intersect query in oracle sql, intersect query in oracle plsql, intersect query in oracle sql, INTERSECTPLSQL, syntax and example of intersect query in oracle database query, syntax and example of intersect query in oracle plsql, syntax and example of intersect query in oracle sql, using intersect query in oracle database query, using intersect query in oracle plsql, using intersect query in oracle sql

  • « Go to Previous Page
  • Page 1
  • Interim pages omitted …
  • Page 65
  • Page 66
  • Page 67
  • Page 68
  • Page 69
  • Interim pages omitted …
  • Page 76
  • Go to Next Page »

Copyright © 2025 · Parallax Pro on Genesis Framework · WordPress · Log in