Abap Summarize data in an infoset for queries

Hi all Experts,
I'm still newbie in Abap and query and my request is on the best way to summarize values in an infoset code ?
The requested infoset must report the total goods issues
of a year for some movements code only.
I have tested this way for the year before without succes :
DATA  ICONSO1 LIKE MSEG OCCURS 0 with header line.
DATA : CONS_Y_1 like MVER-GSV01.
DATA : CONS_YEAR1 .
CONS_YEAR1 = SY-DATUM+0(4).
CONS_YEAR1 = CONS_YEAR1 - 1 .
CLEAR CONS_Y_1.
SELECT * FROM MSEG INTO CORRESPONDING FIELDS OF ICONSO1
WHERE  MATNR = MBEW-MATNR AND WERKS = MARD-WERKS
AND MEINS = MARA-MEINS
AND LGORT <> '0005'
AND BWART IN ('261','961') .
LOOP at ICONSO1  WHERE MJAHR = CONS_YEAR1 .
CONS_Y_1 = CONS_Y_1 + ICONSO1-MENGE.
ENDLOOP.
ENDSELECT.
But CONS_A_1 still remains empty..
What I'm doing wrong an what is the best practice ?
Thanks by advance for any help, I'll do not forget points !
Kind regards,
Jean-Michel

May try this way
DATA ICONSO1 LIKE MSEG OCCURS 0 with header line.
DATA : CONS_Y_1 like MVER-GSV01.
DATA : CONS_YEAR1 .
CONS_YEAR1 = SY-DATUM+0(4).
CONS_YEAR1 = CONS_YEAR1 - 1 .
CLEAR CONS_Y_1.
SELECT * FROM MSEG INTO CORRESPONDING
FIELDS OF TABLE ICONSO1       "<<<
WHERE MATNR = MBEW-MATNR AND WERKS =   MARD-WERKS
AND MEINS = MARA-MEINS
AND LGORT '0005'
AND BWART IN ('261','961') .
IF SY-SUBRC EQ 0.
  LOOP at ICONSO1 WHERE MJAHR = CONS_YEAR1 .
    CONS_Y_1 = CONS_Y_1 + ICONSO1-MENGE.
  ENDLOOP.
ENDIF.

Similar Messages

  • How to create a ABAP report off of SRM box for live data?

    How to create a ABAP report off of SRM box for live data?
    Thanks in advance.
    York.

    you can try infoset query:
    STEP - A:
    1. Go to T Code RSQ02 and give the InfoSet name & select CREATE.
    2. Provide the Name(Description) and Data Source i.e. for eg here i take "DIRECT READ OF TABLE" = /BIC/AODS100. Then CONTINUE.
    3. Select what to Include in the 3 options available with the POPUP, here "INCLUDE ALL TABLE FIELDS". Then Check the fields and click GENERATE(one RED and WHITE round icon).
    4. Now provide the PACKAGE for the INFOSET. Come Back(F3).
    STEP - B: optional(If u want to create a new user group)
    1. Select ENVIRONMENT -> USER GROUPS. Provide the User Group name and CREATE.
    2. Provide Description and SAVE.
    3. Provide PACKAGE and SAVE. Come Back (F3) to the Initial Screen.
    4. Click Role/User Group Assignment. Select Newly Created User Group or an existing one. Then SAVE (CTRL + S). F3.
    STEP - C:
    1. Select ENVIRONMENT -> Queries. Provide the query name and CREATE.
    2. Select the INFOSET u have created and assigned the user group.
    3. Provide the Title and Select BASIC LIST. There you have to select (check) the fields you want to display, SAVE and then TEST. It will ask for Variant, just CONTINUE.

  • Creation of summarization data for PA report

    Dear experts,
    I am facing the following problem with PA. I am trying to create a report using KE30, which will utilize summarization data. I then use KE3Q to run this in the background using only one period. Despite what ever I do, after some hours the background job is cancelled. If I use ST22 I get the following error desc: EXPORT_COMPRESS_ERROR
    Although I checked for the above, I couldn't find anything in combination with the PA...
    Any ideas;
    Best Regards
    Peter

    HI Peter,
    Can you try by executing the report in foreground from KE30.
    Better to have Sales Org, product, customer, Fiscal year, period, etc. in selection screen.
    If it is executing in foreground for 1 customer or product, it means there is no issue in report. If it is not able to execute for 1 customer then you have to check the COPA Form and Report.
    BR,
    ADI

  • Storing data in data bag with webdynpro for abap

    Hi,
    It´s possible to store data in data bag with webdynpro for abap?
    The EPCF client data bag API provide methods to store data in a transient data buffer on the client:
                               EPCM.storeClientData(nameSpace, name, value)
    Does webdynpro for abap has an equivalent method?
    Thanks,
    Márcio

    Web Dynpro ABAP can produce a portal event and pass parameters along with the event. These parameters can be read by any event receiver.  However you don't have directly access to the data bag as you describe. Here is a link to the help on the Portal Event API:
    http://help.sap.com/saphelp_nw70ehp1/helpdata/en/da/f96f4132f15c58e10000000a1550b0/frameset.htm

  • ABAP to set "Switched on/off BIA indexes for queries" flag?

    Hi everyone,
    Does anyone know if the "Switch on/off BIA Indexes for Queries" can be set for a specific cube by a delivered ABAP?
    Here's my scenario. We go live with BIA next Monday 9/22. I've indexed our cubes in production BIA this past weekend and they're rolled up nightly. Until the go-live, I've manually set the "Switched Off for Queries" flag via RSDDBIAMON > BI Accelerator > Index Settings > Switch on/off BIA Indexes for Queries".
    However, one indexed cube is deleted fully every night by the flag in the full load infopackage. In testing, I saw that the BIA fact table index was fully deleted when the E and F tables of the cube were truncated, and then reindexed when the full package is loaded and rolled up. This is all ok.
    The issue is that after the delete, load and rollup, the "Switched Off for Queries" flag is not set. I have had to manually reset to off in the morning. This won't be an issue (hopefully) once we go live, but it does seem like a bug and I'll likely submit a customer message. I would think the delete, index and rollup process should not change the status of this flag.
    Does anyone know if that flag can be programatically set?
    Thanks for any advice,
    Doug

    Thanks, Vitaliy!
    I think you're exactly right. Its seems to be a bug in processing of just this specific type of index reprocessing, e.g. dropping and reindexing. The indexing process properly retains INA status on the other delta indexed cubes.
    I'm barely ABAP OO literate, but do understand enough to find, review and test the class and method code. Thanks for finding it!
    Also, I reviewed table RSDDTREXDIR and it is correct/current. It does spawn another question, though. The field ITYPE (Type of BIA Index) is consistently ICB exept for 2 cubes/indexes, which are typed as PA2 and PA9. When I check possible values on the domain, RSDDTREX_TAGGR_TYPE, it only lists ICB and ICF (Infocube - flat).
    Any idea what types PA2 and PA9 are, and why these 2 cubes would be different? From my perspective, they're basic infocubes, same as all the others.
    Thanks again,
    Doug

  • Infoset for sales Order Transaction data

    Hi,
    I wanted to create target Group based on Sales Order Transaction Data.Any standard Infoset is Available to Create Target group based on sales order Transaction data.
    or any other data sources is there to crate target group.so that all sales Order Transaction data will be available to Create Target Group in Segmentation.
    Thanks In Advance
    Thanks & Regards
    Kishore KUmar

    Hi Kishore ,
    Infoset can be used for create the target group based on master data only.
    To create the target group based on any transaction Data , you need use 'BW Query' data sorce .
    For this you need to build the BW uery with the help of BW consuultant.
    I  hope it will help you ,
    Regards,
    Syed Basha.

  • Full ABAP Edition-Trial (with Web Dynpro for ABAP) Max DB data volume

    I recently installed Full ABAP Edition-Trial (with Web Dynpro for ABAP)- SPS08.
    http://static.flickr.com/89/243544270_91e713e3a3_o.jpg
    as you can see, it's already 92% acquired ( just after installation)
    Is it correct?
    or it's better to add another volume?
    The other question is
    according to the license installation guide,
    it sounds like we can delete the temp licese with SAP*.
    so I did like that but i got the following message
    http://static.flickr.com/81/243546622_bc99d1af2b_o.jpg
    Well, I could delete the old license with BCUSER.
    Thanks,
    David

    Hello,
    to your first question.
    The MaxDB database has a feature which can
    increase the database automatically.
    This ( auto_extend ) is turned on for the SDN Preview
    installation.
    That means the database should extend a further datavolume
    automatically when the filling level gets over 90%.
    In your case the database already added two more datavolumes. The installation only creates one.
    Best regards, Stefan

  • Summarize data from a subreport in a main report

    Good afternoon,
    I'm trying to summarize data from a subreport with data in a main report and I can't get it to summarize all the data correctly. The reports are linked on order number.
    The main report has 3 groups - customer id, batch, order number (in that order). In the detail section I have product and amount. I have the group footer for group order numbers split into two. Footer A has the subreport.
    The subreport has tax code and amount in the detail and I've created a shared variable:
    WhilePrintingRecords;
    Shared CurrencyVar taxtotal := Sum ({@total tax})
    In my main report I created a formula for the shared variable:
    WhilePrintingRecords;
    Shared CurrencyVar taxtotal; taxtotal
    In Footer B of the order number group I have a summary field that is taking the shared variable and adding it to the product amount and creating a total.
    {@taxtotal1} +Sum ({@ext price}, )
    That is all working fine. Where my problem comes in is on the footer for the Batch group. There are 3 order numbers for 1 batch. I have this summary field in the Batch group footer
    ({@taxtotal1} +Sum ({@ext price}, ))
    But it's not calculating correctly. I need it to take all the product amounts and all the tax amounts and add them together, what it is doing is only adding one of the tax amounts along w/ all the product amounts.
    What am I doing wrong? Any help would be greatly appreciated.
    Jeannette

    Hi Jeanette,
    You need to have the running total accumulate into the Batch group as well.  Right now it's just getting the the Tax Total from the last Order Number. 
    In the formula in Footer B of the Order Number, change your formula to: 
    WhilePrintingRecords;
    Shared CurrencyVar taxtotal;
    CurrencyVar batchTaxTotal;
    batchTaxTotal := batchTaxTotal + taxtotal;
    taxtotal;
    Now in your formula in the Batch footer change it to: 
    WhilePrintingRecords;
    CurrencyVar batchTaxTotal;
    (batchTaxTotal +Sum ({@ext price}, {batch}))
    In the Batch Group Header, you will need to reinitialize the total to 0 for the next batch: 
    WhilePrintingRecords;
    CurrencyVar batchTaxTotal := 0;
    Good luck,
    Brian

  • Can I summarize data from a line item ODS into a higher summary level?

    Hello friends,
    1) Can I summarize data from a line item ODS into a high summary level and store the results into another ODS?  If so, can you discuss the approach at a high level...i.e. whether or not a start up routine is needed?
    2) Once data is stored in an ODS, can a routine be written to update specific fields in the ODS after the data has already been loaded into the ODS.  As a simple example, is it possible to write a routine that simply multiplies "Field A" by "Field B" and stores the result in the ODS as "Field C"?  (Most of the time I would do this calculation in Bex, but in this one case, I have the need to calculate and store "Field C" in the ODS.)
    Thank you.

    1.- Yes, you can sumarize data in other ODS. Connect both ODS and use aditions for key figures intead of overwriting.
    2.- You can do it in load time, in update rules, is not necesary to wait for ODS was loaded

  • How we can see the abap memory data

    How we can see the abap-memory data
    fine the code below
    import lsind
             report_title
             table_name
             report_field
             change_display
             show_hide
             conversion_exits
             table_description
             form_program
             select_form
             update_form
             line_size
             line_count
             records[]
             fields[]
             header_fields[]
             select_fields[]
             xrep[]
             from memory id 'LZUT5U11'.
    Regards
    santhosh
    mail-id : [email protected]

    Dear Santosh,
    ABAP MEMORY:
    A logical memory model illustrates how the main memory is distributed from the view of executable programs. A distinction is made here between external sessions and internal sessions .
    An external session is usually linked to an R/3 window. You can create an external session by choosing System/Create session, or by entering /o in the command field. An external session is broken down further into internal sessions. Program data is only visible within an internal session. Each external session can include up to 20 internal sessions (stacks).
    Every program you start runs in an internal session.
    All "squares" with rounded "corners" displayed in the status diagram represent a set of data objects in the main memory.
    The data in the main memory is only visible to the program concerned.
    CALL TRANSACTION and SUBMIT AND RETURN open a new internal session that forms a new program context. The internal sessions in an external session form a memory stack. The new session is added to the top of the stack.
    When a program has finished running, the top internal session in the stack is removed, and the calling program resumes processing.
    The same occurs when the system processes a LEAVE PROGRAM statement.
    LEAVE TO TRANSACTION removes all internal sessions from the stack and opens a new one containing the program context of the calling program.
    The ABAP memory is initialized after the program is called. In other words, you cannot transfer any data to a program called with LEAVE TO TRANSACTION via the ABAP memory.
    SUBMIT replaces the internal session of the program performing the call with the internal session of the program that has been called. The new internal session contains the program context of the called program with which it is performed.
    When a function module is called, the following steps are executed:
    A check is made to establish whether your program has called a function module of the same function group previously.
    If this is not the case, the system loads the associated function group to the internal session of the calling program as an additional program group. This initializes its global data.
    If your program used a function module of the same function group before the current call, the function module that you have called up at present can access the global data of the function group. The function group is not reloaded.
    Within the internal session, all of the function modules that you call from the same group access the global data of that group.
    If, in a new internal session, you call a function module from the same function group as in internal session 1, a new set of global data is initialized for the second internal session. This means that the data accessed by function modules called in session 2 may be different from that accessed by the function modules in session 1.
    You can call function modules asynchronously as well as synchronously. To do so, you must extend the function module call using the addition STARTING NEW TASK ''. Here, '' is a symbolic name in the calling program that identifies the external session, in which the called program is executed.
    Function modules that you call using the addition STARTING NEW TASK '' are executed independently of the calling program. The calling program is not interrupted.
    To make function modules available for local asynchronous calls, you must identify them as executable remotely (processing type: Remote-enabled module).
    There are various ways of transferring data between programs that are running in different program contexts (internal sessions). You can use:
    (1) The interface of the called program (standard selection screen, or interface of a
    subroutine, function module, or dialog module)
    (2) ABAP memory
    (3) SAP memory
    (4) Database tables
    (5) Local files on your presentation server.
    For further information about transferring data between an ABAP program and your presentation server, refer to the documentation for the function modules WS_UPLOAD and WS_DOWNLOAD.
    Function modules have an interface, which you can use to pass data between the calling program and the function module itself (there is also a comparable mechanism for ABAP subroutines). If a function module supports RFC, certain restrictions apply to its interface.
    If you are calling an ABAP program that has a standard selection screen, you can pass values to the input fields. There are two options here:
    By using a variant of the standard selection screen in the program call
    By passing actual values for the input fields in the program call
    If you want to call a report program without displaying its selection screen (default setting), but still want to pass values to its input fields, there is a variety of techniques that you can use.
    The WITH addition allows you to assign values to the parameters and select-options fields on the standard selection screen.
    If the selection screen is to be displayed when the program is called, use the addition: VIA SELECTION-SCREEN.
    Use the pattern button in the ABAP Editor to insert a program call via SUBMIT. The structure shows you the names of data objects that you can complete with the standard selection screen.
    For further information on working with variants and further syntax variants for the WITH addition, see the key word documentation in the ABAP Editor for SUBMIT.
    You can use SAP memory and ABAP memory to pass data between different programs.
    The SAP memory is a user-specific memory area for storing field values. It is available in all of the open sessions in a user's terminal session, and is reset when the terminal session ends. You can use its contents as default values for screen fields. All external sessions can access SAP memory. This means that it is only of limited use for passing data between internal sessions.
    The ABAP memory is also user-specific, and is local to each external session. You can use it to pass any ABAP variables (fields, structures, internal tables, complex objects) between the internal sessions of a single external session.
    Each external session has its own ABAP memory. When you end an external session (/i in the command field), the corresponding ABAP memory is released automatically.
    To copy a set of ABAP variables and their current values (data cluster) to the ABAP memory, use the EXPORT TO MEMORY ID statement. The (up to 32 characters) is used to identify the different data clusters.
    If you repeat an EXPORT TO MEMORY ID statement to an existing data cluster, the new data overwrites the old.
    To copy data from ABAP memory to the corresponding fields of an ABAP program, use the IMPORT FROM MEMORY ID statement.
    The fields, structures, internal tables, and complex objects in a data cluster in ABAP memory must be declared identically in both the program from which you exported the data and the program into which you import it.
    To release a data cluster, use the FREE MEMORY ID statement.
    You can import just parts of a data cluster with IMPORT, since the objects are named in the cluster.
    In the SAP memory, you can define memory areas (SET/GET parameters, or parameter IDs), which you can then address by a name of up to 20 characters.
    You can fill these memory areas either using the contents of input/output fields on screens, or using the ABAP statement:
    SET PARAMETER ID '' FIELD .
    The memory area with the name now has the value .
    You can use the contents of a memory area to display a default value in an input field on a screen.
    You can also read the memory areas from the SAP memory using the ABAP statement GET PARAMETER ID FIELD . The field then contains the value from parameter .
    The link between an input/output field and a memory area in SAP memory is inherited from the data element on which the field is based. You can enable the set parameter or get parameter attributes in the input/output field attributes.
    Once you have set the Set parameter attribute for an input/output field, you can fill it with default values from SAP memory. This is particularly useful for transactions that you call from another program without displaying the initial screen. For this purpose, you must activate the Set parameter functionality for the input fields of the first screen of the transaction.
    You can:
    (1) Copy the data that is to be used for the first screen of the transaction to be called to the parameter ID in the SAP memory. To do so, use the statement SET PARAMETER immediately before calling the transaction.
    (2) Start the transaction using CALL TRANSACTION or LEAVE TO
    TRANSACTION . If you do not want to display the initial screen, use the AND
    SKIP FIRST SCREEN addition.
    (3) The system program that starts the transaction fills the input fields that do not already have default values and for which the Get parameter attribute has been set with values from SAP memory.
    The Technical information for the input fields in the transaction you want to call contains the names of the parameter IDs that you need to use.
    Parameter IDs should be entered in table TPARA. This happens automatically if you create them via the Object navigator.
    Programs that you call using the statements SUBMIT , LEAVE TO TRANSACTION , SUBMIT AND RETURN, or CALL TRANSACTION run in their own SAP LUW, and update requests receive their own update key.
    When you use SUBMIT and LEAVE TO TRANSACTION , the SAP LUW of the calling program ends. If no COMMIT WORK statement occurred before the program call, the update requests in the log table remain incomplete and cannot be processed. They can no longer be executed. The same applies to inline changes that you make using PERFORM &#8230; ON COMMIT.
    Data that you have written to the database using inline changes is committed the next time a new screen is displayed.
    If you use SUBMIT AND RETURN or CALL TRANSACTION to insert a program and then return to the calling program, the SAP LUW of the calling program is resumed when the called program ends. The LUW processing of calling and called programs is independent.
    In other words, inline changes are committed the next time a new screen is displayed. Update requests and calls using PERFORM ... ON COMMIT require an independent COMMIT WORK statement in the SAP LUW in which they are running.
    Function modules run in the same SAP LUW as the program that calls them.
    If you call transactions with nested calls, each transaction needs its own COMMIT WORK, since each transaction maps its own SAP LUW.
    The same applies to calling executable programs, which are called using SUBMIT AND RETURN.
    The statement CALL TRANSACTION allows you to
    Shorten the user dialog when calling using CALL TRANSACTION USING .
    Determine the type of update (asynchronous, local, or synchronous) for the transaction called. For this purpose, use the addition CALL TRANSACTION USING UPDATE 'update_mode', where update_mode can have the values a (asynchronous), L (local), or S (synchronous).
    Combining the two options enables you to call several transactions in sequence (logical chain), to reduce their screen sequence, and to postpone processing of the SAP LUW 2 until processing of the SAP LUW 1 has been completed.
    When you call a function module asynchronously using the CALL FUNCTION STARTING NEW TASK ' ' statement, it runs in its own SAP LUW.
    Programs that are executed with a SUBMIT AND RETURN or CALL
    TRANSACTION statement starts their own LUW processing. You can use these to perform nested (complex) LUW processing.
    You can use function modules as modularization units within an SAP LUW.
    Function modules that are called asynchronously are suitable for programs that allow parallel processing of some of their components.
    All techniques are suitable for including programs with purely display functions.
    Note that a function module called with CALL FUNCTION STARTING NEW TASK is executed as a new logon. It, therefore, sees a separate SAP memory area. You can use the interface of the function module for data transfers.
    Example: In your program, you want to call a display transaction that is displayed in a separate window (amodal). To do so, you encapsulate the transaction call in a function module, which you set as to Remote-enabled module. You use the function module interface to accept values that you write to the SAP memory. You then call up the transaction in the function module using CALL TRANSACTION AND SKIP FIRST SCREEN. You call the function module itself asynchronously.
    Type &#8216;E' locks for nested program calls may be requested more than once from the same object. This behavior can be described as follows:
    Lock entries from function modules called synchronously increment the cumulative counter, And are therefore successful.
    Lock entries from programs called with CALL TRANSACTION or SUBMIT
    AND
    RETURN is refused. The object to be locked by the called program is displayed as already Locked by another user.
    Programs that you call using SUBMIT or LEAVE TO TRANSACTION cannot come into conflict with lock entries from the calling program, since the old program ends when the call is made. When a program ends, the system deletes all of the lock entries that it had set.
    Lock requests belonging to the same user from different R/3 windows or logons are treated as lock requests from other users.
    Regards,
    Rajesh.
    Please reward points if found helpful.

  • How i can give date in each input for applying the exchange rate in Query.

    Hi Gurus,
    We have a requirement to create some currency conversion queries. In the selection screen user should be able to give four inputs. Like given below
    Input 1.          a)  key figures
                            b) Fiscal Year
                            c) Fiscal Period
                            d) Exchange Rate Type
                            e) Date (Exchange rate will be applied which is applicable on the given date)
      Input 2.         a)  key figures
                            b) Fiscal Year
                            c) Fiscal Period
                            d) Exchange Rate Type
                            e) Date (Exchange rate will be applied which is applicable on the given date)
    Input 3.          a)  key figures
                            b) Fiscal Year
                            c) Fiscal Period
                            d) Exchange Rate Type
                            e) Date (Exchange rate will be applied which is applicable on the given date)
    Input 4.          a)  key figures
                            b) Fiscal Year
                            c) Fiscal Period
                            d) Exchange Rate Type
                            e) Date (Exchange rate will be applied which is applicable on the given date)
    So we will have 4 key figures in the query results with the exchange rate applied on the given date.
    I will make four restricted key figures and make the query. I do not know how i can give date in each input for applying the exchange rate.
    Please give your suggestions to resolve my problem.
    Many thaks in advance.

    You can not bring the key figures in the selection screen for the currency translation. Instead you can apply a currency translation type to respective key figures in the query definition.
    The currency translation type can be defined in RSCUR transaction, where you can maintain the parameters like Exchange Rate Type, Exchange Rate Date etc.
    You can refer one of my article on this at
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/600157ec-44e5-2b10-abb0-dc9d06ba6c2f
    Hope this helps.
    Regards,
    Yogesh

  • Which Event Classes i should use for finding good indexs and statistics for queries in SP.

    Dear all,
    I am trying to use pro filer to create a trace,so that it can be used as workload in
    "Database Engine Tuning Advisor" for optimization of one stored procedure.
    Please tel me about the Event classes which i  should use in trace.
    The stored proc contains three insert queries which insert data into a table variable,
    Finally a select query is used on same table variable with one union of the same table variable, to generate a sequence for records based on certain condition of few columns.
    There are three cases where i am using the above structure of the SP, so there are three SPS out of three , i will chose one based on their performance.
    1) There is only one table with three inserts which gets  into a table variable with a final sequence creation block.
    2) There are 15 tables with 45 inserts , which gets into a tabel variable with a final
    sequence creation block.
    3)
    There are 3 tables with 9 inserts , which gets into a table variable with a final
    sequence creation block.
    In all the above case number of record will be around 5 lacks.
    Purpose is optimization of queries in SP
    like which Event Classes i should use for finding good indexs and statistics for queries in SP.
    yours sincerely

    "Database Engine Tuning Advisor" for optimization of one stored procedure.
    Please tel me about the Event classes which i  should use in trace.
    You can use the "Tuning" template to capture the workload to a trace file that can be used by the DETA.  See
    http://technet.microsoft.com/en-us/library/ms190957(v=sql.105).aspx
    If you are capturing the workload of a production server, I suggest you not do that directly from Profiler as that can impact server performance.  Instead, start/stop the Profiler Tuning template against a test server and then script the trace
    definition (File-->Export-->Script Trace Definition).  You can then customize the script (e.g. file name) and run the script against the prod server to capture the workload to the specified file.  Stop and remove the trace after the workload
    is captured with sp_trace_setstatus:
    DECLARE @TraceID int = <trace id returned by the trace create script>
    EXEC sp_trace_setstatus @TraceID, 0; --stop trace
    EXEC sp_trace_setstatus @TraceID, 2; --remove trace definition
    Dan Guzman, SQL Server MVP, http://www.dbdelta.com

  • JCO reading abap RAW data type (truncating?)

    Does anyone have experience reading an Abap RAW data type using JCO?  I am trying to read a GUID (via RFC_READ_TABLE) that is defined as RAW length 16.  When I view this field in SAP GUI, I see 32 characters.  However, when I read this field using JCO, I only see the first 16 characters. 
    The mapping documents state Abap RAW maps to a Java byte array.  I have tried that - no luck.  I have used the constructor of a string that takes a byte array - no luck.  I have made sure my character set is UTF-8 in case Unicode was a possibility.  I have turned on tracing to level 8 and only see 16 characters in the output.  I need the other 16 characters as all 32 characters are used as the primary key into other tables.
    I also posted this on the ABAP Java Development space.  I know the rule about not cross-posting, but I wasn't sure which was a better place to post something like this.  This my first post on here, so my apologies in advance.
    Larry

    Thanks for responding.  Unfortunately, the export parameter list is null. There are no export parameters.  However, there are tables.  I have tried:
    byte[] byteArray = funct.getTableParameterList().getTable("DATA").getByteArray(0);
    My SE16 query only returns one field: GUID.
    I only get 16 bytes back even though GUID is defined as raw length 32.
    Is there something I else I should try?  Do you see an error in my code?
    Thanks again,
    Larry

  • What is "*$HR$ [*]" code in data section of INFOSET?

    I saw "$HR$ []" code in data section of Infoset.
    At Sap query, it changes the resulting abap code, and that's all I know.
    How does this work?
    Plz, give me some explanation.

    There is infoset switch. Check IMG.

  • ABAP System data is not showing in SLD

    Hi All,
    I need to see ABAP System data in to my Java SLD, but presently i cant may be due to 2 main issues--
    1. I have configured all the connections related to RFC properly & SLDCHECK is also giving Green status, but when i ran data collector job in RZ70,. it is giving me following logs
    SLD DS Start Program
        0: inmumsap18_BW2_00                         : Execute program: SLDRFC
        0: inmumsap18_BW2_00                         : Execute program: SLDMSGSRV
        0: inmumsap18_BW2_00                         : Execute program: SLDIPSERV
        0: inmumsap18_BW2_00                         : Execute program: SLDINSTSP
        0: inmumsap18_BW2_00                         : Execute program: SLDINSTSC
        0: inmumsap18_BW2_00                         : Execute program: SLDINSTPRD
        0: inmumsap18_BW2_00                         : Execute program: SLDGWSRV
        0: inmumsap18_BW2_00                         : Execute program: SLDDBSYS
        0: inmumsap18_BW2_00                         : Execute program: SLDCOMPSYS
        0: inmumsap18_BW2_00                         : Execute program: SLDCLIENT
        0: inmumsap18_BW2_00                         : Execute program: SLDBCSYS
        0: inmumsap18_BW2_00                         : Execute program: SLDAPPL_SERV
        0: inmumsap18_BW2_00                         : Execute program: SLDASSOC
        0: inmumsap18_BW2_00                         : Collection of SLD data finished
        0: inmumsap18_BW2_00                         : Data collected successfully
        0: inmumsap18_BW2_00                         : RFC data prepared
        0: inmumsap18_BW2_00                         : Used RFC destination: SLD_NUC
        0: inmumsap18_BW2_00                         : RFC call failed: Error when opening an RFC connection
        0: inmumsap18_BW2_00                         : Test mode: No batch job created
    i did created SLD_NUC entry in Visual admin of my source system then it gives me error of "RFC call failed: JCO.Server could not find server function 'SET_SLD_DATA'.
    So now i need to know, whether this job is actually fetching me data or not?
    Also, when i check in SLD-Administration-data supplier tab, there it shows me my RFC server threads are down, so what to do for it? I did saw in one note, saying Restarting complete server will help, but i think that should be last option, so need to any other solutions prior to that?
    Please also tell me, whether anything else to do for having ABAP system in NWA, i need to do basic activities from NWA for ABAP system?

    Hi,
    This is dual stack, but still i'm not able to see the system.
    Also tell me, in SLD when i'm checking SLD Data supplier in Details tab, it is showing me RFC Server threads as down.
    For example--
    RFC server threads:
    [DOWN] NUC:localhost_sapgw_SLD_NUC_160375285
    [DOWN] UC :localhost_sapgw_SLD_UC_1570432430
    [DOWN] NUC:localhost_sapgw_SLD_NUC_1566747572
    [DOWN] UC :localhost_sapgw_SLD_UC_131845580
    Is this hampering anything?
    Also, in SLD, i'm not able to see Server Settings button/option in main page along with SLD Data Supplier starting option. I have already given concerned roles to my User J2EE_ADMIN, by which i'm logging in to the SLD, as this is my Administrator user.

Maybe you are looking for

  • How to Determine the "Total" Page Count on HP 2575 All-in-one printer?

    Looking at how to determine the "Total" Page Count on HP 2575 All-in-one printer?   I've seen directions for other HP printers but can't seem to find any for the HP 2575 All-in-one printer.  I am trying to find approximately how many pages my printer

  • Accuracy in custom Clock

    Hi all! I've made a simple clock meant to measure computer uptime. I'm using javax.swing.Timer with a delay of 1000 milliseconds. By each event triggered by the timer a variable (long as datatype) holding the total elapsed seconds is incremented. My

  • Parameter memory not initializing whwn re execute the program

    I have used parameter memory in  selection screen  of module pool program, The problem is when I exit from the program and re execute the transaction the parameter memory not initializing and the same value come again in the selection screen .

  • Crystal reports 2008 connection to universe

    Hi , I am trying to create Crystal Reports using universe as a data source. I am able to logon BOE, select universe and then select the objects that I need to build a query. As soon as I click OK button I am getting "Logon Failed". If i use SAP BW MD

  • Brief Idea of Java Technology !

    Hi all, I m a Form/Report Developer in 11g and want to use JAVA in my 11g Forms/Reports application. But I have a little knowledge of Java, and Java has also so many technologies, and confuse to start the technology. So, want some brief idea of all J