PL/SQL :: Only Display A Column Value One Time For A Record / Not A Static Value

Jan 7, 2013

I am trying to only display a column value one time for a record, not a static value. The value changes and there can be many values. I do not think grouping will work since the Date value is dynamic. I am using Oracle for Toad 10.5. There are 4 records with this test data.

select Date, Person, Language, Country
from TableATableA
Date            Person  Language   Country
01/25/2013       James   English
12/20/2012       James   English
US

[code]....

View 3 Replies


ADVERTISEMENT

PL/SQL :: How To Display Pseudo Static Index Using Select Statement

Jul 20, 2012

I have to display a 24 hours time as an index. (00:00 - 23:00) That is easy, if the data exists.

But, if the data is not regularly exists on specific hour (the time/hours is not regular, i.e: 00:00, 01:00, 05:00, 08:00, 10:00, 11:00, 23:00), then it is OK for a TABLE, but not for a CHART.

Here is the story:

I wrote an SQL statement that can "choose" what to display respectively to the the available time. The result will be displayed on the chart: Days or Time is used for X-Axis, and the respective Value on the Y-Axis.

Example:

+ if the data consists of "days" (i.e: the last 5 days from now, 16/07/2012, 17/07/2012, 18/07/2012, 19/07/2012, 20/07/2012), then the chart will show those dates on the X-Axis.

+ if the data consists of "hours" (i.e: 1 single day, from 00:00 hour - 23:00), then the chart shows hours on the X-Axis.

If the 'hours' are not regular, means: there is no data on specific hours, the query result is also not regular, means: the X-Axis-value 'jumps' irregularly.

Question:

Is it possible to query our own static value?

for example:

select 'hello' from dual --> result: "hello", 1 column, 1 row

But how to display this in multiple rows, i.e.:

Time
*****
0
1
2
3
4
5
...
...
23

Note: the X-Axis on the chart template can be only customized for 1 single mode, example: "Days", but of course it is not going to show up properly if the query result are in "Hours". It means: I have to find the workaround on the SQL Query.

DB: ORA 11

View 9 Replies View Related

Forms :: Choose Lov In First Record That Won't Be Display In Second Record Lov

Sep 10, 2012

I have one multi record block in that i have one LOV..If i choose lov in first record that won't be display in second record lov...

View 4 Replies View Related

PL/SQL :: Static Table Creation In Oracle - Difference Between Static And Dynamic Table

Dec 11, 2012

Static Tables Creation In oracle & Diff Between Static table ,Dynamic table

View 2 Replies View Related

SQL & PL/SQL :: Display Some Value When There Is No Record In Table

Jul 8, 2010

I have a following table,

create table test ( col1 date,col2 number);

Data:

col1 Col2
----------
NULL NULL

select * from test where col2=123 will give me null because It doesnt have any values, But can we display some harcoded value when I do not have anything ?

View 9 Replies View Related

Forms :: Display Next Record?

Apr 22, 2010

I have a form in which the fields are not database items i want to display the next record, i know i can use the next_record for the same but it does not work since it is not the database item, is there any way when the item is not the database item and i can see the next record. I use the cursor for loop but since it fecthes all the records in one go it cannot display one record at the time in the form..

View 3 Replies View Related

SQL & PL/SQL :: How To Display The Duplicate Record In Table

Jun 30, 2011

how to display the dupicate record in table

View 1 Replies View Related

Forms :: How To Display Current Record

Mar 12, 2013

I have problem about displaying current records with same table(tbl_pawnitem). I have 2 transactions which are the pawned transaction and for sale transaction. and both transactions save into tbl_pawnitem table..i want to display only in my list the for sale transaction without deleting the records of pawned transaction. what condition i will use?

View 5 Replies View Related

How To Display Time In Minutes

Oct 15, 2012

I have two columns which I need to add together then devide by 60 in order to display that time in minutes. the problem I am facing is that at times I get numbers above 60 and my client doesn't want to see numbers above 60.

i.e (col1 + col 2)/60 = 34.87

what I need to do is make sure that when the number reaches 60 it moves on to 35.

View 2 Replies View Related

Display Date And Time

Sep 28, 2011

I had a database at microsoft access but i had move it to the oracle database.

When i check the datatype at oracle, date column is at DATE datatype. but it only display date. like in oracle. it display:

 oracle_date.PNG ( 74.61K )
Number of downloads: 4

But when i link it to microsft access. like i will control the oracle from access. the result is at below:

 access_date.PNG ( 136.11K )
Number of downloads: 3

So, my problem is how to display the date and time fully in oracle?

View 1 Replies View Related

Forms :: Display Record On Non Database Item?

Sep 17, 2012

I want to display my query select * from Clinical_Chart_CCHPI in non database item which is 1000 Char. I want to display that query when my forms execute.below is the test case.

