SQL & PL/SQL :: Query To Get Overall Status For Clients

Sep 11, 2010

I have a clients table called CLIENTS. One of the fields in this table is called 'status'

I need to set this status field, depending on if the transactions for this client have passed.

The transactions are in a table called TXNS and has fields
client_id, txn_id, txn_status

txn_status can be 'success' or 'failed'

I need to somehow set the overall 'status' field on CLIENTS to success or fail depending on if any transactions failed or not

So for every client I want to list the status, any query that can possible list the overall status for the client?

select client_id, MAX(status)
from txns
group by client_id

but the max(status) bit needs to get the overall status part

View 10 Replies


ADVERTISEMENT

SQL & PL/SQL :: Query On V$session - Status Column

Dec 2, 2011

If a session runs a query, the status will be inactive after completing the database call. I know this concept. But I just want to know what will be session status, if it running a procedure contains many select queries, DML quries and loop? Whether it will be active until procedure completes or it will be switching active and inactive?

View 3 Replies View Related

SQL & PL/SQL :: Select Query To Get Top Two Rows Based On Status Date

Oct 29, 2012

I want to get top two rows based on ACCT_UNIT & order by status_date, if there is only one row on acct_unit, get one row. IF more than two rows available, want to get the top two rows based on status_date.

SELECT ACTIVE_STATUS, ACCT_UNIT, DESCRIPTION, DIRECTOR, DIRECTOR2, STATUS_DATE, OBJ_ID, STATUS_FLAG, SUR_KEY
FROM STSI

View 10 Replies View Related

PL/SQL :: Query To Fetch Parent Records Only If No Child With Particular Status?

Sep 16, 2012

I need to fech parent records only when no child record with status 'N' exists. There are only two possible values for status column of child table 'Y' / 'N'.

Below are table structures and insert statements for data.

CREATE TABLE MASTER
(
COL1  NUMBER,

[Code]....

COMMIT;Query I framed is below

select * from master where exists (select null from child where child.col2 = master.col1
group by child.col2 having count(distinct col3) =1 )

Output in above case would be 3 as for 1 there's one record with status as 'N' and for 2 there's no child record. I am on 10g.

View 2 Replies View Related

Server Administration :: Check Status Of Listener And Read Only From DB Query?

Jun 13, 2010

I need to display the parameter and status of DB for listener and Read Only.

I know those value could be get from command line , but could we get the values of Listener and Read only by SQL/PlSQL? So I can get it through the query of DB.

View 8 Replies View Related

Forms :: Block Status When User Presses Enter Query Key

Feb 28, 2012

Is it possible to get the status of form or block every time? I mean if user presses Enter query key, it should display some status and if user presses execute query key then it should reflect some status. If user update any then it should reflect.

View 7 Replies View Related

Performance Tuning :: How To Find Percentage Completion Of Query In Running Status

May 2, 2012

How can we check completion status for running sql query. i.e. how much % completed

SQL> begin
2 delete from gsmcrmdw.wc_loy_txn_f_aa
3 where integration_id in
4 ( select integration_id
5 from support_olap.recover_wc_loy_txn_f_953to955
6 );
7 commit;
8 end;
9 /

View 35 Replies View Related

How To Restrict Clients Access

Jan 9, 2013

I am having one requirement that i have to restrict the access of oracle database from clients.

suppose i am having 10 users and they have all information related login like username, password, database servers details etc but then also they should not get login into my database, i have to restrict some of them like i have to provide access to 5 users only out of that 10 users.

View 3 Replies View Related

(TNSNAMES) Shared For All Oracle Clients?

Jun 19, 2012

Way to share or manage the TNSNAMES.ORA file for all oracle clients in same place?I already have a TNSNAMES.ORA configured and running in the machines (locally).The problem is that any change done( ip, port etc), imply in update all files in all the Oracle clients

View 1 Replies View Related

SQL & PL/SQL :: How To Get Distinct List Of Clients From 2 Tables

Nov 8, 2010

I have 2 tables which contain 1000's of cash and stock transactions and I need to somehow get a list of the distinct clients

select distinct client_id
from pf_cash_txns pct, pf_stock_txns pst

Quote:ORA-00918: column ambiguously defined

View 5 Replies View Related

Oracle Clients Immediately Logging Off?

Nov 4, 2011

I got a call today saying that some users were having a hard time logging on to Oracle using our in-house PowerBuilder-built application. I have Oracle 10.2.0 running on 32-bit Windows 2003. Poked around a little, looking in the dump directories, checking CPU utilization, checking OEM to see if there were any obvious performance issues or blocking issues or whatever - didn't see anything unusual. Logged in with SQL Plus with no problem. Then I checked the audit logs. All we audit is user logons and logoffs. What I was seeing is that a handful of users were showing a logon event with a logoff (action 101) 10 to 15 seconds later. One user in particular was showing this over and over again.

View 1 Replies View Related

Server Administration :: Clients Can't Connect To Database - ORA-12560

Nov 28, 2011

Since 13.00 hours, my clients can't connect to the database, and hence cannot access their application.

They get a ORA-12560 error. protocol adapter.

What I have discovered and done so far.

1. I can tnsping dbname -> OK.

2. I have rebooted both application server and databaseserver multiple times

3. I haven't touched tnsnames.ora, sqlnet.ora and listener.ora and they look to be in perfect mint condition.

4. I have full access to access the database instance via web.

5. I can connect to the database instance via sql

6. I have restarted the oracle-services: oracleDBConsoledbname, OracleOraDb20g_home1TNSListener and OracleServicedbname

7. I have rebooted the client computers, and the file server.

8. I don't see any errors in event logs, both on file server, client computer and database-server.

9. When I press down the link Listener, I get Metric Collection Error, which means I might not access it?

10. The only alert I find is that filesystem D: only has 15.62% available space.

They have been using the database for a very long time without any trouble, and suddenly boom.What do I do? How do I check things?

View 22 Replies View Related

Networking And Gateways :: Logs Or Queries To Monitor Clients IP

Oct 13, 2012

Is there any logs or query where I can monitor client's IP previously connected to the database? I have created 2 listener with 10.1.2.x and 10.1.100.x network. I would like to separate the oracle traffic to the 10.1.100.x alone. As of now both can connect to the database. I like to monitor if everybody is already transferred to the 10.1.100.x network before I will disable the 10.1.2.x.

View 2 Replies View Related

Windows :: Oracle Client Need To Install Its Clients Over Several Desktops

Apr 1, 2011

I have an Oracle server with Oracle 11g R2 and need to install its clients over several desktops.I am using 2 separate installs, but I think that this might be redundant.The 2 setups I'm using are:

- ODAC 11.2 Release 3 and Oracle Developer Tools for Visual Studio (11.2.0.2.1)
- 64-bit Oracle Data Access Components (ODAC) Downloads

- Is really necessary to install both of the 2 setup, or there is something I can use once instead of it?

View 4 Replies View Related

Networking And Gateways :: Clients Connections Failed Intermittently?

Jul 16, 2012

have some problem between my database and the listener Sometimes I have connection errors: The error occurred intermittently

Oracle 11.2.0.2.0 on RHEL 5
My listener:
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXx
LISTENER =

[code]...

The listener starts and stops normally
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXx
>lsnrctl start
LSNRCTL for Linux: Version 11.2.0.2.0 - Production on 16-JUL-2012 17:51:09
Copyright (c) 1991, 2010, Oracle. All rights reserved.

Starting /opt/oracle/product/EE_11.2.0/bin/tnslsnr: .

[code]...

But there is an error when the database register into the listener (in listener.log):
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXx
Started with pid=4029
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=xxxxxx)(PORT=1521)))
Listener completed notification to CRS on start

[code]....

View 2 Replies View Related

Forms :: Conversion - Make It Accessible Based On Browser To Clients?

Jul 6, 2011

i have developed an oracle form application in oracle developer 10g, now i want to make it accessible based on a browser to the clients(make it a web aaplication form)

View 3 Replies View Related

Status Online Logfile

Nov 2, 2010

I delete member logfile from disk with statement: shred -fu /u01/app/oracle/redologs/activeredolog/DB1/redo0102.log

But if I check status one logfile with statement:

select status from v$logfile wheremember='/u01/app/oracle/redologs/activeredolog/DB1/redo0102.log';

Status is still null. I think status should be change.

My database is 11.2.0.1 with single instance.

Status is changed after restart instance.

Haw can I monitor status logfiles without restart instance?

View 2 Replies View Related

SQL & PL/SQL :: Batch ID From Child Status

Mar 27, 2013

Im looking for a query which returns the batch for which all the child should either be in 'A_STATUS','B_STATUS' or 'C_STATUS'. In this query im expecting a query which returns batch 2,3 and 4.

create table batch (batchid number);
insert into batch values(1);
insert into batch values(2);
insert into batch values(3);
insert into batch values(4);

[Code]...

View 9 Replies View Related

Forms :: Record Status Bar?

Jun 2, 2011

i am migrating forms 6i to 10g, when i compile one form to checking purpose all are successfully fine but the record status bar not showing there fore message are not appear how to solve this problem

View 1 Replies View Related

SQL & PL/SQL :: Get Continuous Dates With Same Status Value

Feb 23, 2012

I'm looking for a way to get continuous dates as a period in the result.My tabledata contains a date and a status, I want to get continuous dates with the same status value.

That's my tabledata:
select * from (
select to_date('01022012', 'ddmmyyyy') as thedate, 1 as status from dual
union select to_date('02022012', 'ddmmyyyy') as thedate, 1 as status from dual
union select to_date('03022012', 'ddmmyyyy') as thedate, 2 as status from dual

[code]...

THEDATE STATUS
---------- ------
01.02.2012 1
02.02.2012 1
03.02.2012 2
04.02.2012 1
05.02.2012 1

[code]...

And that's the result I am looking for:
select * from (
select to_date('01022012', 'ddmmyyyy') as startdate,
to_date('02022012', 'ddmmyyyy') as enddate from dual
union select to_date('04022012', 'ddmmyyyy') as startdate,

[code]....

View 6 Replies View Related

SQL & PL/SQL :: Monitoring Status Of Procedure?

Feb 24, 2010

I've got a pl/sql procedure that i would like to monitor its progress. Its been running for quite a few hours now and i dont really know if it is stuck in a loop or if it is just taking too long read/execute queries. Is there a way to find out what is the status of the procedure? or what it is currently doing?

I looked at views like v$sessions or v$session_longops but they dont actually tell me what it is currently doing. All of them just point to the call to the pl/sql procedure. Also, is it possible to look at the physical files on the filesystem to know if there is actually any processing going on and files are being written to? Is this possible or a files written to only after a commit?

View 17 Replies View Related

SQL & PL/SQL :: Display Output IDs Which Are Having Status Both Y And N?

May 11, 2012

CREATE TABLE stud(id number,Status CHAR(1))

INSERT INTO stud values(10,'Y')
INSERT INTO stud values(10,'Y')
INSERT INTO stud values(10,'Y')
INSERT INTO stud values(10,'N')

[code]...

ID STATUS

10 Y
10 Y
10 Y
10 N
20 Y

[code]...

I want to display the out put the IDs which are having the status both 'Y' and 'N'The output should be

ID STATUS

10 Y
10 Y
10 Y
10 N
20 Y
20 N
20 N

View 12 Replies View Related

Upgrade :: Get Listener Status?

Oct 31, 2012

We are upgrading 10.2.0.4 enterprise edition single instance to 11.2.0.3 enterprise edition single edition manually. What should the listener status while doing upgradation. This is my first upgradation project.

View 5 Replies View Related

How To Change Remote_login_password File Status

Jan 21, 2006

How to change the status of remote_login_password file!

View 14 Replies View Related

Create A Procedure To Update Status?

Mar 10, 2011

create a procedure that will update the column status from active to closed after every two years.

View 4 Replies View Related

How To Check Status Of Import (old Method) Job

Aug 23, 2011

Question:

How to find out the status of the import job(how much work is done, ETA), i have started the job few days back it still running on the server. i am using import not datapump, because i got the dump which took with export. DB version is 11.2.0.2.0

for datapump i know i can use the following queries, but these are not giving any output l think these are only for datapump

select sid, serial#, sofar, totalwork from v$session_longops;
select sid, serial# from v$session s, dba_datapump_sessions d where s.saddr = d.saddr;

View 1 Replies View Related

How To Change Tablespace Plugged_in (no Status To Yes)

Aug 6, 2010

how to change tablespace plugged_in =no status to yes

View 1 Replies View Related

SQL & PL/SQL :: Change The Temp Table Status?

Jun 21, 2011

In one of the databases, we have created more temp tables as on commit preserve rows. but i want to change the on commit preserve rows to on commit delete rows as per application requirements.I have searched the google but i didnt find any alter scripts for it.?

View 1 Replies View Related

Forms :: How To Check Record Status

Sep 7, 2011

I am manually committing the form by writing commit statement in key - commit trigger for some reason.

Everything is working fine. I want to display a message if some necessary fields are not filled properly, like if a user filled half table and mistakenly he press the commit button. Here I want to show him a message that you can't saved the data because the table is not completely filled.

View 17 Replies View Related

SQL & PL/SQL :: Fetch Records Based On 2 Status

Jan 25, 2013

create table test_exp (oid number, ioid number, status varchar2(20));

Below are the insert statements.

Insert into TEST_EXP (OID, IOID, STATUS) Values (1, 100, 'NEW');
Insert into TEST_EXP (OID, IOID, STATUS) Values (1, 101, 'DISCO');
Insert into TEST_EXP (OID, IOID, STATUS) Values (1, 102, 'CANCELLED');
Insert into TEST_EXP (OID, IOID, STATUS) Values (2, 103, 'NEW');
Insert into TEST_EXP (OID, IOID, STATUS) Values (3, 104, 'DISCO');
Insert into TEST_EXP (OID, IOID, STATUS) Values (4, 105, 'DISCO');
Insert into TEST_EXP (OID, IOID, STATUS) Values (4, 106, 'NEW');
Insert into TEST_EXP (OID, IOID, STATUS) Values (5, 107, 'NEW');
Insert into TEST_EXP (OID, IOID, STATUS) Values (5, 108, 'CANCELLED');
[code]...

Now my problem is we should fetch the data based on the below rules

If an OID contains 2 IOIDs for which there is a NEW and DISCO status attached, then fetch the 2 records
If an OID has only 1 of these status, then ignore the same
If an OID has none of the 2 status, then ignore the same.

The expected output will be like below:

OID|IOID|STATUS
1 |100 |NEW
1 |101 |DISCO
4 |105 |DISCO
4 |106 |NEW

View 4 Replies View Related







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