Select is slow
Hi, the following select is very slow :
SELECT "EN_PERSON"."NAME",
"EN_PERSON"."FIRSTNAMES",
"EN_CONTRACT"."NRWORKER",
"EN_AMENDMENT"."NROCCUR",
"EN_AMENDMENT"."ENTRYDATE",
"EN_AMENDMENT"."OUTDATE",
"EN_CONTRACT"."ROW_ID",
"EN_CONTRACT"."F_PAYGROUP",
"EN_CONTRACT"."F_DEPARTMENT",
"EN_CONTRACT"."F_EMPLOYER",
"EN_AMENDMENT"."ROW_ID",
"EN_PERSON"."ROW_ID",
"EN_EMPLOYER"."DOSSIER",
"EN_AMENDMENT"."NR_CT_AM",
"EN_AMENDMENT"."F_TIMEGRID"
FROM "EN_AMENDMENT",
"EN_CONTRACT",
"EN_PERSON",
"EN_EMPLOYER"
WHERE ( "EN_PERSON"."ROW_ID" = "EN_CONTRACT"."F_PERSON" ) and
( "EN_CONTRACT"."ROW_ID" = "EN_AMENDMENT"."F_CONTRACT" ) and
( "EN_CONTRACT"."F_EMPLOYER" = "EN_EMPLOYER"."ROW_ID" ) and
( ( "EN_AMENDMENT"."B_OCCUR" = '1' ) AND
( "EN_AMENDMENT"."NROCCUR" = (select max(a.nroccur) from en_amendment A where A.f_contract="EN_CONTRACT"."ROW_ID" and A.b_occur='1') ) )
It seems that the last condition of the where clause is the problem.
How can it be faster ?
Thank for your help,
Fabrice
null
Try the following
SELECT
"EN_PERSON"."NAME",
"EN_PERSON"."FIRSTNAMES",
"EN_CONTRACT"."NRWORKER",
"EN_AMENDMENT"."NROCCUR",
"EN_AMENDMENT"."ENTRYDATE",
"EN_AMENDMENT"."OUTDATE",
"EN_CONTRACT"."ROW_ID",
"EN_CONTRACT"."F_PAYGROUP",
"EN_CONTRACT"."F_DEPARTMENT",
"EN_CONTRACT"."F_EMPLOYER",
"EN_AMENDMENT"."ROW_ID",
"EN_PERSON"."ROW_ID",
"EN_EMPLOYER"."DOSSIER",
"EN_AMENDMENT"."NR_CT_AM",
"EN_AMENDMENT"."F_TIMEGRID"
FROM
"EN_AMENDMENT",
"EN_CONTRACT",
"EN_PERSON",
"EN_EMPLOYER" ,
(select max(nroccur) maxdate
from en_amendment
where
A.f_contract="EN_CONTRACT"."ROW_ID" and
A.b_occur='1') A
WHERE
"EN_PERSON"."ROW_ID" = EN_CONTRACT"."F_PERSON" and
"EN_CONTRACT"."ROW_ID" = "EN_AMENDMENT"."F_CONTRACT" and
"EN_CONTRACT"."F_EMPLOYER" = "EN_EMPLOYER"."ROW_ID" and
"EN_AMENDMENT"."B_OCCUR" = '1' ) AND
"EN_AMENDMENT"."NROCCUR" = a.maxdate
Using the inline view (subquery in the from clause with an alias)
instead of the original correlated subquery in the where clause, allows
it to use the subquery as if it were a table and use the join conditions similarly,
eliminating the back and forth comparisons. Therefore, in general, it tends to be
faster. Indexes on the datecolumn for each table would also tend to help. This
may or may not be all that is needeed.
null
Similar Messages
-
Select running slow in prod but work fine in T-1
We have a query which run very slow on production database it is taking around 7 min to run.
While it is working fine on T-1 database which gets refreshed every night, here it takes around 3 seconds.
both the os version and database versions are same.
Database is also refreshed and have same data and statistics.
please update what could be the reason?
SELECT c.txt_master_claim_no "Master Claim No",
c.num_serial_no "Serial No",
TO_CHAR(c.dat_loss_date, 'dd / mm / yyyy') "Loss Date",
d.departmentname "Line of Business",
m.productname "Product",
tab.stat "Status"
FROM (SELECT t.num_claim_no, 'REPUDIATION' stat, num_update_no
FROM gc_clm_gen_info t, gc_clm_os a
WHERE t.num_update_no =
(SELECT MAX(p.num_update_no)
FROM gc_clm_gen_info p
WHERE p.num_claim_no = t.num_claim_no)
AND t.txt_claim_status = 'X'
AND a.cur_os_amount = 0
AND a.num_ac_year * 100 + a.num_ac_month =
(select max(s.num_ac_year * 100 + s.num_ac_month)
from gc_clm_os s
where s.num_claim_no = a.num_claim_no)
AND t.num_claim_no = a.num_claim_no
UNION
SELECT a.num_claim_no, 'DISBURSE' stat, num_update_no
FROM gc_clm_os a, gc_clm_gen_info b
WHERE a.cur_os_amount = 0
AND a.num_ac_year * 100 + a.num_ac_month =
(select max(s.num_ac_year * 100 + s.num_ac_month)
from gc_clm_os s
where s.num_claim_no = a.num_claim_no)
AND b.num_update_no >
(SELECT MAX(x.num_update_no)
FROM gc_clm_gen_info x
WHERE x.num_claim_no = b.num_claim_no
AND x.txt_claim_status in ('F', 'X'))
AND a.num_claim_no = b.num_claim_no
UNION
SELECT a.num_claim_no, 'DISBURSE' stat, num_update_no
FROM gc_clm_os a, gc_clm_gen_info b
WHERE a.cur_os_amount = 0
AND a.num_ac_year * 100 + a.num_ac_month =
(select max(s.num_ac_year * 100 + s.num_ac_month)
from gc_clm_os s
where s.num_claim_no = a.num_claim_no)
AND b.num_update_no =
(SELECT MAX(x.num_update_no)
FROM gc_clm_gen_info x
WHERE x.num_claim_no = b.num_claim_no)
AND a.num_claim_no = b.num_claim_no
And b.txt_claim_status = 'F'
and not exists
(select 1
from gc_clm_payment_details p
where p.num_claim_no = a.num_claim_no
and p.txt_status in ('APPROVAL DUE', 'APPROVED'))
) tab,
gc_clm_gen_info c,
uw_product_master m,
uw_department_master d
WHERE tab.num_claim_no = c.num_claim_no
AND c.num_update_no =
(SELECT MAX(d.num_update_no)
FROM gc_clm_gen_info d
WHERE d.num_claim_no = c.num_claim_no)
AND c.num_department_code = d.departmentcode
AND m.productcode = c.num_product_code
AND M.DEPARTMENTCODE=D.DEPARTMENTCODE
AND c.txt_claim_status NOT IN ('O', 'S')
AND c.num_update_no = tab.num_update_no
AND c.num_claim_no not in
(select p.num_claim_no
from gc_clm_payment_details p, gc_clmmst_resource_type r
where p.num_type_of_party = r.num_resource_type_cd
and r.txt_loss_exp = 'E'
and p.txt_status = 'APPROVAL DUE') and Upper(C.txt_master_claim_no) like '%C231110020345%' order by c.NUM_CLAIM_NO Desc;
Edited by: user12195658 on Mar 24, 2011 7:27 AMfrom T-1 explain plan output is:
Explain complete.
PLAN_TABLE_OUTPUT
| Id | Operation | Name | Rows | Bytes |TempSpc| Cost (%CPU)|
| 0 | SELECT STATEMENT | | 1 | 132 | | 5862 (4)|
| 1 | SORT ORDER BY | | 1 | 132 | | 5862 (4)|
| 2 | NESTED LOOPS | | 1 | 132 | | 5853 (4)|
| 3 | NESTED LOOPS | | 1 | 97 | | 5852 (4)|
| 4 | NESTED LOOPS | | 1 | 83 | | 5851 (4)|
| 5 | VIEW | | 78 | 2574 | | 5617 (4)|
| 6 | SORT UNIQUE | | 78 | 6992 | | 5617 (78)|
| 7 | UNION-ALL | | | | | |
| 8 | FILTER | | | | | |
| 9 | HASH JOIN | | 29 | 1943 | | 1266 (5)|
| 10 | HASH JOIN | | 2895 | 115K| | 584 (5)|
| 11 | INDEX FAST FULL SCAN | IND_GC_CLM_GEN_INFO | 2437 | 43866 | | 353 (5)|
| 12 | TABLE ACCESS FULL | GC_CLM_OS | 36517 | 820K| | 229 (4)|
| 13 | VIEW | VW_SQ_1 | 43391 | 1101K| | 680 (4)|
| 14 | HASH GROUP BY | | 43391 | 1313K| 4712K| 680 (4)|
| 15 | TABLE ACCESS FULL | GC_CLM_OS | 65293 | 1976K| | 228 (4)|
| 16 | SORT AGGREGATE | | 1 | 15 | | |
| 17 | INDEX RANGE SCAN | IND_GC_CLM_GEN_INFO | 6 | 90 | | 3 (0)|
| 18 | HASH JOIN | | 76 | 6840 | | 2001 (5)|
| 19 | HASH JOIN | | 2207 | 137K| | 1338 (5)|
| 20 | HASH JOIN | | 365 | 17885 | 1256K| 1054 (4)|
| 21 | TABLE ACCESS FULL | GC_CLM_OS | 36517 | 820K| | 229 (4)|
| 22 | VIEW | VW_SQ_2 | 43391 | 1101K| | 680 (4)|
| 23 | HASH GROUP BY | | 43391 | 1313K| 4712K| 680 (4)|
| 24 | TABLE ACCESS FULL | GC_CLM_OS | 65293 | 1976K| | 228 (4)|
| 25 | INDEX FAST FULL SCAN | PK_GC_CLM_GEN_INFO | 262K| 3849K| | 276 (5)|
| 26 | VIEW | VW_SQ_3 | 30152 | 765K| | 661 (5)|
| 27 | HASH GROUP BY | | 30152 | 883K| 3336K| 661 (5)|
| 28 | INDEX FAST FULL SCAN | IND_GC_CLM_GEN_INFO | 46690 | 1367K| | 356 (6)|
| 29 | FILTER | | | | | |
| 30 | HASH JOIN | | 511 | 43435 | | 1535 (5)|
| 31 | HASH JOIN ANTI | | 337 | 22579 | | 1180 (4)|
| 32 | HASH JOIN | | 365 | 17885 | 1256K| 1054 (4)|
| 33 | TABLE ACCESS FULL | GC_CLM_OS | 36517 | 820K| | 229 (4)|
| 34 | VIEW | VW_SQ_4 | 43391 | 1101K| | 680 (4)|
| 35 | HASH GROUP BY | | 43391 | 1313K| 4712K| 680 (4)|
| 36 | TABLE ACCESS FULL | GC_CLM_OS | 65293 | 1976K| | 228 (4)|
| 37 | INDEX FAST FULL SCAN | IND_GC_CLM_PAYMENT_DETAILS | 2396 | 43128 | | 125 (6)|
| 38 | INDEX FAST FULL SCAN | IND_GC_CLM_GEN_INFO | 44253 | 777K| | 354 (5)|
| 39 | SORT AGGREGATE | | 1 | 15 | | |
| 40 | INDEX RANGE SCAN | IND_GC_CLM_GEN_INFO | 6 | 90 | | 3 (0)|
| 41 | TABLE ACCESS BY INDEX ROWID | GC_CLM_GEN_INFO | 1 | 50 | | 3 (0)|
| 42 | INDEX RANGE SCAN | PK_GC_CLM_GEN_INFO | 1 | | | 2 (0)|
| 43 | SORT AGGREGATE | | 1 | 15 | | |
| 44 | INDEX RANGE SCAN | IND_GC_CLM_GEN_INFO | 6 | 90 | | 3 (0)|
| 45 | NESTED LOOPS | | 1 | 26 | | 5 (0)|
| 46 | TABLE ACCESS BY INDEX ROWID| GC_CLM_PAYMENT_DETAILS | 1 | 21 | | 4 (0)|
| 47 | INDEX RANGE SCAN | IND_GC_CLM_PAYMENT_DETAILS | 1 | | | 3 (0)|
| 48 | TABLE ACCESS BY INDEX ROWID| GC_CLMMST_RESOURCE_TYPE | 1 | 5 | | 1 (0)|
| 49 | INDEX UNIQUE SCAN | PK_GC_CLMMST_RESOURCE_TYPE | 1 | | | 0 (0)|
| 50 | INDEX RANGE SCAN | UW_DEPARTMENT_MASTER_INDX | 1 | 14 | | 1 (0)|
| 51 | INDEX RANGE SCAN | IND_UW_PRODUCT_MASTER | 1 | 35 | | 1 (0)|
Note
- 'PLAN_TABLE' is old version
61 rows selected. -
Good day master's!
I'm having a so slow query with this code:
SELECT EBELN BELNR AUGBL GJAHR KOSTL INTO TABLE IT_BSEG FROM BSEG WHERE EBELN EQ LS_EKKO-EBELN AND BUKRS EQ S_BUKRS.
I use ABAP debugger and found out the cause why my program are so slow. Reading the BSEG table take a while to read. Is there alternate way to use.
Thanks, Sorry for my bad english.Hi Kenneth,
Please try this
TYPES: BEGIN OF TY_RSEG,
BELNR TYPE RSEG-BELNR,
GJAHR TYPE RSEG-GJAHR,
EBELN TYPE RSEG-EBELN,
EBELP TYPE RSEG-EBELP,
AWKEY TYPE BKPF-AWKEY,
END OF TY_RSEG.
TYPES: BEGIN OF TY_BKPF,
BUKRS TYPE BKPF-BUKRS,
BELNR TYPE BKPF-BELNR,
GJAHR TYPE BKPF-GJAHR,
AWKEY TYPE BKPF-AWKEY,
END OF TY_BKPF.
DATA: IT_RSEG TYPE TABLE OF TY_RSEG,
IT_BKPF TYPE TABLE OF TY_BKPF.
FIELD-SYMBOLS : <FS_RSEG> TYPE TY_RSEG.
SELECT BELNR GJAHR EBELN EBELP FROM RSEG INTO CORRESPONDING FIELDS OF TABLE IT_RSEG
WHERE EBELN IN S_EBELN.
LOOP AT IT_RSEG ASSIGNING <FS_RSEG>.
<FS_RSEG>-AWKEY+0(10) = <FS_RSEG>-BELNR.
<FS_RSEG>-AWKEY+10(4) = <FS_RSEG>-GJAHR.
ENDLOOP.
IF IT_RSEG[] IS NOT INITIAL.
SELECT BUKRS BELNR GJAHR AWKEY FROM BKPF INTO TABLE IT_BKPF FOR ALL ENTRIES IN IT_RSEG
WHERE AWKEY = IT_RSEG-AWKEY.
ENDIF.
IF IT_BKPF[] IS NOT INITIAL.
SELECT * FROM BSEG INTO TABLE IT_BSEG FOR ALL ENTRIES IN IT_BKPF
WHERE BUKRS = IT_BKPF-BUKRS
AND BELNR = IT_BKPF-BELNR
AND GJAHR = IT_BKPF-GJAHR.
ENDIF.
I Think , it is helpful.
Regards,
Nilesh Patel -
Adobe Illustrator object Direct or Indirect Select is Slow MBP5,4
ISSUE: Using Direct or Indirect Selection tool on any object in Illustrator CS3 or CS4 is slow (usually presents beach ball). It is an irritation not feature failure. To reproduce, create a new Illustrator file on MacBookPro5,4, (effects RGB or CMYK, all preview and non preview modes), create a line segment, create a square (or any other closed shape), create a text line. Grab the direct selection tool and click on any of the objects. You may not see the slowness on first selection. Now click on any of the other objects. The machine will pause. The existing selection will not disappear. The beach ball will appear and spin. After roughly 2 seconds, the existing selection will disappear, the new selection will be made as expected.
NOTE: strangely, if you do a drag selection (marquee drag) rather than clicking on the object with the selection tool, the delay does NOT occur!"The problem ONLY occurs on my new MacBookPro5,4. So by all appearances is it a difference in video hardware of software on the new machine."
If that's the case then posting in the Adobe forums should bare that out and you'll have solved your issue. If that's not the case then you'll have solved your issue as well. Either way... -
Delete with sub select sometimes slow
Hi all,
we have following problem in version 11.2:
we run some deletes similar delete-statements:
delete from msvs where fk_msv_nr in (select pk_msv_nr from msv where rueckweisungsgrund = '<Falsch aus ePUB angelegt>');
delete from zbe where fk_msv_nr in (select pk_msv_nr from msv where rueckweisungsgrund = '<Falsch aus ePUB angelegt>');
delete from zag where fk_msv_nr in ( select pk_msv_nr from msv where rueckweisungsgrund = '<Falsch aus ePUB angelegt>');
table msv has 500000 rows, the select has 390000 rows and is running a few seconds, seems good.
table msvs has 1000000 rows, zbe 3250000 rows and zag 513000 rows
pk_msv_nr is primary key on msv
fk_msv_nr is foreign key and referencing table msv
delete from msvs: 780000 rows, 55sec
delete from zbe: 2885000 rows 5min 55sec
delete from zag: process killed after 30min
execution plan shows FTS on msv and index range scan on idx_zag_fk_msv_nr (foreign key)
also i see more than 100'000'000 logical reads
we have similar problem with one other table
Anybody an idea, why the deletes on two tables are slow, a few other tables (all with same sub-select) are in time
Thanks for any help!!!
Regards
JürgenSQL> explain plan for
2 delete from msvs where fk_msv_nr in (select pk_msv_nr from msv where rueckweisungsgrund = '<Falsch aus ePUB angelegt>');
Explained.
Elapsed: 00:00:00.21
SQL> @?/rdbms/admin/utlxpls
PLAN_TABLE_OUTPUT
| Id | Operation | Name | Rows | Bytes | Cost |
| 0 | DELETE STATEMENT | | 1 | 21 | 2202 |
| 1 | DELETE | MSVS | | | |
| 2 | NESTED LOOPS | | 1 | 21 | 2202 |
| 3 | TABLE ACCESS FULL| MSV | 1 | 7 | 2200 |
| 4 | INDEX RANGE SCAN | IDX_UNIQUE_MSVS_PK | 2 | 28 | 2 |
SQL> explain plan for
2 delete from zbe where fk_msv_nr in (select pk_msv_nr from msv where rueckweisungsgrund = '<Falsch aus ePUB angelegt>');
Explained.
Elapsed: 00:00:00.09
SQL> @?/rdbms/admin/utlxpls
PLAN_TABLE_OUTPUT
| Id | Operation | Name | Rows | Bytes | Cost |
| 0 | DELETE STATEMENT | | 3 | 78 | 2202 |
| 1 | DELETE | ZBE | | | |
| 2 | NESTED LOOPS | | 3 | 78 | 2202 |
| 3 | TABLE ACCESS FULL| MSV | 1 | 7 | 2200 |
| 4 | INDEX RANGE SCAN | IDX_UNIQUE_ZBE_PK | 7 | 133 | 2 |
SQL> explain plan for
2 delete from zag where fk_msv_nr in ( select pk_msv_nr from msv where rueckweisungsgrund = '<Falsch aus ePUB angelegt>');
Explained.
SQL> @?/rdbms/admin/utlxpls
PLAN_TABLE_OUTPUT
| Id | Operation | Name | Rows | Bytes | Cost |
| 0 | DELETE STATEMENT | | 1 | 27 | 2202 |
| 1 | DELETE | ZAG | | | |
| 2 | NESTED LOOPS | | 1 | 27 | 2202 |
| 3 | TABLE ACCESS FULL| MSV | 1 | 7 | 2200 |
| 4 | INDEX RANGE SCAN | IDX_ZAG_FK_MSV_NR | 3 | 60 | 2 | -
Selective and slow syncing in iCal
Today I updated my iPhone and iPad to iOs 5 and my laptop to 10.7.2. The iPhone and iPad have subsribed to iCloud, but not yet for the laptop. I also have an imac running 10.6.8 (can't update it to Lion because I need Rosetta) and a G5 running 10.5.8.
Tests on syncing iCal have shown it to be very slow and sometimes failing to sync.
The iOs devices show changes across each other almost immediately - and MobileMe (accessed throgh Safari) is also almost instant. But the Snow leopard and leopard machines take quite a while to update, 20 mins or so. Now this could just because everybody is doing what I'm doing and there's a lot of traffic, but the slowest of all is the laptop running 10.7.2. Events entered on the ipad took over half an hour to appear on this machine, and one event I created in its own iCal has still not transferred to either of the other desktops, although it has arrived on the iOs devices.
is this unusual? Does anybody else notice this?.
Also, I am hesitant to move my MobileMe account to the Cloud because I understand that my desktop machines that are not running Lion will not be able to sync iCal (or contatcts etc) with the Cloud - it is an iOs5 and Lion facility only. Is this true?Today I updated my iPhone and iPad to iOs 5 and my laptop to 10.7.2. The iPhone and iPad have subsribed to iCloud, but not yet for the laptop. I also have an imac running 10.6.8 (can't update it to Lion because I need Rosetta) and a G5 running 10.5.8.
Tests on syncing iCal have shown it to be very slow and sometimes failing to sync.
The iOs devices show changes across each other almost immediately - and MobileMe (accessed throgh Safari) is also almost instant. But the Snow leopard and leopard machines take quite a while to update, 20 mins or so. Now this could just because everybody is doing what I'm doing and there's a lot of traffic, but the slowest of all is the laptop running 10.7.2. Events entered on the ipad took over half an hour to appear on this machine, and one event I created in its own iCal has still not transferred to either of the other desktops, although it has arrived on the iOs devices.
is this unusual? Does anybody else notice this?.
Also, I am hesitant to move my MobileMe account to the Cloud because I understand that my desktop machines that are not running Lion will not be able to sync iCal (or contatcts etc) with the Cloud - it is an iOs5 and Lion facility only. Is this true? -
Select very slow on empty table
Oracle 9.2.0.5.0
I had a table with ~1m rows. I truncated it. I then analysed the table and all it's indexes. After that a select * from table was taking ~10secs but the table was empty. Our DBA fixed the problem but I am intriged in what he did. Any ideas?
ThanksAs requested, the table script:
CREATE TABLE "AcEvent"
"EventId" INTEGER NOT NULL,
"EventTimestamp" DATE NOT NULL,
"SystemComponentId" INTEGER NOT NULL,
"UserName" VARCHAR2(50 BYTE) NOT NULL,
"EventTypeCode" INTEGER NOT NULL,
"StartTimestamp" DATE NOT NULL,
"EndTimestamp" DATE NOT NULL,
"StatusCode" INTEGER NOT NULL,
"ServiceTypeCode" INTEGER NOT NULL
TABLESPACE ACTUATE_DATA
PCTUSED 0
PCTFREE 10
INITRANS 1
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS 2147483645
PCTINCREASE 0
BUFFER_POOL DEFAULT
LOGGING
NOCOMPRESS
NOCACHE
NOPARALLEL
NOMONITORING;
CREATE INDEX ACEVENT_IDX_01 ON "AcEvent"
("EventId", "SystemComponentId", "StatusCode", "ServiceTypeCode", "EventTypeCode",
"EventTimestamp", UPPER(DECODE("UserName",'-',NULL,"UserName")))
LOGGING
TABLESPACE ACTUATE_DATA
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS 2147483645
PCTINCREASE 0
BUFFER_POOL DEFAULT
NOPARALLEL;
CREATE INDEX "AcEv_SyCoId_Idx" ON "AcEvent"
("SystemComponentId")
LOGGING
TABLESPACE ACTUATE_DATA
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS 2147483645
PCTINCREASE 0
BUFFER_POOL DEFAULT
NOPARALLEL
COMPRESS 1;
CREATE INDEX "AcEv_StCo_Idx" ON "AcEvent"
("StatusCode")
LOGGING
TABLESPACE ACTUATE_DATA
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS 2147483645
PCTINCREASE 0
BUFFER_POOL DEFAULT
NOPARALLEL
COMPRESS 1;
CREATE INDEX "AcEv_EvTi_Idx" ON "AcEvent"
("EventTimestamp")
LOGGING
TABLESPACE ACTUATE_DATA
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS 2147483645
PCTINCREASE 0
BUFFER_POOL DEFAULT
NOPARALLEL;
CREATE INDEX "AcEv_UsNa_Idx" ON "AcEvent"
("UserName")
LOGGING
TABLESPACE ACTUATE_DATA
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS 2147483645
PCTINCREASE 0
BUFFER_POOL DEFAULT
NOPARALLEL
COMPRESS 1;
CREATE INDEX "AcEv_EvTyCo_Idx" ON "AcEvent"
("EventTypeCode")
LOGGING
TABLESPACE ACTUATE_DATA
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS 2147483645
PCTINCREASE 0
BUFFER_POOL DEFAULT
NOPARALLEL
COMPRESS 1;
CREATE INDEX "AcEv_SyTyCo_Idx" ON "AcEvent"
("ServiceTypeCode")
LOGGING
TABLESPACE ACTUATE_DATA
PCTFREE 10
INITRANS 2
MAXTRANS 255
STORAGE (
INITIAL 64K
MINEXTENTS 1
MAXEXTENTS 2147483645
PCTINCREASE 0
BUFFER_POOL DEFAULT
NOPARALLEL
COMPRESS 1;
ALTER TABLE "AcEvent" ADD (
CONSTRAINT "AcEv_EvId_Idx"
PRIMARY KEY
("EventId"));
ALTER TABLE "AcEvent" ADD (
FOREIGN KEY ("SystemComponentId")
REFERENCES "AcSystemComponent" ("SystemComponentId"));
ALTER TABLE "AcEvent" ADD (
FOREIGN KEY ("EventTypeCode")
REFERENCES "AcEventType" ("EventTypeCode"));
ALTER TABLE "AcEvent" ADD (
FOREIGN KEY ("StatusCode")
REFERENCES "AcStatus" ("StatusCode"));
ALTER TABLE "AcEvent" ADD (
FOREIGN KEY ("ServiceTypeCode")
REFERENCES "AcServiceType" ("ServiceTypeCode")); -
Single click object selection painfully slow
Hi,
I don't have any particular speed issue with illustrator CS6 in general.
However there is a massive speed problem when I'm trying to select on object on the artboard with a single click.
Is anyone else having the same issue? Is it simply a setting that may be wrong somewhere for me?
When selecting a object by creating a "rectangle" over the object it works fine and normal speed.
When clicking the object to select it, nothing happens for about 3/4 seconds, then the loading little rainbow circle appears and loads for another 3/4 seconds...
I really don't understand what's happening.
If anyone could help me that would be greatly appreciated (it's driving me insane)...
ThanksNevermind...
Finally found the reason after hours searching on the Adobe forum or google, and battling with different settings in illustrator...
For those who may encounter the same issue, I'm running "RightZoom" on my Mac to fully maximize my windows.
For some reasons they don't seem to like each other! Well, Illustrator doesn't like RightZoom...
To fix the issue, simply open RightZoom and deactive it for the time you're using Illustrator CS6. Job done, working super fine
You can re-activate "RightZoom" whilst you're done with Illustrator.
Hope it can save someone the hassle I had! -
Peculiar selective Broadband slowness - read for explanation
Hi,
This is really bizarre, I have no idea what this could be. My G5 is exhibiting a painfully slow Broadband connection, but only at certain times and on my machine. Let me explain:
We have my G5 and a Macbook Pro on a wireless router. Recently over the past couple months I have had some issues with the G5: kernel panics. I had gone through some troubleshootng, used DiskWarrior to rebuild, etc, with no clear resolution. Just as mysteriously as they started, the kernel panics have gradually disppeared. I mention this because it was a performance anamoly, and is perhaps related to the current issue, maybe not.
So now as I surf, it takes forever - as in dialup speed, to "connect" to a web page. Sometimes once it "accesses" the page, it then displays the code rapidly as I would expect. I click a link, it hangs for a while, then seems to finally send out the request, "finds" the page and loads it. Sometimes it is slow with fully displaying the page. Using the SpeedStat 2 widget, which displays outgoing and incoming data speeds, it seems to show that the page request that is sent out is delayed.
I have no problem with streaming, downloading, or email. That all exhibits a more consistent speed with Broadband. The problem is just surfing, and I mainly use Safari. Using Firefox the problem is worse, and from SpeedStat2 again, it seems that no request is even sent out, it just hangs and hangs.
This is weird because our Macbook Pro on the wireless connection is very fast, even wireless and three rooms away. So it seems to be my machine solely. Even the browsers themselves.
I don't know to call my service provider or Apple, but it's really frustrating. I don't know if it's the browsers, some networking configuration, my hardware, my service provider. It seems the Broadband connection is working correctly based on the evidence. Any advice would be really appreciated!
thank you
G5, dual 2Ghz Mac OS X (10.4.6)Let me just emphasize one last time: in iTunes when I click on the Music Store, it takes f-o-r-e-v-e-r to load. As I click around in Safari again, it is v-e-r-y slow. It takes a long time to send out the request and the nsometimes in mid page it hangs again.
And most oddly our wireless Macbook Pro is lightning fast by comparison. Could it be cables or something? -
Start-up disk selection very slow, how to speed up.
I have multiple Operating Systems on my MBP and in order to boot form one in to the other I hold the Alt key at start-up. However, having several MBP', i5 on one machine it is extremely slow. It takes almost 2 minutes before the choice of disks appear, it is a i5, MacBookPro6,2.
Is there a way of speeding this up? Alernatively, is there maybe a Mac utility where I can choose the start-up disk from (not using the control panel as this would permanently change the start-up disk and I want the Mac OS to be the default OS) and invoke a restart?
Love to hear.We get email notifications if some color is clicked, otherwise posts drop off the pages as we think your not interested in our responses.
ChangeAgent wrote:
ds store wrote:
Sounds like your EFI is corrupted.
So my question was how one fixes that? Rest, un-corrupt.
I must have been tired, I meant "EFI and/or the GUID partition table"
You'll have to backup your files off the machine, erase and install 10.6, software update to 10.6.8, install all OS X programs, setup bootcamp again and can only install Windows 7 (not XP or Vista.) Return files from backup.
Follow these steps, you need to erase the ENTIRE drive of all partitions to catch the hidden EFI partition and rebuild the GUID partition table anew
How to erase and install Snow Leopard 10.6
Your direct boot XP days are history on your Mac, it's the Apple way to burn their bridges behind them faster and faster every year.
You might want to use a virtual machine instead, but there is a performance hit.
Windows in BootCamp or Virtual Machine? -
Quick Selection tool slows down when I have at least 5 layers
How can I remedy this problem?
Hey Hey Thanks a lot!:) I was so frusterated with the problem that I didn't even look there..LOL! Thanks again.
-
Performance Issue in select statements
In the following statements, it is taking too much time for execution,Is there any best way to change these selection statements...int_report_data is my final internal table....
select fsplant fvplant frplant fl1_sto pl1_delivery pl1_gr pl2_sto pl2_delivery perr_msg into (dochdr-swerks,dochdr-vwerks,dochdr-rwerks,dochdr-l1sto,docitem-l1xblnr, docitem-l1gr,docitem-l2sto, docitem-l2xblnr,docitem-err_msg) from zdochdr as f inner join zdocitem as p on fl1_sto = pl1_sto where fsplant in s_werks and
fvplant in v_werks and frplant in r_werks and pl1_delivery in l1_xblnr and pl1_gr in l1_gr and p~l2_delivery in l2_xblnr.
move : dochdr-swerks to int_report_data-i_swerks,
dochdr-vwerks to int_report_data-i_vwerks,
dochdr-rwerks to int_report_data-i_rwerks,
dochdr-l1sto to int_report_data-i_l1sto,
docitem-l1xblnr to int_report_data-i_l1xblnr,
docitem-l1gr to int_report_data-i_l1gr,
docitem-l2sto to int_report_data-i_l2sto,
docitem-l2xblnr to int_report_data-i_l2xblnr,
docitem-err_msg to int_report_data-i_errmsg.
append int_report_data.
endselect.
Goods receipt
loop at int_report_data.
select single ebeln from ekbe into l2gr where ebeln = int_report_data-i_l2sto and bwart = '101' and bewtp = 'E' and vgabe = '1'.
if sy-subrc eq 0.
move l2gr to int_report_data-i_l2gr.
modify int_report_data.
endif.
endloop.
first Billing document (I have to check fkart = ZRTY for second billing *document..how can i write the statement)
select vbeln from vbfa into (tabvbfa-vbeln) where vbelv = int_report_data-i_l2xblnr or vbelv = int_report_data-i_l1xblnr.
select single vbeln from vbrk into tabvbrk-vbeln where vbeln = tabvbfa-vbeln and fkart = 'IV'.
if sy-subrc eq 0.
move tabvbrk-vbeln to int_report_data-i_l2vbeln.
modify int_report_data.
endif.
endselect.
Thanks in advance,
YadHi!
Which of your selects is slow? Make a SQL-trace, check which select(s) is(are) slow.
For EKBE and VBFA you are selecting first key field - in general that is fast. If your z-tables are the problem, maybe an index might help.
Instead of looping and making a lot of select singles, one select 'for all entries' can help, too.
Please analyze further and give feedback.
Regards,
Christian -
Report on Smartform..To make it efficient by removing SELECT ,ENDSELECT
To make a smartform report efficient by removing all occurs & modify internal table statements.
What i have been given to do is to select all data from respective tables put them into one internal table & then finally making tab2 or tab3 in the report to be the final table.I am not sure which among these two i can make final table.
THE CODE is:
REPORT zgr_note.
TABLES : mseg, "Document Segment : Material
prps, "WBS element master data
proj, "Project Definition
mkpf, "Header : Material Document
lfa1, "Vendor Master
makt, "Material Description
aufk, "Order Master Data
afvc. "Operation within an order
DATA : fname LIKE rs38l-name. "Name of Function Module
DATA: lf_fm_name TYPE rs38l_fnam.
DATA: ls_control_param TYPE ssfctrlop.
DATA: ls_composer_param TYPE ssfcompop.
DATA: ls_recipient TYPE swotobjid.
DATA: ls_sender TYPE swotobjid.
DATA: lf_formname TYPE tdsfname.
DATA: ls_addr_key LIKE addr_key.
DATA: ls_dlv_land LIKE vbrk-land1.
DATA: ls_job_info TYPE ssfcrescl.
DATA: ls_otpt_opt TYPE ssfcompop.
DATA: retcode TYPE sy-subrc.
DATA: cntr TYPE i VALUE 0.
DATA: cntr1 TYPE i .
DATA: number TYPE SSFCRESCL-SPOOLIDS. " OCCURS 0 WITH HEADER LINE.
DATA: TSP01 type TABLE OF TSP01_SP0R.
DATA : BEGIN OF itab OCCURS 0.
INCLUDE STRUCTURE mseg.
DATA : post1 LIKE proj-post1, "Project Definition
pspnr LIKE proj-pspnr, "WBS element
maktx LIKE makt-maktx, "Material Description
name1 LIKE lfa1-name1, "Name of the supplier
budat LIKE mkpf-budat, "Posting date
bldat LIKE mkpf-bldat, "Document date
cpudt LIKE mkpf-cpudt, "Date on which account document was entered
psphi LIKE prps-psphi, "Current number of project
post2 LIKE prps-post1, "WBS Definition
xblnr LIKE mkpf-xblnr, "Reference number( in this case challan number)
bktxt LIKE mkpf-bktxt, "Header text
ort01 LIKE lfa1-ort01, "vendor city
ktext LIKE aufk-ktext, "network description
ltxa1 LIKE afvc-ltxa1. "operation short text
DATA : END OF itab.
DATA : BEGIN OF jtab OCCURS 0.
INCLUDE STRUCTURE itab.
DATA : END OF jtab.
DATA : itab1 LIKE itab OCCURS 0
WITH HEADER LINE.
DATA :itab2 LIKE itab OCCURS 0
WITH HEADER LINE.
DATA: itab3 LIKE itab OCCURS 0 WITH HEADER LINE.
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text_001.
SELECT-OPTIONS : gr_num FOR mseg-mblnr . "no INTERVALS.
PARAMETERS : gr_note LIKE itemset-xopsel RADIOBUTTON GROUP rad1.
SELECTION-SCREEN SKIP.
SELECT-OPTIONS : mat_num FOR mseg-mblnr . "no INTERVALS.
PARAMETERS : mat_slip LIKE itemset-xopsel RADIOBUTTON GROUP rad1.
SELECTION-SCREEN END OF BLOCK b1.
SELECTION-SCREEN SKIP.
CASE 'X'.
WHEN gr_note.
PERFORM gr_display.
WHEN mat_slip.
PERFORM mat_display.
ENDCASE.
FORM gr_display .
*break developer1.
SELECT mblnr mjahr matnr werks lgort lifnr menge meins
erfmg bpmng ebeln ps_psp_pnr zeile lsmng erfme
FROM mseg
INTO CORRESPONDING FIELDS OF TABLE itab
WHERE mblnr IN gr_num.
LOOP AT itab.
SELECT pspnr psphi post1 INTO CORRESPONDING FIELDS OF itab1
FROM prps WHERE pspnr = itab-ps_psp_pnr.
itab-psphi = itab1-psphi.
itab-pspnr = itab1-pspnr.
itab-post2 = itab1-post1.
MODIFY itab TRANSPORTING psphi pspnr post2.
ENDSELECT.
SELECT post1 FROM proj INTO CORRESPONDING FIELDS OF itab2
WHERE pspnr = itab-psphi.
itab-post1 = itab2-post1.
MODIFY itab TRANSPORTING post1.
ENDSELECT.
REFRESH itab2.
SELECT maktx FROM makt INTO CORRESPONDING FIELDS OF itab2
WHERE matnr = itab-matnr.
itab-maktx = itab2-maktx.
MODIFY itab TRANSPORTING maktx.
ENDSELECT.
REFRESH itab2.
SELECT name1 ort01 FROM lfa1 INTO CORRESPONDING FIELDS OF itab2
WHERE lifnr = itab-lifnr.
itab-name1 = itab2-name1.
itab-ort01 = itab2-ort01.
MODIFY itab TRANSPORTING name1 ort01.
ENDSELECT.
REFRESH itab2.
SELECT budat bldat cpudt xblnr bktxt FROM mkpf
INTO CORRESPONDING FIELDS OF itab2
WHERE mblnr = itab-mblnr.
itab-budat = itab2-budat.
itab-bldat = itab2-bldat.
itab-cpudt = itab2-cpudt.
itab-xblnr = itab2-xblnr.
itab-bktxt = itab2-bktxt.
MODIFY itab TRANSPORTING budat bldat cpudt xblnr bktxt.
ENDSELECT.
ENDLOOP.
LOOP AT itab .
ON CHANGE OF itab-mblnr.
itab3-mblnr = itab-mblnr.
itab3-post1 = itab-post1.
itab3-post2 = itab-post2.
itab3-name1 = itab-name1.
itab3-ort01 = itab-ort01.
itab3-bldat = itab-bldat.
APPEND itab3.
CLEAR itab3.
ENDON.
ENDLOOP.
jtab-mblnr = itab-mblnr.
jtab-xblnr = itab-xblnr.
jtab-budat = itab-budat.
jtab-bktxt = itab-bktxt.
jtab-lsmng = itab-lsmng.
jtab-erfmg = itab-erfmg.
jtab-erfme = itab-erfme.
jtab-matnr = itab-matnr.
jtab-maktx = itab-maktx.
jtab-zeile = itab-zeile.
APPEND jtab.
LOOP AT itab3.
CLEAR: itab2,itab2[].
LOOP AT itab WHERE mblnr = itab3-mblnr.
MOVE-CORRESPONDING itab TO itab2.
APPEND itab2.
CLEAR itab2.
ENDLOOP.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = 'ZMM_GOODS_RECEIPT1'
VARIANT = ' '
DIRECT_CALL = ' '
IMPORTING
fm_name = fname
EXCEPTIONS
NO_FORM = 1
NO_FUNCTION_MODULE = 2
OTHERS = 3
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
*break developer1.
PERFORM print_parameters.
CALL FUNCTION fname
EXPORTING
control_parameters = ls_control_param
output_options = ls_otpt_opt
user_settings = 'X'
gr_mseg_hdr = itab3
IMPORTING
DOCUMENT_OUTPUT_INFO =
JOB_OUTPUT_INFO =
JOB_OUTPUT_OPTIONS =
TABLES
gr_mseg = itab2
EXCEPTIONS
formatting_error = 1
internal_error = 2
send_error = 3
user_canceled = 4
OTHERS = 5
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDLOOP.
ENDFORM. " GR_DISPLAY
FORM mat_display .
SELECT mblnr mjahr matnr werks lgort lifnr menge meins
erfmg bpmng ebeln ps_psp_pnr zeile lsmng erfme
mat_pspnr nplnr aufpl aplzl
FROM mseg
INTO CORRESPONDING FIELDS OF TABLE itab
WHERE mblnr IN mat_num.
LOOP AT itab.
SELECT ltxa1 FROM afvc INTO CORRESPONDING FIELDS OF itab1
WHERE aufpl = itab-aufpl AND aplzl = itab-aplzl.
itab-ltxa1 = itab1-ltxa1.
MODIFY itab TRANSPORTING ltxa1.
ENDSELECT.
REFRESH itab1.
SELECT ktext FROM aufk INTO CORRESPONDING FIELDS OF itab1
WHERE aufnr = itab-nplnr.
itab-ktext = itab1-ktext.
MODIFY itab TRANSPORTING ktext.
ENDSELECT.
REFRESH itab1.
SELECT pspnr psphi post1 INTO CORRESPONDING FIELDS OF itab1
FROM prps WHERE pspnr = itab-mat_pspnr.
itab-psphi = itab1-psphi.
itab-pspnr = itab1-pspnr.
itab-post2 = itab1-post1.
MODIFY itab TRANSPORTING psphi pspnr post2.
ENDSELECT.
SELECT post1 FROM proj INTO CORRESPONDING FIELDS OF itab2
WHERE pspnr = itab-psphi.
itab-post1 = itab2-post1.
MODIFY itab TRANSPORTING post1.
ENDSELECT.
REFRESH itab2.
SELECT maktx FROM makt INTO CORRESPONDING FIELDS OF itab2
WHERE matnr = itab-matnr.
itab-maktx = itab2-maktx.
MODIFY itab TRANSPORTING maktx.
ENDSELECT.
REFRESH itab2.
SELECT name1 ort01 FROM lfa1 INTO CORRESPONDING FIELDS OF itab2
WHERE lifnr = itab-lifnr.
itab-name1 = itab2-name1.
itab-ort01 = itab2-ort01.
MODIFY itab TRANSPORTING name1 ort01.
ENDSELECT.
REFRESH itab2.
SELECT budat bldat cpudt xblnr bktxt FROM mkpf
INTO CORRESPONDING FIELDS OF itab2
WHERE mblnr = itab-mblnr.
itab-budat = itab2-budat.
itab-bldat = itab2-bldat.
itab-cpudt = itab2-cpudt.
itab-xblnr = itab2-xblnr.
itab-bktxt = itab2-bktxt.
break developer1.
MODIFY itab TRANSPORTING budat bldat cpudt xblnr bktxt.
ENDSELECT.
ENDLOOP.
LOOP AT itab.
ON CHANGE OF itab-mblnr.
itab3-mblnr = itab-mblnr.
itab3-budat = itab-budat.
itab3-bldat = itab-bldat.
itab3-post1 = itab-post1.
itab3-ktext = itab-ktext.
APPEND itab3.
CLEAR itab3.
ENDON.
ENDLOOP.
LOOP AT itab3.
CLEAR: itab2, itab2[].
LOOP AT itab WHERE mblnr EQ itab3-mblnr.
MOVE-CORRESPONDING itab TO itab2.
APPEND itab2.
CLEAR itab2.
ENDLOOP.
CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
EXPORTING
formname = 'ZMM_MAT_ISSUE_SLIP'
VARIANT = ' '
DIRECT_CALL = ' '
IMPORTING
fm_name = fname
EXCEPTIONS
NO_FORM = 1
NO_FUNCTION_MODULE = 2
OTHERS = 3
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ls_control_param-no_dialog = 'X'.
*ls_control_param-preview = 'X'.
*ls_control_param-getotf = 'X'.
ls_otpt_opt-tdnoprev = 'X'.
ls_otpt_opt-tdnewid = ''.
ls_otpt_opt-tdimmed = 'X'.
ls_otpt_opt-tddest = 'LP01'.
CALL FUNCTION fname
EXPORTING
ARCHIVE_INDEX =
ARCHIVE_INDEX_TAB =
ARCHIVE_PARAMETERS =
control_parameters = ls_control_param
MAIL_APPL_OBJ =
MAIL_RECIPIENT =
MAIL_SENDER =
output_options = ls_otpt_opt
user_settings = 'X'
mat_slip_hdr = itab3
IMPORTING
DOCUMENT_OUTPUT_INFO =
JOB_OUTPUT_INFO = ls_job_info
JOB_OUTPUT_OPTIONS =
TABLES
mat_slip = itab2
EXCEPTIONS
FORMATTING_ERROR = 1
INTERNAL_ERROR = 2
SEND_ERROR = 3
USER_CANCELED = 4
OTHERS = 5
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDLOOP.
ENDFORM.Hello Saswat,
There are a couple of criteria to make a SmartForm report efficient, i.e. to achieve a better performance:
- provide the best possible interface to the temporary FM (fname). When you do so, SmartForm itself has not to perform so much programming stuff by itself.
- The Driver program (zgr_note) has to be designed and coded well. What mean the performance of the Driver has to be optimized. In your case there should be a couple of performance improvements:
-- adjust your program declaration to the new ABAP syntax, i.e. don't use OCCURS clauses and do not use HEADER LINE. Instead, implement TYPES and use them. Here is an example:
TYPES: BEGIN OF ty_itab.
INCLUDE STRUCTURE mseg.
TYPES: post1 LIKE proj-post1, "Project Definition
pspnr LIKE proj-pspnr, "WBS element
maktx LIKE makt-maktx, "Material Description
name1 LIKE lfa1-name1, "Name of the supplier
budat LIKE mkpf-budat, "Posting date
bldat LIKE mkpf-bldat, "Document date
cpudt LIKE mkpf-cpudt, "Date on which account document was entered
psphi LIKE prps-psphi, "Current number of project
post2 LIKE prps-post1, "WBS Definition
xblnr LIKE mkpf-xblnr, "Reference number( in this case challan number)
bktxt LIKE mkpf-bktxt, "Header text
ort01 LIKE lfa1-ort01, "vendor city
ktext LIKE aufk-ktext, "network description
ltxa1 LIKE afvc-ltxa1, "operation short text
END OF ty_itab.
* Declare your internal tables and the corresponding working structures
DATA: itab1 type standard table of ty_itab,
itab2 type standard table of ty_itab,
itab3 type standard table of ty_itab,
jtab type standard table of ty_itab,
wa_itab1 type ty_itab,
wa_itab2 type ty_itab,
wa_itab3 type ty_itab,
wa_jtab type ty_itab.
-- Don't use
LOOP at itab.
SELECT ...... WHERE pspnr = itab-ps_psp_pnr.
ENDSELECT.
SELECT * ...
ENDSELECT
SELECT * .....
ENDSELECT
ENDLOOP.
Instead try to populate itab, itab1, itab2 each in ONE select statement using FOR ALL ENTRIES clause. After that you have to perform the LOOP runs using LOOP at itab INTO wa_itab. The more redundant SELECTs, the slower the program! When you perform a LOOP run, let say over itab1 and you need a corresponding record from table itab2 the use READ <itab> with key.
One additional, very important hint: Using internal tables w/o header line the CLEAR statement has another functionality than with HEADER LINE
CLEAR with HEADER LINE clears the HEADER line only
CLEAR w/o HEADER LINE clears the entire table. CLEAR does the same as REFRESH.
Another performance improvement is (when itab contains a lot of records) using FIELD-SYMBOLS.
A simple example is
FIELD-SYMBOLS: <fs> type itab.
LOOP at itab assigning <fs>.
wa_itab3-post1 = <fs>-post1.
wa_itab3-post2 = <fs>-post2.
APPEND wa_itab3 to itab.
ENDLOOP.
In this case no data values have to be transfered to a working field. The values are taken directly from the current line of the internal table.
-- For better readability disign some events like START-OF-SELECTION, END-OF-SELECTION, INITIALIZATION and others.
Try to gather all in SmartForms needed fields and pop them into table itab3.
I hope this helps improving zgr_note's efficiency.
Good luck,
Heinz -
Brand New Machine and Photoshop CS6 running very slow
I just installed Photoshop CS6 on my new Machine and it is running horrible. Moving around objects, turning effects on/off, zooming, and more all take for ever to render. I can not figure out why. I have updated video card drivers and more. Scratch Disk is set to a second disk and messed with all of the GPU settings. Only photoshop runs bad on this machine. I should not be having issues with the system. Below is the system info from Photoshop. Also this machine is running with two SSD drives which should make PS run even faster.
Adobe Photoshop Version: 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00) x64
Operating System: Windows 7 64-bit
Version: 6.1 Service Pack 1
System architecture: Intel CPU Family:6, Model:13, Stepping:7 with MMX, SSE Integer, SSE FP, SSE2, SSE3, SSE4.1, SSE4.2, HyperThreading
Physical processor count: 12
Logical processor count: 24
Processor speed: 2294 MHz
Built-in memory: 16310 MB
Free memory: 11540 MB
Memory available to Photoshop: 14661 MB
Memory used by Photoshop: 70 %
Image tile size: 128K
Image cache levels: 4
OpenGL Drawing: Enabled.
OpenGL Drawing Mode: Advanced
OpenGL Allow Normal Mode: True.
OpenGL Allow Advanced Mode: True.
OpenGL Allow Old GPUs: Not Detected.
Video Card Vendor: ATI Technologies Inc.
Video Card Renderer: AMD FirePro V5900 (ATI FireGL)
Display: 3
Display Bounds:= top: -80, left: -1024, bottom: 1200, right: 0
Display: 2
Display Bounds:= top: 0, left: 1920, bottom: 1680, right: 2970
Display: 1
Display Bounds:= top: 0, left: 0, bottom: 1200, right: 1920
Video Card Number: 2
Video Card: AMD FirePro V5900 (ATI FireGL)
OpenCL Version:
Driver Version: 8.982.8.3000
Driver Date: 20120930000000.000000-000
Video Card Driver: aticfx64.dll,aticfx64.dll,aticfx64.dll,aticfx32,aticfx32,aticfx32,atiumd64.dll,atidxx64.d ll,atidxx64.dll,atiumdag,atidxx32,atidxx32,atiumdva,atiumd6a.cap,atitmm64.dll
Video Mode: 1680 x 1050 x 4294967296 colors
Video Card Caption: AMD FirePro V5900 (ATI FireGL)
Video Card Memory: 2048 MB
Video Rect Texture Size: 16384
Video Card Number: 1
Video Card: AMD FirePro V5900 (ATI FireGL)
OpenCL Version:
Driver Version: 8.982.8.3000
Driver Date: 20120930000000.000000-000
Video Card Driver: aticfx64.dll,aticfx64.dll,aticfx64.dll,aticfx32,aticfx32,aticfx32,atiumd64.dll,atidxx64.d ll,atidxx64.dll,atiumdag,atidxx32,atidxx32,atiumdva,atiumd6a.cap,atitmm64.dll
Video Mode: 1920 x 1200 x 4294967296 colors
Video Card Caption: AMD FirePro V5900 (ATI FireGL)
Video Card Memory: 2048 MB
Video Rect Texture Size: 16384
Serial number: 92938707758622115301
Application folder: C:\Program Files\Adobe\Adobe Photoshop CS6 (64 Bit)\
Temporary file path: C:\Users\JDONAL~1.RWS\AppData\Local\Temp\
Photoshop scratch has async I/O enabled
Scratch volume(s):
D:\, 237.9G, 229.4G free
Required Plug-ins folder: C:\Program Files\Adobe\Adobe Photoshop CS6 (64 Bit)\Required\
Primary Plug-ins folder: C:\Program Files\Adobe\Adobe Photoshop CS6 (64 Bit)\Plug-ins\
Additional Plug-ins folder: not set
Installed components:
A3DLIBS.dll A3DLIB Dynamic Link Library 9.2.0.112
ACE.dll ACE 2012/06/05-15:16:32 66.507768 66.507768
adbeape.dll Adobe APE 2012/01/25-10:04:55 66.1025012 66.1025012
AdobeLinguistic.dll Adobe Linguisitc Library 6.0.0
AdobeOwl.dll Adobe Owl 2012/06/26-12:17:19 4.0.95 66.510504
AdobePDFL.dll PDFL 2011/12/12-16:12:37 66.419471 66.419471
AdobePIP.dll Adobe Product Improvement Program 6.0.0.1654
AdobeXMP.dll Adobe XMP Core 2012/02/06-14:56:27 66.145661 66.145661
AdobeXMPFiles.dll Adobe XMP Files 2012/02/06-14:56:27 66.145661 66.145661
AdobeXMPScript.dll Adobe XMP Script 2012/02/06-14:56:27 66.145661 66.145661
adobe_caps.dll Adobe CAPS 6,0,29,0
AGM.dll AGM 2012/06/05-15:16:32 66.507768 66.507768
ahclient.dll AdobeHelp Dynamic Link Library 1,7,0,56
aif_core.dll AIF 3.0 62.490293
aif_ocl.dll AIF 3.0 62.490293
aif_ogl.dll AIF 3.0 62.490293
amtlib.dll AMTLib (64 Bit) 6.0.0.75 (BuildVersion: 6.0; BuildDate: Mon Jan 16 2012 18:00:00) 1.000000
ARE.dll ARE 2012/06/05-15:16:32 66.507768 66.507768
AXE8SharedExpat.dll AXE8SharedExpat 2011/12/16-15:10:49 66.26830 66.26830
AXEDOMCore.dll AXEDOMCore 2011/12/16-15:10:49 66.26830 66.26830
Bib.dll BIB 2012/06/05-15:16:32 66.507768 66.507768
BIBUtils.dll BIBUtils 2012/06/05-15:16:32 66.507768 66.507768
boost_date_time.dll DVA Product 6.0.0
boost_signals.dll DVA Product 6.0.0
boost_system.dll DVA Product 6.0.0
boost_threads.dll DVA Product 6.0.0
cg.dll NVIDIA Cg Runtime 3.0.00007
cgGL.dll NVIDIA Cg Runtime 3.0.00007
CIT.dll Adobe CIT 2.0.5.19287 2.0.5.19287
CoolType.dll CoolType 2012/06/05-15:16:32 66.507768 66.507768
data_flow.dll AIF 3.0 62.490293
dvaaudiodevice.dll DVA Product 6.0.0
dvacore.dll DVA Product 6.0.0
dvamarshal.dll DVA Product 6.0.0
dvamediatypes.dll DVA Product 6.0.0
dvaplayer.dll DVA Product 6.0.0
dvatransport.dll DVA Product 6.0.0
dvaunittesting.dll DVA Product 6.0.0
dynamiclink.dll DVA Product 6.0.0
ExtendScript.dll ExtendScript 2011/12/14-15:08:46 66.490082 66.490082
FileInfo.dll Adobe XMP FileInfo 2012/01/17-15:11:19 66.145433 66.145433
filter_graph.dll AIF 3.0 62.490293
hydra_filters.dll AIF 3.0 62.490293
icucnv40.dll International Components for Unicode 2011/11/15-16:30:22 Build gtlib_3.0.16615
icudt40.dll International Components for Unicode 2011/11/15-16:30:22 Build gtlib_3.0.16615
image_compiler.dll AIF 3.0 62.490293
image_flow.dll AIF 3.0 62.490293
image_runtime.dll AIF 3.0 62.490293
JP2KLib.dll JP2KLib 2011/12/12-16:12:37 66.236923 66.236923
libifcoremd.dll Intel(r) Visual Fortran Compiler 10.0 (Update A)
libmmd.dll Intel(r) C Compiler, Intel(r) C++ Compiler, Intel(r) Fortran Compiler 10.0
LogSession.dll LogSession 2.1.2.1640
mediacoreif.dll DVA Product 6.0.0
MPS.dll MPS 2012/02/03-10:33:13 66.495174 66.495174
msvcm80.dll Microsoft® Visual Studio® 2005 8.00.50727.6195
msvcm90.dll Microsoft® Visual Studio® 2008 9.00.30729.1
msvcp100.dll Microsoft® Visual Studio® 2010 10.00.40219.1
msvcp80.dll Microsoft® Visual Studio® 2005 8.00.50727.6195
msvcp90.dll Microsoft® Visual Studio® 2008 9.00.30729.1
msvcr100.dll Microsoft® Visual Studio® 2010 10.00.40219.1
msvcr80.dll Microsoft® Visual Studio® 2005 8.00.50727.6195
msvcr90.dll Microsoft® Visual Studio® 2008 9.00.30729.1
pdfsettings.dll Adobe PDFSettings 1.04
Photoshop.dll Adobe Photoshop CS6 CS6
Plugin.dll Adobe Photoshop CS6 CS6
PlugPlug.dll Adobe(R) CSXS PlugPlug Standard Dll (64 bit) 3.0.0.383
PSArt.dll Adobe Photoshop CS6 CS6
PSViews.dll Adobe Photoshop CS6 CS6
SCCore.dll ScCore 2011/12/14-15:08:46 66.490082 66.490082
ScriptUIFlex.dll ScriptUIFlex 2011/12/14-15:08:46 66.490082 66.490082
tbb.dll Intel(R) Threading Building Blocks for Windows 3, 0, 2010, 0406
tbbmalloc.dll Intel(R) Threading Building Blocks for Windows 3, 0, 2010, 0406
TfFontMgr.dll FontMgr 9.3.0.113
TfKernel.dll Kernel 9.3.0.113
TFKGEOM.dll Kernel Geom 9.3.0.113
TFUGEOM.dll Adobe, UGeom© 9.3.0.113
updaternotifications.dll Adobe Updater Notifications Library 6.0.0.24 (BuildVersion: 1.0; BuildDate: BUILDDATETIME) 6.0.0.24
WRServices.dll WRServices Friday January 27 2012 13:22:12 Build 0.17112 0.17112
wu3d.dll U3D Writer 9.3.0.113
Required plug-ins:
3D Studio 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Accented Edges 13.0
Adaptive Wide Angle 13.0
ADM 3.11x01
Angled Strokes 13.0
Average 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Bas Relief 13.0
BMP 13.0
Camera Raw 7.3
Chalk & Charcoal 13.0
Charcoal 13.0
Chrome 13.0
Cineon 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Clouds 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Collada 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Color Halftone 13.0
Colored Pencil 13.0
CompuServe GIF 13.0
Conté Crayon 13.0
Craquelure 13.0
Crop and Straighten Photos 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Crop and Straighten Photos Filter 13.0
Crosshatch 13.0
Crystallize 13.0
Cutout 13.0
Dark Strokes 13.0
De-Interlace 13.0
Dicom 13.0
Difference Clouds 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Diffuse Glow 13.0
Displace 13.0
Dry Brush 13.0
Eazel Acquire 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Embed Watermark 4.0
Entropy 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Extrude 13.0
FastCore Routines 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Fibers 13.0
Film Grain 13.0
Filter Gallery 13.0
Flash 3D 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Fresco 13.0
Glass 13.0
Glowing Edges 13.0
Google Earth 4 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Grain 13.0
Graphic Pen 13.0
Halftone Pattern 13.0
HDRMergeUI 13.0
IFF Format 13.0
Ink Outlines 13.0
JPEG 2000 13.0
Kurtosis 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Lens Blur 13.0
Lens Correction 13.0
Lens Flare 13.0
Liquify 13.0
Matlab Operation 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Maximum 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Mean 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Measurement Core 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Median 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Mezzotint 13.0
Minimum 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
MMXCore Routines 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Mosaic Tiles 13.0
Multiprocessor Support 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Neon Glow 13.0
Note Paper 13.0
NTSC Colors 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Ocean Ripple 13.0
Oil Paint 13.0
OpenEXR 13.0
Paint Daubs 13.0
Palette Knife 13.0
Patchwork 13.0
Paths to Illustrator 13.0
PCX 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Photocopy 13.0
Photoshop 3D Engine 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Picture Package Filter 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Pinch 13.0
Pixar 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Plaster 13.0
Plastic Wrap 13.0
PNG 13.0
Pointillize 13.0
Polar Coordinates 13.0
Portable Bit Map 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Poster Edges 13.0
Radial Blur 13.0
Radiance 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Range 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Read Watermark 4.0
Reticulation 13.0
Ripple 13.0
Rough Pastels 13.0
Save for Web 13.0
ScriptingSupport 13.0.1
Shear 13.0
Skewness 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Smart Blur 13.0
Smudge Stick 13.0
Solarize 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Spatter 13.0
Spherize 13.0
Sponge 13.0
Sprayed Strokes 13.0
Stained Glass 13.0
Stamp 13.0
Standard Deviation 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Sumi-e 13.0
Summation 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Targa 13.0
Texturizer 13.0
Tiles 13.0
Torn Edges 13.0
Twirl 13.0
U3D 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Underpainting 13.0
Vanishing Point 13.0
Variance 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Variations 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Water Paper 13.0
Watercolor 13.0
Wave 13.0
Wavefront|OBJ 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
WIA Support 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
Wind 13.0
Wireless Bitmap 13.0.1 (13.0.1 20120808.r.519 2012/08/08:21:00:00)
ZigZag 13.0
Optional and third party plug-ins: NONE
Plug-ins that failed to load: NONE
Flash:
Mini Bridge
Extensis
Kuler
Installed TWAIN devices: NONEMy Old System was:
Dell T5500
GPU1: ATI FirePro 5700
GPU2: Nvidia Geforce 210
CPU1:Xeon E5520 2.26Ghz
CPU2: Xeon E5520 2.26Ghz
C Drive: 80gb Sata 10K RPM
D Drive/Scratch Disk: 80gb Sata 10K RPM
Photoshop CS6 was set at default performance setting with the exception of the D drive being used for the scratch disk. GPU Processor was checked.
Worked on numerous large files 100 mg plus with little to no issue. Most setup in CMYK, 200 dpi, 8 bit depth.
New Machine:
Dell T5600
Two ATI FirePro V5900
CPU1: Xeon E5-2630
CPU2: Xeon E5-2630
C Drive: 240 gb SSD
D Drive:
My Old System was:
Dell T5500
GPU1: ATI FirePro 5700
GPU2: Nvidia Geforce 210
CPU1:Xeon E5520 2.26Ghz
CPU2: Xeon E5520 2.26Ghz
C Drive: 80gb Sata 10K RPM
D Drive/Scratch Disk: 80gb Sata 10K RPM
Photoshop CS6 was set at default performance setting with the exception of the D drive being used for the scratch disk. GPU Processor was checked.
Worked on numerous large files 100 mg plus with little to no issue. Most setup in CMYK, 200 dpi, 8 bit depth.
New Machine:
Dell T5600
Two ATI FirePro V5900
CPU1: Xeon E5-2630
CPU2: Xeon E5-2630
C Drive: 240 gb SSD
D Drive: 240gb SSD
Tried Photoshop at all sorts of various settings including default. All with the D drive being used for the Scratch disk. Working on the similar size file described above. The file I am working on now is 4000 x 4800 pixels, CMYK, 8 bit depth. Photoshop is slow selecting layers with auto select, very slow when moving layers around the Canvas, and slow rendering the Canvas when zooming in and out. This document also has about 30 layers and is 80mg.
I only use the 64 bit version of Photoshop these days. Also all three monitors are set at 60 Hertz. Photoshop is closed and reopened upon all changes.
I use to be a Photoshop Certified Expert in CS3 so I am extremely familar with the product. I am just stumped. -
This is a spin off from another thread which started off as slow inserts. But what actaully happens is every insert is preceded by select it turned out that the select was slow.
We have a multi-tier web application conencting to the DB using connection pool and inserting about a 100000 records in a table. To isolate the issue I wrote a PL/SQL which does the same thing.
This problem happens every time the schema is recreated or the table dropped and created again and we start inserting. When the table is empty, the selects choose a full table scan but as the records are inserted it continues to use the same even though after a few thousands of rows I run stats. But as its running if gather stats and flush the shared pool, it picks up the new plan using the indexes and immediately gets faster.
But in either case, full tablescan being slow after a few thousands of rows or using the index and getting much faster. Or me just doing the same select and no inserts on a table with 100000 rows, the CPU seems to be pegged to the core.
The code snipped repeated again
DECLARE
uname NVARCHAR2 (60);
primid NVARCHAR2 (60);
num NUMBER;
BEGIN
FOR i IN 1 .. 100000
LOOP
uname := DBMS_RANDOM.STRING ('x', 20);
primid := DBMS_RANDOM.STRING ('x', 30);
DBMS_OUTPUT.put_line (uname || ' ==> ' || primid);
SELECT COUNT (*)
INTO num
FROM TEST
WHERE ID = 0
AND (primid = primid OR UPPER (username) = uname OR uiname = uname
AND (deldate IS NULL)
ORDER BY TIME DESC;
INSERT INTO TEST
VALUES (0, uname, uname, 1, uname, primid);
IF MOD (i, 200) = 0
THEN
COMMIT;
DBMS_OUTPUT.put_line ('Commited');
END IF;
END LOOP;
END;This is the original thread
Re: Slow insertsMaybe if you post the actual code, or a code as similar to the actual code, the users of this forum may provide you with more appropriate suggestions.
Personally, I would like to understand what is the logic behind, so I can provide you with better advices.
Anyway, let's focus on the code that we currently have on the table.
Why your CPU goes high?
- Huge amount of LIOs produced by SELECT statement which is executed 100000 times.
- Usage of single-row / aggregate functions
- You mentioned you have some indexes created on table TEST. Index maintenance consumes some CPU as well.
Let's focus on the SELECT statement, since it is the most important reason for having high number of LIOs thus having high CPU usage.
I built a test case using the query you provided, with one difference, I named TEST table columns as COL1, COL2, etc. And instead of 100,000 cycles, I did 10,000
declare
uname varchar2(60);
pname varchar2(60);
num number(5);
begin
for i in 1..10000 loop
uname:=dbms_random.string('x',30);
pname:=dbms_random.string('x',20);
select count(1)
into num
from test
where col1=0
and (col2=uname or upper(col5)=pname or col3=uname)
and col4 is not null;
insert into test
values (0,uname,pname,1,uname,uname);
if mod(i,200)=0 then
commit;
end if;
end loop;
end;When I run 10046 trace and made tkprof report, I got the following for the SELECT part:
SELECT COUNT(1)
FROM
TEST WHERE COL1=0 AND (COL2=:B1 OR UPPER(COL5)=:B2 OR COL3=:B1 ) AND COL4 IS
NOT NULL
call count cpu elapsed disk query current rows
Parse 2 0.00 0.00 0 0 0 0
Execute 10050 0.48 0.43 0 0 50 0
Fetch 10000 94.07 94.37 0 2910664 2 10000
total 20052 94.56 94.80 0 2910664 52 10000As you can see, tkprof report indicated high CPU usage and 2,910,664 LIO calls.
The execution plan (I didn't include that part) indicated FULL TABLE scan on table TEST was used.
At this point the goal should be to reduce the number of LIO calls.
For this purpose I created the following indexes:
TEST_IDX1 on TEST(col2)
TEST_IDX2 on TEST(col3)
TEST_IDX3 on TEST(upper(col5)) - a Function Based Index
Let's forget about the statistics at this moment.
I will use index_combine hint in the SELECT statement to make CBO to try every index combination for listed indexes (B-Tree) and make bitmap conversion.
The new code looks like this
declare
uname varchar2(60);
pname varchar2(60);
num number(5);
begin
for i in 1..10000 loop
uname:=dbms_random.string('x',30);
pname:=dbms_random.string('x',20);
select /*+ index_combine(test test_idx1 test_idx2 test_idx3) */ count(1)
into num
from test
where col1=0
and (col2=uname or upper(col5)=pname or col3=uname)
and col4 is not null;
insert into test
values (0,uname,pname,1,uname,uname);
if mod(i,200)=0 then
commit;
end if;
end loop;
end;After running 10046 trace and creating tkprof report, I got the following result:
SELECT /*+ index_combine(test test_idx1 test_idx2 test_idx3) */ COUNT(1)
FROM
TEST WHERE COL1=0 AND (COL2=:B1 OR UPPER(COL5)=:B2 OR COL3=:B1 ) AND COL4 IS
NOT NULL
call count cpu elapsed disk query current rows
Parse 1 0.00 0.00 0 0 0 0
Execute 10000 0.79 0.70 0 0 0 0
Fetch 10000 0.68 0.71 3 59884 0 10000
total 20001 1.47 1.42 3 59884 0 10000
Misses in library cache during parse: 1
Misses in library cache during execute: 1
Optimizer mode: ALL_ROWS
Parsing user id: 54 (recursive depth: 1)
Rows Row Source Operation
10000 SORT AGGREGATE (cr=59884 pr=3 pw=0 time=1188641 us)
0 TABLE ACCESS BY INDEX ROWID TEST (cr=59884 pr=3 pw=0 time=1012723 us)
0 BITMAP CONVERSION TO ROWIDS (cr=59884 pr=3 pw=0 time=915796 us)
0 BITMAP OR (cr=59884 pr=3 pw=0 time=820728 us)
0 BITMAP CONVERSION FROM ROWIDS (cr=20039 pr=1 pw=0 time=258455 us)
0 INDEX RANGE SCAN TEST_IDX1 (cr=20039 pr=1 pw=0 time=157107 us)(object id 52988)
0 BITMAP CONVERSION FROM ROWIDS (cr=19902 pr=1 pw=0 time=198466 us)
0 INDEX RANGE SCAN TEST_IDX2 (cr=19902 pr=1 pw=0 time=109999 us)(object id 52989)
0 BITMAP CONVERSION FROM ROWIDS (cr=19943 pr=1 pw=0 time=198730 us)
0 INDEX RANGE SCAN TEST_IDX3 (cr=19943 pr=1 pw=0 time=107200 us)(object id 52990)As you can see the number of LIO calls fallen dramatically. Also CPU time is significantly less.
The second code completed in few seconds compared to the previous one which needed about 100 seconds to complete.
Please be aware that this is just an example of tuning the code that you provided.
This solution might not be suitable for your actual code, since we don't have any information about it. That's why it is important to give us as much information as you could, so you can get the most appropriate answer.
If the test code is similar to the actual one, you should focus on reducing LIOs calls.
In order to achieve it, you may want to use hints to force an index to be used.
Cheers,
Mihajlo
Maybe you are looking for
-
Short dumop in J2I5 (provide duplicate entry in Standard table)
Hello Expert , We have a problem in T.Code J2I5 ( Excise Register Extraction) input entry is lelect Excise group 20 . and a date from 04.08.09 onwards. and select the register RG23D . it shows the run time error ( Eg Th
-
We've recently had some security consultants go through our environment and the report they've provided has advised that some high priority upgrades are required on our NetWare servers around the Apache versions. We are running NW65sp7, and the repor
-
Hi All I have a custom ODS with the following : <b>Key</b> Material Plant Cal Month <b>Data</b> Company code Fiscal year period Fiscal year variant PTS (Price to stockist) - Key figure Brand Distribution channel Division I have defined this key figur
-
Link to August PDK newsletter is broken
See page http://portalstudio.oracle.com/servlet/page?_pageid=356&_dad=ops&_schema=OPSTUDIO when you click on the August newsletter link, all you get is: Error: document not found.
-
Dear all, Enabled action menu using form personalization for launching reports , when user clicks on Actions-->ReportName it is throwing error --> "Function not available to this responsibility, change the responsibility or contact the system adminis