Using Aliases in same query

Alias is very helpful to shorten long query in SQL.

To use Alias in the same query you can use the following method:



SELECT  A,B,C*50 from (select A,B,(A+B) as C from table).

note that you can choose  any column from inner-query to display it in outer-query.

but you cannot display a column in outer-query which is not exist in inner-query.



You can try this example using SCOTT schema:

select  SAL,COMM,COMM_RATE *100 from (
select SAL,COMM,(COMM/SAL) as COMM_RATE from emp)


Remove the 'Do you want to save changes?' Messages in Forms

here is it ...

1. Modify the CLEAR_ALL_MASTER_DETAILS procedure body. Change the existing CLEAR_BLOCK(ASK_COMMIT) to CLEAR_BLOCK(DO_COMMIT).

2. Specifying NO_COMMIT or NO_VALIDATE with the CLEAR_BLOCK built-in causes
Oracle Forms to flush the current block without performing a commit or prompting the operator.
ex:CLEAR_BLOCK(NO_COMMIT,NO_VALIDATE);

Thanks to Dipankar...

Avoid FRM-40401 message

Use Standard.commit  instead of commit to prevent Oracle message :



Source :OraFAQ