Database Performace Report
Hi
We are having many Oracle 10.2.0.3 instances on Unix and Windows .
We donot have Enterprise Manager configured and we donot have licence for the diagnostic packs.
Requirement : My manager wants a Graphical Report for each database intance showing its performace details . He needs the reports monthly .*
I tried to convince him by generating AWR reports , however he said he is not satistisfied with it because its too technical . He needs something in a graphical format or a presentation format where a non technical person can easily understand some things like :
1) When was peak load on the database
2) Which Application was using most resources
3) Which Table/Object was most queried
4) Statistics in regards to Disk/Network/CPU
Actually the report should be similar or a kind of Oracle EM dbcontrol's Persormace Tab where we can see all the graphs at any point of time .
I have to create a dynamic report every month with the details mentioned above for any point of Time with in the last one month.
The resulting report can be in Excel or PPT
Any pointers or Templates to get the result is highly appreciated .
Thanks
Ok, I have simulated your problem and I fixed it:
1- Download the ojdbc14.jar file from this link: http://www.oracle.com/technetwork/database/enterprise-edition/jdbc-10201-088211.html
2- In the run.sh file change the content like belows:
#!/bin/ksh
# Licensed to the GNU GENERAL PUBLIC LICENSE Version 3
# ASH Viewer start up batch script
# Required ENV vars:
# JAVA_HOME - location of a JDK home dir
export JAVA_HOME=/usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64
export CLASSPATH=/home/oracle/ashv-3.4-bin/lib
export JAVA_EXE=$JAVA_HOME/bin/java
$JAVA_EXE -cp /home/oracle/ashv-3.4-bin/lib -Xmx128m -jar ASHV.jar
~ Don't forget to change to your JAVA_HOME, in my case my JAVA_HOME is /usr/lib/jvm/java-1.6.0-openjdk-1.6.0.0.x86_64
3- don't forget to run the following command in order to convert the file in Linux:
dos2unix run.sh
4- Change the permission so the run.sh become executable
5- Make sure the Oracle system user has the privilege to execute and access the ashv-3.4-bin folder
6- run ./run.sh
and you will get the graphs and the screens
Hope it helps,
Wissem
Edited by: orawiss on Apr 9, 2011 3:12 PM
Similar Messages
-
Auto-Generate mail for database performace reporting.
Hello,
i have many server to keep an eye on for maintenance but, now the number for it is growing day by day. Its difficult for me to keep a watch on each in detail. So I have an idea to implement.
I want to make a script which will auto generate a mail from the server & send it to my email id with all the details of database. Basically performance related details.+
Is it possible to do so ???? I know how to send a mail with attachment, the code i will use is given below.+
please suggest me how can i attach my performance tuning queries output & get those things in my mail on a daily basis......
thanks in advance .....
DECLARE
v_From VARCHAR2(80) := '[email protected]';
v_Recipient VARCHAR2(80) := '[email protected]';
v_Subject VARCHAR2(80) := 'test subject';
v_Mail_Host VARCHAR2(30) := 'mail.mycompany.com';
v_Mail_Conn utl_smtp.Connection;
crlf VARCHAR2(2) := chr(13)||chr(10);
BEGIN
v_Mail_Conn := utl_smtp.Open_Connection(v_Mail_Host, 25);
utl_smtp.Helo(v_Mail_Conn, v_Mail_Host);
utl_smtp.Mail(v_Mail_Conn, v_From);
utl_smtp.Rcpt(v_Mail_Conn, v_Recipient);
utl_smtp.Data(v_Mail_Conn,
'Date: ' || to_char(sysdate, 'Dy, DD Mon YYYY hh24:mi:ss') || crlf ||
'From: ' || v_From || crlf ||
'Subject: '|| v_Subject || crlf ||
'To: ' || v_Recipient || crlf ||
'MIME-Version: 1.0'|| crlf || -- Use MIME mail standard
'Content-Type: multipart/mixed;'|| crlf ||
' boundary="-----SECBOUND"'|| crlf ||
crlf ||
'-------SECBOUND'|| crlf ||
'Content-Type: text/plain;'|| crlf ||
'Content-Transfer_Encoding: 7bit'|| crlf ||
crlf ||
'some message text'|| crlf || -- Message body
'more message text'|| crlf ||
crlf ||
'-------SECBOUND'|| crlf ||
'Content-Type: text/plain;'|| crlf ||
' name="excel.csv"'|| crlf ||
'Content-Transfer_Encoding: 8bit'|| crlf ||
'Content-Disposition: attachment;'|| crlf ||
' filename="excel.csv"'|| crlf ||
crlf ||
'CSV,file,attachement'|| crlf || -- Content of attachment
crlf ||
'-------SECBOUND--' -- End MIME mail
utl_smtp.Quit(v_mail_conn);
EXCEPTION
WHEN utl_smtp.Transient_Error OR utl_smtp.Permanent_Error then
raise_application_error(-20000, 'Unable to send mail: '||sqlerrm);
END;
/I like your script idea.
You can spool output to a file and mail the file to yourself.
What OS are you running?
On linux a simple starter script would look like this:
#!/bin/bash
echo `date`
# Set the Environmental variable for TESTDB instance
. /u01/app/oracle/dba_tool/env/TESTDB.env
$ORACLE_HOME/bin/sqlplus -s system/<PASSWORD> <<EOF
@/u01/app/oracle/dba_tool/TESTDB/quickaudit
EOF
echo `date`
mailx -s "Check database on TESTDB" [email protected] < /tmp/quickaudit.lst
----------------------sample ENV file--------------------------------------
ORACLE_BASE=/u01/app/oracle
ULIMIT=unlimited
ORACLE_SID=TESTDB
export ORACLE_TERM=xterm
ORACLE_HOME=$ORACLE_BASE/product/11.2.0
ORA_NLS33=$ORACLE_HOME/ocommon/nls/admin/data
LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib
LIBPATH=$LD_LIBRARY_PATH:/usr/lib
TNS_ADMIN=$ORACLE_HOME/network/admin
PATH=$ORACLE_HOME/bin:$ORACLE_BASE/dba_tool/bin:/bin:/usr/bin:/usr/ccs/bin:/etc:/usr/sbin:/usr/ucb:$HOME/bin:/usr/bin/X11:/sbin:/usr/lbin:/GNU/bin/make:/u01/app/oracle/dba_tool/bin:/home/oracle/utils/SCRIPTS:/usr/local/bin:
export ORACLE_BASE ORACLE_SID ORACLE_TERM ULIMIT
export ORACLE_HOME
export LIBPATH LD_LIBRARY_PATH ORA_NLS33
export TNS_ADMIN
export PATH
--------------------Starter reporting script--------------------------------------------------
SET ECHO OFF
SET TERMOUT OFF
REM Revisions:
REM Date ID Version Description
REM -------- -- ------- ----------------------------------------------------|
REM 10/07/05 1.0 Script to check for database issues
SPOOL /tmp/quickaudit.lst
SELECT SYSDATE FROM DUAL;
SHOW USER
SET TERMOUT ON
SET VERIFY OFF
SET FEEDBACK ON
PROMPT
PROMPT Checking database name and archive mode
PROMPT
column NAME format A9
column LOG_MODE format A12
SELECT NAME,CREATED, LOG_MODE FROM V$DATABASE;
PROMPT
PROMPT ------------------------------------------------------------------------|
PROMPT
PROMPT
PROMPT Checking database versions
PROMPT
column BANNER format A64
select * from v$version;
PROMPT
PROMPT ------------------------------------------------------------------------|
PROMPT
PROMPT
PROMPT Checking control file(s)
PROMPT
column STATUS format a7
column NAME format a68
column IS_RECOVERY_DEST_FILE format a3
set linesize 110
SELECT * FROM V$CONTROLFILE;
PROMPT
PROMPT ------------------------------------------------------------------------|
PROMPT
PROMPT
PROMPT Checking redo logs and group(s)
PROMPT
column member format a70
set linesize 110
set pagesize 30
SELECT group#, member FROM v$logfile;
PROMPT
PROMPT -----------------------------------------------------------------------|
PROMPT
PROMPT
PROMPT ------------------------------------------------------------------------|
PROMPT
PROMPT
PROMPT Checking freespace by tablespace
PROMPT
column dummy noprint
column pct_used format 999.9 heading "%|Used"
column name format a16 heading "Tablespace Name"
column bytes format 9,999,999,999,999 heading "Total Bytes"
column used format 99,999,999,999 heading "Used"
column free format 999,999,999,999 heading "Free"
break on report
compute sum of bytes on report
compute sum of free on report
compute sum of used on report
set termout off
set pagesize 40
select a.tablespace_name name,
b.tablespace_name dummy,
sum(b.bytes)/count( distinct a.file_id||'.'||a.block_id ) bytes,
sum(b.bytes)/count( distinct a.file_id||'.'||a.block_id ) -
sum(a.bytes)/count( distinct b.file_id ) used,
sum(a.bytes)/count( distinct b.file_id ) free,
100 * ( (sum(b.bytes)/count( distinct a.file_id||'.'||a.block_id )) -
(sum(a.bytes)/count( distinct b.file_id ) )) /
(sum(b.bytes)/count( distinct a.file_id||'.'||a.block_id )) pct_used
from sys.dba_free_space a, sys.dba_data_files b
where a.tablespace_name = b.tablespace_name
group by a.tablespace_name, b.tablespace_name;
PROMPT
PROMPT ------------------------------------------------------------------------|
PROMPT
PROMPT
PROMPT Checking for invalid objects
PROMPT -
How to hide some select-option of Logical Database in report?
How to hide select-option of Logical Database in report?eg . In Logical Database 'PNP' , my code is 'GET PERNR' , excute the report , select-screen is displayed . I want to hide some select-options , such as PNPPERNR-LOW .
Edited by: rongrong wang on Mar 26, 2008 9:31 AMU need to write code in initialization as
initialization.
loop at screen.
if screen-name = 'PNPPERNR-LOW'.
screen-active = '0'.
modify screen.
endif.
if screen-name = 'PNPPERNR-HIGH'.
screen-active = '0'.
modify screen.
endif.
endloop. -
Database Status report.
Hi Export,
Currently i joined a company as a Oracle Dba. i am new to DBA world, My manager told me to prepare a database status report. Please suggest me how can i create the report.
Regards...
AsmitEdStevens wrote:
marksmithusa wrote:
That's an awesome idea - just one problem.
If it's tall enough for all to see, this also includes management and if they notice the chicken, your cube will be instantly surrounded by various management types asking 'when will it be back up?'
You're, almost literally, hoisting yourself with your own petard.True, but I think he had the understanding with mgmt that if the chicken was up, they'd best leave him alone until the chicken came down.Wow. I'm actually stunned - I didn't think that was possible within the physical laws of the universe that we occupy.
He achieved 'DBA Hero' status. -
Unable to create Database in Reporting Service Configuration
Hi,
We have SQL Server 2012 in our environment. I want to enable monitor report in Lync 2013. i have separate Lync sql instance.
I am trying to configure new database in Reporting Service Configuration manager in report Server database Configuration wizard.
while testing connection getting below error.
could not connect to server:A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to
allow remote connections.(provider:Named Pipes provider,error:40-could not open a connection to SQL Server)
kindly help to resolve issue.Hi Rakesh,
Please check the below details information:
Check the ReportServer db is present in the Database engine.
Go and check the report server configurations (go here:Start -> All Programs -> Microsoft sql server 2012-> Configuration Tools -> Report Service Configuration Manager
check all the connections if still not working. then create a new reporting services Database. While creating it make sure you select native mode, if you want to create a share point services then select share point integration mode.
If the above didn't work, Please check which port is used for SQL Server database engine from SQL Server Configuration Manager.
If we are using dynamic port, please make sure:
SQL Server Browser service is running.
UDP 1434 port is enabled in the firewall.
If we are using static port, please make sure the port is enabled in the firewall.
Below is useful link about how to troubleshoot connection issue:
http://blogs.msdn.com/sql_protocols/archive/2005/12/22/506607.aspx
https://msdn.microsoft.com/en-us/library/ms156468.aspx?f=255&MSPPError=-2147217396
Similar thread for your reference:
http://www.mssqltips.com/sqlservertip/2340/resolving-could-not-open-a-connection-to-sql-server-errors/
If you have any more questions, please feel free to ask.
Regards,
Vicky Liu
Vicky Liu
TechNet Community Support -
ISSUE Sharepoint 2013 databases for reporting services on the second server SQL 2012
Hello,
I have server A: Operating system windows 2012 standard, SQL server 2012 standard
instance: Sharepoint contains data for sharepint
instance: Reporting should be contain databases for reporting
Server B:
Windows server 2012 standard contains installation Sharepoint 2013
Sharepoint works (without reporting services), it is OK - databases are located on server A:
My issue is:
When I have installed reporting services on server B, I have already installed SQL server 2012 on server B, it works.
I am able to create report in report builder adn place it in to sharepoint.
But I would like to use only one full SQL machine on server A:
When I reconfigure repoting settings on server A in central administration - manage service aplications,
On the SQL server A in instance reporting , there is automatically created databases. It is no problem.
But the first difference is, when I want to manage service aplication for reporting in
Provision Subscriptions and Alerts, there is information
SQL Server Agent state cannot be determined
When I want to create report in report builder, I have issue:
server A-7380mw016\reporting it means server A with full SQL server:
The Test of connection was successful
Then I have clicked test connection
I have recieved this screen with fail: Logon faild for user NT Authority\anonymous logon
My account belongs to SQL admin on server A (A-7380mw016\reporting) I do not know it is not possible to create report, when it is possible to test connection in the first step and in the second step, there is problem...
Please, can somebody help me?Hi,
Since you are getting an Anonymous Logon error, it appears there may be a problem passing your credentials to the SQL Server Agent Service. This would indicate a Kerberos issue. See this thread for details:
http://social.technet.microsoft.com/Forums/sharepoint/en-US/46b7c773-6a77-435d-b471-cb9a6ec41c43/has-anyone-else-upgraded-reporting-services-to-denali-2012
Microsoft Virtual Academy: Breakthrough Insights using SQL Server 2012 : Analysis Services and Credible, Consistent data (Module 2) - Configuring and Securing Complex BI Applications in a SharePoint 2010 Environment with Microsoft SQL Server 2012
http://technet.microsoft.com/en-us/video/Video/hh858469
Tips from the video:
We are connecting to Reporting services using Kerberos when using Reporting Services in SharePoint integrated mode
For the account using reporting services, we just need a dummy SPN. We go to Attribute editor tab in AD for RS account. And then we will be enabled with Delegation tab.
In Delegation tab. I we are using claims to windows token, we need to use "Trust this user for delegation to specified services only"
There you have 2 options: "Use Kerberos only": It means I only want to delegate in the situation where the service that is doing the delegation actually has the Kerberos ticket to start with
"Use any authentication protocol" When we need protocol transition (like from NTLM to claims for intra farm communication)
We need to delegate this to SQL server.
Please check out these articles as well:
How to configure SQL Reporting Services in SharePoint Server for Kerberos authentication
http://support.microsoft.com/kb/2723587
Configure Kerberos authentication (Office SharePoint Server)
http://blogs.technet.com/b/mbiswas/archive/2009/07/10/configure-kerberos-authentication-office-sharepoint-server.aspx
Thanks.
Tracy Cai
TechNet Community Support -
The error below makes absolutely no sense! I'm using Enterprise Core...yet I'm being told I can't use remote data sources:
w3wp!library!8!03/05/2015-19:08:48:: i INFO: Catalog SQL Server Edition = EnterpriseCore
w3wp!library!8!03/05/2015-19:08:48:: e ERROR: Throwing Microsoft.ReportingServices.Diagnostics.Utilities.OperationNotSupportedException: , Microsoft.ReportingServices.Diagnostics.Utilities.OperationNotSupportedException: The feature: "The edition of Reporting
Services that you are using requires that you use local SQL Server relational databases for report data sources and the report server database." is not supported in this edition of Reporting Services.;
Really? This totally contradicts the documentation found here:
https://msdn.microsoft.com/en-us/library/ms157285(v=sql.110).aspx
That article says remote connections are completely supported.
ARGH! Why does this have to be so difficult to setup?!?Hi jeffoliver1000,
According to your description, you are using Enterprise Core edition and you are prompted that you can’t use remote data sources.
In your scenario, we neither ignore your point nor be doubt with what you say. But actually we have met the case before that even though the SQL Server engine is Enterprise but the reporting services is still standard. So I would recommend you to find the
actual edition of reporting services you are using. You can find Reporting Services starting SKU in the Reporting Service logs ( default location: C:\Program Files\Microsoft SQL Server\<instance name>\Reporting Services\LogFiles). For more information,
please refer to the similar thread below:
https://social.technet.microsoft.com/Forums/en-US/f98c2f3e-1a30-4993-ab41-acbc5014f92e/data-driven-subscription-button-not-displayed?forum=sqlreportingservices
By the way, have you installed the other SQL Server edition before?
Best regards,
Qiuyun Yu
Qiuyun Yu
TechNet Community Support -
I have been using the database dependencies report to remove tables from my database. If I don't see that they have a dependency in that report, is that good enough to know I can delete them from the database?
For example: I have a lookup table in SQL WORKSHOP > OBJECT BROWSER > TABLES called CATEGORY_LKP that was used in the database at some point in the past. When I run the Database Dependencies Report under the UTILITIES tab of the application, that table does not show up as having any dependencies.
I am assuming this means it is safe to delete it, but is there another way to make sure it is not referenced by any tables or List of Values or anything? Just curious as I am on a roll to getting a very ugly database structure under control and don't want to lose momentum
Thanks
WallyDo you have any non-APEX code in the database? If so, check the relevant *_DEPENDENCIES data dictionary view(s) as well.
-
Hi,
Pls advice me to how to get 'Database Configuration Report' on oracle 10g
Thank,
JagathJagath,
Can you elobrate what exactly you mean Database Configuration Report? Are you looking to find out existing database configuration and more? Or you mean Database configuration assistant? You can use AWR report by running awrrpt.sql and at the end of report you can find detailed configuration report if that's what you after
sqlplus '/as sysdba'
sql> $ORACLE_HOME/rdbms/admin/awrrpt.sqlRegards
OrionNet -
Hi,
I am working on Oracle 10.2.0.4 and HP-UX .
i need to prepare one report showing database health on weekly basis for management .
This report can contain performance overview ..bottleneck ..high and low peeks etc..
This will be good if all data showing here will be in GUI , Graph format ..so easy to understand..
we have this type of templates available to create report..?
How to get data in report..?
Any idea..Hi,
Database Health report can be obtain from my below link:
http://rafioracledba.blogspot.com/search/label/DBA%20Daily%20activities
It is a detailed one.Make use of point 20 in the above link to get the report you want.Hope it helps.
Best regards,
Rafi.
http://rafioracledba.blogspot.com -
hello i'm running on my database 10g r2 with autotuning a database contention report with the following result
CLASS TOTAL_WAITS TOTAL_TIME
free list 0 0
extent map 0 0
system undo block 0 0
sort block 0 0
segment header 1 0
bitmap index block 0 0
unused 0 0
system undo header 0 0
bitmap block 0 0
save undo block 0 0
data block 15535 4889
save undo header 0 0
1st level bmb 0 0
2nd level bmb 0 0
3rd level bmb 0 0
undo block 229 0
undo header 2498 174
file header block 1 0
what parameters should i focus to tune the database?
thanks in advance
nickYou need to put these figures into context - is the time spent on these waits significant compared to the snapshot interval and the rest of the time spent in the database.
Post an extract from a statspack report (or AWR report if you are licensed for it) showing the "Top 5 Timed Events", and the "Buffer Wait Statistics" from a busy period, and then we might be able to offer some sensible advice.
PS - before posting any of the report, check how to use the "code" tags (in curly brackets) to get the output into: fixed fontRegards
Jonathan Lewis
http://jonathanlewis.wordpress.com
http://www.jlcomp.demon.co.uk
"The temptation to form premature theories upon insufficient data is the bane of our profession."
Sherlock Holmes (Sir Arthur Conan Doyle) in "The Valley of Fear". -
hi all
how to take a oracle 9i database helth report through enterprice manager console
regards
BuddhikeHi buddhike ,
If you want to use OEM then it is graphical tool and there is "Health Check " tab present in the main menu (left hand side oredered vertically) if i am not wrong. since you are using Linux environment you can use statspack report for performnace (schedule it as per the application/business requirements) for tablespace usage and hard disk usage better to use scripts and if you need can schedule it in cron jobs !!!!!! (you can get it in your email as per threshold you have set crossed.)
Thanks
-- Raman -
Hi
What does "database grow report" means and how it is possible to be collected?
Thanks
Jonny ...this report will tell you how your database is growing?
generally we will take database size and tablespace sizes in this report on a timely basis (this time could be week, month or quarter)
by comparing this report will previous one, we will get to know how fast db is growing and accordingly we can plan the space to be added.
the following script will be helpful
http://pavandba.wordpress.com/2009/10/24/db-growth-between-two-periods/ -
How to make use of logical database in reports?
hi,
I am working on a Cash Flow Forecast report, which requires the usage of 'PSJ' Logical Database for the selection screen with Profit Center(PRCTR) as one field and the other field being Period ( in MM/YYYY format).
I have not worked on Logical Database before. Since, its for the first time I am working on LDB, I require help on it.
How to proceed for this, can someone help me with it?
On receiving further inputs, I will proceed and might come up with some more queries.
Regards,
RaviHi Hari,
Thanks a lot for being so patient. yeah, I will just send you a code snippet of mine. My code is of 3000 Lines. Hence, I will send few parts of it. Just go through and let me know if you need any further information from my side.
Here is the snippet:
*& TABLES
TABLES: PROJ, "Project definition.
PRPS, "WBS Element Master Data
COSP, "CO: External Table.
COFP, "CO: External Table.
SETLEAF, "Value in sets.
FAGLFLEXT, "Profit Center.
S031, "Statistics: Movements for Current Stocks.
SETHEADERT, "short Description of Sets.
AFVC, "Operation within an Order.
AUFK, "Order master data.
PRHI, "Work Breakdown Structure.
AFKO, "Order header data PP orders.
NRIV, "Number range Intervals.
SKB1, "G/L Account Master (company code).
FMCI. "Commitments Item master data.
Type Pool
TYPE-POOLS: SLIS.
FIELD-SYMBOLS: <DYN_TABLE> TYPE STANDARD TABLE,
<DYN_WA>,
<DYN_FIELD>.
DATA: COUNT TYPE I,
D_PERIOL LIKE COFP-PERIO,
D_PERIOH LIKE COFP-PERIO,
D_GJAHRL LIKE COFP-GJAHR,
D_GJAHRH LIKE COFP-GJAHR,
D_GJAHR LIKE COFP-GJAHR,
D_PERIO LIKE COFP-PERIO,
OBJNR LIKE COSP-OBJNR,
PKOKR LIKE PRPS-PKOKR,
G_NRLEVEL LIKE NRIV-NRLEVEL,
G_BELNR LIKE COFP-BELNR,
I_OBJ-OBJNR LIKE COFP-OBJNR,
G_OPNGBAL LIKE FAGLFLEXT-HSL01,
G_PAYROLL LIKE COSP-WKG001,
G_PYROL_TAX LIKE COFP-WKGBTR,
G_PENSION LIKE COFP-WKGBTR,
G_BTLDGR LIKE COFP-WKGBTR,
G_REIMPYMT LIKE COFP-WKGBTR,
G_INTCORCPT LIKE COFP-WKGBTR,
G_CAPEXP LIKE COFP-WKGBTR,
G_SLSLDGR LIKE COFP-WKGBTR,
G_REIMRCPT LIKE COFP-WKGBTR,
G_TOTPYMNTS LIKE COFP-WKGBTR VALUE 0,
G_TOTRECPTS LIKE COFP-WKGBTR VALUE 0,
G_MVMTFRMNTH LIKE COFP-WKGBTR VALUE 0,
G_CLSGBAL LIKE COFP-WKGBTR VALUE 0.
DATA: LYEAR(4) TYPE N,
LMONTH1(2) TYPE N,
MON1(2) TYPE N.
DATA: HYEAR(4) TYPE N.
DATA: LMONTH(2) TYPE N.
DATA: HMONTH(2) TYPE N.
DATA: TOTAL(10) TYPE N.
DATA: SUM(10) TYPE N.
DATA: G_PSPID LIKE PROJ-PSPID.
DATA: TOTAL1 LIKE COFP-WKGBTR,
TOTAL2 LIKE COFP-WKGBTR.
DATA: G_KOKRS LIKE COFP-KOKRS,
G_FIPOS LIKE SKB1-FIPOS,
G_POSIT LIKE COFP-POSIT,
G_BUKRS LIKE COFP-BUKRS.
DATA: L_RACCT LIKE FAGLFLEXT-RACCT VALUE '0000220000',
H_RACCT LIKE FAGLFLEXT-RACCT VALUE '0000227999'.
DATA: I TYPE I VALUE '74'.
DATA: P TYPE I VALUE '62'.
*& SELECT-OPTIONS
PARAMETERS : S_PRCTR LIKE PROJ-PRCTR. "Profit Center
SELECT-OPTIONS: SL_SPMON FOR S031-SPMON OBLIGATORY. "Period
*INITIALIZATION
INITIALIZATION.
SL_SPMON-SIGN = C_IN.
SL_SPMON-OPTION = C_BT.
SL_SPMON-LOW = SL_SPMON.
SL_SPMON-HIGH = SL_SPMON.
APPEND SL_SPMON.
AT SELECTION-SCREEN
Event which occurs each time the user hits enter on the selection
Screen.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR SL_SPMON-LOW.
PERFORM MONAT_F4.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR SL_SPMON-HIGH.
PERFORM MONAT_F4.
SELECT SINGLE * FROM PROJ WHERE PRCTR = S_PRCTR.
IF SY-SUBRC <> 0 AND NOT ( S_PRCTR IS INITIAL ).
MESSAGE E019.
ENDIF.
ALL WBS ELEMENT SELECTION
SELECT PSPID INTO TABLE I_PROJTAB FROM PROJ WHERE PRCTR = S_PRCTR.
IF SY-SUBRC = 0.
LOOP AT I_PROJTAB.
CALL FUNCTION 'GET_TREE_FROM_PRHI'
EXPORTING
I_POSID = I_PROJTAB-PSPID
I_PSPNR = 00000000
NO_BUFFER = ' '
TABLES
PSP_TREE = I_PRHI
EXCEPTIONS
INPUT_ERROR = 1
PSP_HIERARCHY_ERROR = 2
PSP_NOT_FOUND = 3
OTHERS = 4
ENDLOOP. " PROJTAB
ENDIF.
SELECT * FROM PRPS INTO TABLE I_PRPSVC FOR ALL ENTRIES IN I_PRHI
WHERE PSPNR = I_PRHI-POSNR.
SELECT * FROM AFVC INTO TABLE I_AFVC FOR ALL ENTRIES IN I_PRPSVC
WHERE PROJN = I_PRPSVC-PSPNR.
SELECT * FROM AUFK INTO TABLE I_AUFK FOR ALL ENTRIES IN I_PRPSVC
WHERE PSPEL = I_PRPSVC-PSPNR AND AUTYP NE C_TWENTY.
SELECT OBJNR FROM PRPS INTO TABLE I_OBJ FOR ALL ENTRIES IN I_PRHI
WHERE PSPNR = I_PRHI-POSNR.
IF SY-SUBRC <> 0.
MESSAGE E010.
ENDIF.
I hope that's of some use.
Thanks & Regards,
Ravi -
Using PNP logical database in report
Hi i'm using the PNP logical database in my report, and i want to hide all fields in the 'Period' frame.
is there any way to do it automatically or is it necessary to hide them one by one??
Thanks in advance.If you can put them all in the same screen group, you may be able to do this. But you might run into problems when you re-generate.
Rob
Maybe you are looking for
-
F.19 GR/IR Clearing accounts
Hi, In F.19 report i can see all the open item, is there any option to see the cleared items in that report?? regards rajesh
-
How to dinamically name objects in a for statement using addChild
Hi. I was wondering where did go the for statement with attachMovie from library in AS 3. I mean i was having in AS 2: for (i=0; i<5; i++) { attachMovie("sim", "sim"+i, i); Now in AS 3: for (var i=0; i<5; i++) { addChild(new sim()); I can't figure ou
-
I have a passport 0740 it shows up on my device manger
I need help.I have a passport 0740 its shows up in the device msger and states that its workin property but when i goto volumes and click populate. all the data comes back blank. could it be broken? it doesnt show up in my computer, nor does it have
-
Pithy - A tiny console file browser
Pithy is a console file browser, a branch of ranger which focuses on shortness and simplicity of the code and integration into the shell while retaining rangers basic features and looks. Its size is less than 1000sloc (about a tenth of ranger) which
-
Please insert cs3 master collection disc 1 into drive
i'm unable to install cs3 master collections on my win xp. i keep getting "Please insert cs3 master collection disc 1 into drive E\ to continue installation". i downloaded this straight from adobes website. the adobe cs3 folder resides on my desktop.