Create table Clinical_Chart (Chart_Number Char(12),MR_NO Char(13));
Create table Clinical_Chart_CCHPI (Chart_Number Char(12),serial_number number,Date Date, Remarks Varchar(1000));
--------------------------
insert into Clinical_Chart(1,1);
insert into Clinical_Chart_CCHPI (1,1,01-JAN-

[code]...

I have taken one non database block and my item Test which is non-database too. But no result is coming i have attached JPEG file too.

View 4 Replies View Related

Forms :: Display Record Counts / Unique Names

Sep 25, 2012

I have a table

TAB1 with data
no name
1 abc
2 abc
3 xyz
4 xyz
5 cvb

now I would like to create a form with name counts as

abc 2
xyz 2
cvb 1

I would like to create a datablock to display all the unique names, not sure where I should be writing the query to display unique names. I would like to create a textitem box to display the counts when the form is compiled, but not sure which trigger to use to write the query.

View 2 Replies View Related

SQL & PL/SQL :: How To Display The Status And Record Count In Separate Rows

Mar 6, 2013

My problem is i need to display the status and the record count in separate rows.How can i do it

Example

SELECT 'A' STAT, COUNT(A) CNT,'B' STAT, COUNT(B) CNT,'C' STAT, COUNT(C) CNT
FROM TAB1;

OUTPUT SHUD BE LIKE

STAT COUNT
A A_cnt
B B_CNT
C C_CNT

View 13 Replies View Related

Application Express :: Message Display Before Submit To Record

Nov 5, 2012

I have created two page process with two buttons "APPROVE" AND "CANCEL" button. first page process running approve invoice procedure on approve button and second page process running cancel invoice procedure on cancel button. i want to display massage before approve invoice and cancel invoice (DO you want to approve invoice) on approve button and (Do you want to cancel invoice on ) cancel button.

Working with apex4.1.

View 4 Replies View Related

Forms :: Display Alert When Click On Insert Record In Tool Bar?

Jun 26, 2013

I want to display an alert when we click on Insert Record in tool bar. I put allow update->yes and insert->no.

but when i click on the insert record in tool bar it showing message only.

Instead of message I need an alert using triggers. I added the image also.

View 1 Replies View Related

Forms :: Display All Records One By One As User Click On Next Record Button

Jul 13, 2010

I have created one tab canvased form

On first tab I am taking input (search criteria)
on that input i am trying to display all records one by one as user click on next record button....

for that i used when-tab-page-change trigger for first record display and it display correctly.but for further record what should i need to write on next_record command button so all record i can see one by one.

View 1 Replies View Related

Forms :: Unable To Display A Message When Record Status Is Changed?

Jun 2, 2010

I have one requirement.i.e I want to display 'Do you want to save the changes you have made?[YES/NO]' message when record status is changed.In my form if i enter some value to the actual qty(db item) and press 'x' button it does't prompting 'Do you want to save the changes you have made?' message.

For displaying this message i have written following code in the APP_CUSTOM body:

IF (wnd = 'XXMZ_MRS_DET')
THEN
lv_wnd_stat := get_window_property('XXMZ_SUMMARY',VISIBLE);
if lv_wnd_stat = 'TRUE' THEN
IF :SYSTEM.form_status = 'CHANGED' THEN
CLEAR_BLOCK(ASK_COMMIT);
ELSE

[code]....

if i write above code in the app_custom body it's prompting the above message.But if i click 'YES' it does't save the records?

How can i save the records when i click 'yes'?

View 3 Replies View Related

SQL & PL/SQL :: Display Time Format In Oracle By Create View

Nov 16, 2011

I am not able to find any information regarding inserting data with timestamp format without putting the date.

This is what i want to do:

ALTER SESSION SET NLS_TIMESTAMP_TZ_FORMAT='DD-MON-RR HH24:MI TZR';

I create the column data type as timestamp with time zone. This is value i have inserted:

Insert Into TEST Values('05-OCT-2013 01:00 +08:00','05-OCT-2013 23:00 +08:00','SCIENCE);

And now i wish to display it in 'HH24:MI TZR' only after i deduct both of the time. This is the view i have created:

Create View TESTRECRDS As Select (STARTTIME- ENDTIME)*24 As DURATION, Science;

But when i select it display as weird timing because it would default in 'DD-MON-RR HH24:MI TZR' format.

BUT IF i create the view and display as 'HH24:MI TZR', it would gives me error:

Create View TESTRECRDS As Select To_Char(STARTTIME- ENDTIME, 'HH24:MI TZR')*24 As DURATION, Science;

Error would be invalid number. How can i display only 'HH24:MI TZR' after subtracting?

View 3 Replies View Related

Forms :: Display Country Name And Region At Time Of Navigation

Feb 10, 2011

I have developed customer entry form, its working fine. I have 2 display items on form. One is country name & other is region, these are fetched based on country id LOV.

Now I want to display country name & region at time of navigation. I have written following code on WHEN_NEW_RECORD_INSTANCE of block.

******
DECLARE
CCNTRY_ID VARCHAR2(2);
CCNTRY_NAM VARCHAR2(25);
CREGION VARCHAR2(11);
begin
select cntry_nam,region into ccntry_nam,cregion from cntry where cntry_id=ccntry_id;

exception
when no_data_found then
message('NO DATA FOUND');
end;
**********

I always get message not data found on navigation. Problem is only with the display item other, values of database columns are being shown.

View 3 Replies View Related

Application Express :: Display Custom Message For Report When Record Count Returned

Nov 8, 2012

Our application has a homepage that displays results of several SQL statements that are defined as reports. One report in particular should only display a custom message when Count of Invoices having a particular status > 0, and not the actual invoice count itself.

I have gotten the layout to not display the count but I need to be able to display a custom message that says "Problem Invoices exist. Please see Invoices Report for more information." I've looked over the Report Attributes definition page but I cannot find how to display this custom message.

View 2 Replies View Related

Forms :: Changing Record Group For LOV At Run Time

Dec 2, 2008

I have 2 record groups names RG1,RG2 , I attached RG1 record group to LOV1 at design time,I want to change the record group RG1 to RG2 for LOV1 at run time.

View 11 Replies View Related

SQL & PL/SQL :: Find The Time Of A Record Inserted Into Table

Oct 20, 2010

I have a table which is getting populated from a source. I dont have a time-stamp column in the table. Is there anyway to find the time when a record was inserted into the table?

View 3 Replies View Related

Forms :: New Record With Same ID Inserted Every Time - Duplication

Mar 4, 2013

I have a form that used to enter new employees , if the employee ID already registerd then the user can ONLY update the information and NOT adding the same ID with new info.

int the ID item in when-validat-item trigger I put this code

begin

IF :SOURCE_CODE IS NULL THEN MESSAGE('PLEASE ENTER SOURCE CODE');
ELSE
declare --chg#13-3169 nada

[Code].....

in the save button the code is : commit;

The problem Is : a new record with same ID is inserted every time !! Duplication is happining

View 6 Replies View Related

Forms :: Create Lov And Record Group Dynamically At Run Time?

Apr 10, 2013

i want to create a lov and record group dynamically at run time. i have the code in when-form-instance..

Declare
v_lov lov;
rg_id recordgroup;
gc_id groupcolumn;

[Code]....

whether i create first a lov and record group at design time or not? if i create a lov and have the recordgroup column then what is the benefit of dynamically lov.?

View 5 Replies View Related

Forms :: Lock Record When Two Users Updating Existing One At Same Time

Aug 22, 2013

I am using Forms 6i and developed a Master Detail Oracle Form for Oracle EBS 11i application.

I was asked to write a pl/sql program so that.. When a user updating an existing record at the same time another user query the same record and try to update the same time, the record should be locked and a message should popup saying the record is being updated by another user.

View 2 Replies View Related

Forms :: Insert / Update And Delete Single Record At A Time?

Aug 10, 2005

I have multirecord block and I want to disable Inserting/Updating/Deleting more then one record at a time.

View 32 Replies View Related

SQL & PL/SQL :: Pipe Line Function Taking Time To Return Table Record

Mar 15, 2011

I want to use a function in join clause. so i go for pipelined function(using for loop to get record & 1 more loop to fetch in table type variable). i achieved what i required. but problem is it takes much time to fetch data. is there any other approach which returns table records without pipelined function.

View 2 Replies View Related

Oracle 11g - Record Query And Time To Fetch Results For A Specific User ID

Jul 22, 2013

I have an application connected to Oracle 11g that sends its own querys to the db based on what the user is clickng on. The applicaiton is connected via one user id and I was wondering, is there a way that I can capture the tiem each query starts, the sql itself, and the amount of time it took to fetch the data?

View 7 Replies View Related

PL/SQL :: Add A Column To Display?

Mar 21, 2013

I have a procedure in this i want add a column to display my procedure is

set serveroutput on;
create or replace PROCEDURE IdentifySparesInDSIGNALTables
AS
V_SQL VARCHAR2(1024);
cnt1 number;

[code]...

i wnat to add dlstation in this procedure to display output...

View 1 Replies View Related

How To Display Row Value Of Each Class As Column Value

May 27, 2008

How to display row value of each class as a column value

IDNAMECLASSHOURSSCHOOLNAME
1AllenMaths12school1
2SamMaths12school1
4PamMaths10school1
3SamComp10school1
9SmithComp15school1
7SmithPhy20school1
5PamPhy12school1

[code]....

I wanted output like below for School1

NamemathsCompPhyAccountsBusiness
Allen120000
Sam1210000
Pam10012150
Smith01520120
Adams000030

I wanted output like below for School2

NameCompAccountsBusiness
Anthony2000
Chris102020

I wanted output like below for School3

NamemathsAccounts
Angelo2015
Robert1515

how to write a single query, Also i may add /delete school/class anytime. Query should support mesans everything dynamically should get the data.Even stored procedure will work for me.

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved