How do I create a dynamic growing table which holds "copies" of the footer Row from several instances?
Mission:
To create a summary table with Rows from several (yet to be determined) instances
Coordinates of the enemy (or Row in question):
ROOT.category[*].sub_category_total.sub_category_summary.Row1
Background information:
An order form with option for several categories (2 – 10) with subcategories (2 – 20).
Since the finished form might be up to 20 pages long I would like to get to the point
with a click of a button (so to speak)
Therefore a summary list seems the only logic solution.
Reward:
Unending gratefulness and publishing of finished sample for others to learn from
Additional Note:
Should you choose to accept this mission I will never deny your existence and will
always give credit to whom credit belongs.
This message will NOT self-destruct.
Hi Steve,
thanks for the example ... nice and close but not 100 % solution.
The sample requires me to set up the summary table with fixed rows.
But I don't know how many main categories & subcategories will be there - it can vary between 2 and 20.
One solution would be to set up a table with 20+ rows and hide them if rawValue ... equals 0.
Might work - but is not very elegant ....
I guess I was looking for the script that counts the instances and then creates automatically the necessary rows.
I know it is a lot to ask in a forum ... but I guess it might be possible. Isn't it??
Please let me know if I'm reaching for the impossible
Jixin
Similar Messages
-
Table which contains name of the report generated from table
Hello everyone,
Is there any table which stores the report names that are created from table.
For example if my table name is 'ABC' a new report will be created for table at run time '/1BCDWB/DB/ABC'.
I also need to have table names, which stored the values when a layout is changed
For example if I have ten fields in my table, first time ill choose 5 fields, second time ill change the layout and choose 10 fields and ill save the layout.
If any Function modules are there please let me know
Please let me know, if anyone has details.
Thanks,
Gayatri.
Moderator message : Duplicate post locked. Continue with the thread - [Name of the table which stores report contents and layout changes|Name of the table which stores report contents and layout changes;.
Edited by: Vinod Kumar on Jun 14, 2011 3:42 PMHi,
Thanks for reply.
I know about ttxfp and tnapr. but none of the two table contain form name with its description. actully I m looking for a table which contain form name with there desription. please if you have info regarding this, Do share with me . this is really urgent
regrads,
Ruchika saini -
Hello Everyone,
I am trying to create a single video clip where my original subject (dancer) is multiplied on the screen many times. Basically I am trying to create a background video for a dance team and want to make it look like an army of the same person dancing behind them. Amy guidance would be great!
Thanks
Madisonman 2013Motion ($50) can do this with a replicator.
Russ -
Hi All,
Suppose I have table, whose structure changes frequently on daily basis.
For eg. desc my_table gives you following column name on Day 1
SQL > desc my_table;
Output
Name
Age
Phone
On Day 2, two more columns are added, viz, Address and Salary.
SQL > desc my_table;
Output
Name
Age
Phone
Address
Salary
Now I want to create an Dynnamic RTF report which would fetch data from ALL columns from my_table on daily basis. For that I have defined a concurrent program with XML as output type and have attached a data template/data definition to it which takes in XML as input and gives final output of conc program in EXCEL layout. I am able to do this for constant number of columns, but dont know how to do it when the number of columns to be displayed changes dynamically.
For Day 1 my XML file should be like this.
<?xml version="1.0" encoding="UTF-8"?>
<dataTemplate name="XYZ" description="iExpenses Report" Version="1.0">
<dataQuery>
<sqlStatement name="Q2">
<![CDATA[
SELECT Name
,Age
,Phone
FROM my_table
]]>
</sqlStatement>
</dataQuery>
<dataStructure>
<group name="G_my_table" source="Q2">
<element name="Name" value="Name" />
<element name="Age" value="Age" />
<element name="Phone" value="Phone" />
</group>
</dataStructure>
</dataTemplate>
And my Day 1, EXCEL output from RTF template should be like this.
Name Age Phone
Swapnill 23 12345
For Day 2 my XML file should be like this. With 2 new columns selected in SELECT clause.
<?xml version="1.0" encoding="UTF-8"?>
<dataTemplate name="XYZ" description="iExpenses Report" Version="1.0">
<dataQuery>
<sqlStatement name="Q2">
<![CDATA[
SELECT Name
,Age
,Phone
,Address
,Salary
FROM my_table
]]>
</sqlStatement>
</dataQuery>
<dataStructure>
<group name="G_my_table" source="Q2">
<element name="Name" value="Name" />
<element name="Age" value="Age" />
<element name="Phone" value="Phone" />
<element name="Address" value="Address" />
<element name="Salary" value="Salary" />
</group>
</dataStructure>
</dataTemplate>
And my Day 2, EXCEL output from RTF template should be like this.
Name Age Phone Address Salary
Swapnill 23 12345 Madrid 100000
Now, I dont know below things.
Make the XML dynamic as in on Day 1 there must be 3 columns in the SELECT statement and on Day 2, 5 columns. I want to create one dynamic XML which should not be required to be changed if new columns are added in my_table. I dont know how to create this query and also create their corresponding elements below.
Make the RTF template dyanamic as in Day1 there must 3 columns in EXCEL output and on Day 2, 5 columns. I want to create a Dynamic RTF template which would show all the columns selected in Dynamic XML.I dont know how the RTF will create new XML tags and how it will know where to place it in the report. Means, I can create RTF template on Day 1, by loading XML data for 3 columns and placing 3 XML tags in template. But how will it create and place tags for new columns on Day 2?
Hope, you got my requirement, its a challenging one. Please let me know how I can implement the required solution using RTF dynamically without any manual intervention.
Regards,
Swapnil K.
Message was edited by: SwapnilKHi All,
I am able to fulfil above requirement. Now I am stuck at below point. Need your help!
Is there any way to UPDATE the XML file attached to a Data Definition (XML Publisher > Data Definition) using a standard package or procedure call or may be an API from backend? I am creating an XML dynamically and I want to attach it to its Data Definition programmatically using SQL.
Please let me know if there is any oracle functionality to do this.
If not, please let me know the standard directories on application/database server where the XML files attached to Data Definitions are stored.
For eg, /$APPL_TOP/ar/1.0/sql or something.
Regards,
Swapnil K. -
Error while creating a dynamic internal table refers to custom field
Hi all,
I am getting the exception TYPE_NOT_FOUND when I try to create a dynamic internal table using:-
DATA: gr_desc TYPE REF TO cl_abap_typedescr.
gr_desc = cl_abap_typedescr=>describe_by_name( p_field ).
The field p_field is a Z-field inside a DB table, (e.g. a user added field in MARA). The statement fails at that point and gives a runtime exception. Any suggestions to how I may solve this problem? Or any alternatives for the same? I guess we face this issue for all custom fields..has SAP released a note for this??
Thanks..that's just the wrong method, you should use DESCRIBE_BY_DATA
gr_desc = cl_abap_typedescr=>describe_by_data( p_field ).
Note: DESCRIBE_BY_NAME is to be used for referencing a DDIC type by its name. Example:
gr_desc = cl_abap_typedescr=>describe_by_name( 'MARA-ZZFIELD' ). -
How to upload data with dynamic internal table
Hi,
I have to upload the basic , sales, purchasing view data by using bapi depend on check box selected for views.
i have filled fieldcatalog for selected views and pass the field catalog structure to dynamic int table and
import it into the field symbol <fs_data>. this field symbol assigned to <fs_1>.
then callED the 'GUI_UPLOAD ' and when i pass field symbo for function module i am getting first 10 rows 0f the file .
flat file has basic data,sales ,purchase fields data
ex: i was selected basicview and purchase view and execute i am getting basic,sales view data.
how can i get only basic and purchase data.hi ,
please find code.
CALL METHOD cl_alv_table_create=>create_dynamic_table
EXPORTING
it_fieldcatalog = lt_fieldcatalog
IMPORTING
ep_table = <fs_data>
EXCEPTIONS
generate_subpool_dir_full = 1
OTHERS = 2.
IF sy-subrc <> 0. "#EC NEEDED
ENDIF.
So <FS_1> now points to our dynamic internal table.
ASSIGN <fs_data>->* TO <fs_1>.
Next step is to create a work area for our dynamic internal table.
CREATE DATA new_line LIKE LINE OF <fs_1>.
A field-symbol to access that work area
ASSIGN new_line->* TO <fs_2>.
ASSIGN new_line->* TO <fs_3>.
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
filename = p_f
filetype = 'DAT'
TABLES
data_tab = <fs_1>
EXCEPTIONS
file_open_error = 1
file_read_error = 2
no_batch = 3
gui_refuse_filetransfer = 4
invalid_type = 5
no_authority = 6
unknown_error = 7
bad_data_format = 8
header_not_allowed = 9
separator_not_allowed = 10
header_too_long = 11
unknown_dp_error = 12
access_denied = 13
dp_out_of_memory = 14
disk_full = 15
dp_timeout = 16
OTHERS = 17.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF. -
How can I create a query with tables in INFOSET?
Dear Gurus,
How can I create a query with tables in INFOSET?
Just tables and fields INFOSET?
Kind Regards,Hello
Check following SCN Article for your understanding/reference:
- [Using Infoset Query ,SAP Query and Quick Viewer|http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/10eab7af-0e54-2c10-28a5-87b47adbe1a5]
Regards
JP -
How can i create a Global Temporary Table inside a Stored Procedure....
Hi...
I need to create a Global Temporary Table inside a Stored
Procedure....
I have no idea how to do that....
Please....if u can send me a sample, send to me....
Thanks a lotTo create a global temporary table inside a stored procedure,
the minimal syntax would be:
CREATE OR REPLACE PROCEDURE procedure_name
AS
BEGIN
EXECUTE IMMEDIATE 'CREATE GLOBAL TEMPORARY TABLE table_name'
|| '(column_name NUMBER)';
END procedure_name;
As Todd stated, it would probably be better to create the global
temporary table outside of the procedure:
SQL> CREATE GLOBAL TEMPORARY TABLE table_name
2 (column_name NUMBER);
Table created.
You can also specify things like ON COMMIT PRESERVE ROWS or ON
COMMIT DELETE ROWS.
It may be that there is something else, like a PL/SQL table of
records or a cursor, that would suit your needs better. It is
difficult to guess without knowing what you want to do with it. -
How to populate data into Dynamic Internal Table.
Hi Experts,
I had created one Dynamic Internal table and one static internal table.I want to move data from Static Internal table to Dynamic interal table.And aslo the number of coloum of these two tables are not same.
So please help me for solving this issue.
Thanks,
<u><i><b>Seema.</b></i></u>Hi,
Check out this sample program for dynamictable report.
REPORT YMS_DYNAMICDEMO
NO STANDARD PAGE HEADING
MESSAGE-ID zcs_c2c_001.
type-pools : abap.
field-symbols: <dyn_table> type standard table,
<dyn_wa>,
<dyn_field>.
data: dy_table type ref to data,
dy_line type ref to data,
xfc type lvc_s_fcat,
ifc type lvc_t_fcat.
selection-screen begin of block b1 with frame.
parameters: p_table(30) type c default 'T001'.
selection-screen end of block b1.
start-of-selection.
perform get_structure.
perform create_dynamic_itab.
perform get_data.
perform write_out.
form get_structure.
data : idetails type abap_compdescr_tab,
xdetails type abap_compdescr.
data : ref_table_des type ref to cl_abap_structdescr.
Get the structure of the table.
ref_table_des ?=
cl_abap_typedescr=>describe_by_name( p_table ).
idetails[] = ref_table_des->components[].
loop at idetails into xdetails.
clear xfc.
xfc-fieldname = xdetails-name .
xfc-datatype = xdetails-type_kind.
xfc-intlen = xdetails-length.
xfc-decimals = xdetails-decimals.
append xfc to ifc.
endloop.
endform.
form create_dynamic_itab.
Create dynamic internal table and assign to FS
call method cl_alv_table_create=>create_dynamic_table
exporting
it_fieldcatalog = ifc
importing
ep_table = dy_table.
assign dy_table->* to <dyn_table>.
Create dynamic work area and assign to FS
create data dy_line like line of <dyn_table>.
assign dy_line->* to <dyn_wa>.
endform.
form get_data.
Select Data from table.
select * into table <dyn_table>
from (p_table).
endform.
form write_out.
Write out data from table.
loop at <dyn_table> into <dyn_wa>.
do.
assign component sy-index
of structure <dyn_wa> to <dyn_field>.
if sy-subrc <> 0.
exit.
endif.
if sy-index = 1.
write:/ <dyn_field>.
else.
write: <dyn_field>.
endif.
enddo.
endloop.
endform.
Thanks,
Shankar -
I need to know how I will create a dynamic website using php and mysql
I need to know how will I create a dynamic website using php and mysql that people could have the abilities of registering in the website, and modify their profile where they can add their pictures and everything. apart from that, they should have the ability to search about other member. hope to here more from you.
If you are a right-brained creative, and have no previous experience or propensity to be able to understand coding and database "stuff", and/or if your time can be better spent on other skills, I recommend you save your sanity and hire a developer... or at least the first time around. I have been attempting to grasp this for years... and have a library of marked up books to prove my efforts, all while trying to keep up with an ongoing client base that is always cramped. It's a wonder I still have my sanity... then again, I might not be the best person to determine that. Others might question it.
That said, I still plan to master php... one of these days. -
How to create entity for the table which is not having the primary key
Hi,
Is it possible to create an entity for the table which is not having the primary key.
I have to write a method in my session bean and that method must use this entity.
any websites for this.If you are talking about processes launched from a JVM (running outside), Process is available.
If you are talking about processes already running outside of a JVM, you could roll-your-own class to provide similar functionality as Process. This approach would be platform dependent, backed by the platform's I/O scripting and therefore limited to what the platform supports for process manipulation, e.g. Linux/Unix capabilities far exceed Windows. -
Master Child tables how to get the latest rows from both
Hi,
Need some help with the sql. I have two tables Master & Child. In my Master table I have multiple rows for the same record and in the child table also multiple rows for the same master row how can I get the latest one's from both.
For example Data in my Master table looks like
CONT_ID SEQ_NUM DESCRIPTION
1 189 Update 2
1 188 Update 1
1 187 NewNow in the child table for the same CONT_ID I may have the following rows
CONT_ID UPDATED_DATE STATUS
1 3/16/2010 2:19:01.552700 PM P
1 3/16/2010 12:29:01.552700 PM A
1 3/16/2010 12:29:01.552700 PM P
1 3/16/2010 12:19:01.552700 PM NIn my final query how can I get the row with seq_num 189 as it's the latest in Master table and from child table the row with status of P as it's the latest one based on the time. Here is the query i have but it returns the latest row from the child table only and basically repeats the master table rows as opposed to one row that is latest from both:
ThanksHi,
You can use the analytic ROW_NUMKBER function to find the latest row for each cont_id in each table:
WITH got_m_rnum AS
SELECT cont_id, seq_num, description
, ROW_NUMBER () OVER ( PARTITION BY cont_id
ORDER BY seq_num DESC
) AS m_rnum
FROM master_table
-- WHERE ... -- any filtering goes here
, got_c_rnum AS
SELECT cont_id, updated_date, status
, ROW_NUMBER () OVER ( PARTITION BY cont_id
ORDER BY updated_date DESC
) AS c_rnum
FROM child_table
-- WHERE ... -- any filtering goes here
SELECT m.cont_id, m.seq_num, m.description
, c.updated_date, c.status
FROM got_m_rnum m
JOIN got_c_rnum c ON m.cont_id = c.cont_id
AND m.m_rnum = c.c_rnum
AND m.m_rnum = 1
;If you'd like to post CREATE TABLE and INSERT statements for the sample data, then I could test this.
If there happens to be a tie for the latest row (say, there are only two rows in the child_table with a certain cont_id, and both have exactly the same updated_date), then this query will arbitrarily choose one of them as the latest. -
How to return the entire row from a table
Hi guys,
Tabl A
FirstName varchar2(10),
Age Number,
Add varchar2(100),
Table B
Filedname varchar2(200), -- contains all the fields of table A
Datatype varchar2(100), -- Contains the datatypes of the filedname
Length Number -- contains the length of the fileds
Now how can i return the entire row from table A with the datatype and its length.
Any help would be appreciated ?
Here is the query I wrote but it how to take the datatype and its length..
create or replace procedure disp_table_data
as
type r_cursor is REF CURSOR;
c_A r_cursor;
er A%rowtype;
begin
open c_A for select * from A;
loop
fetch c_A into er;
exit when c_A%notfound;
dbms_output.put_line(er.FirstName||'--'||er.Age);
end loop;
close c_A;
END;
/Guys,
I want column value from table A and its corresponding data_type and length from table B. I think I cant do it through joins.
Any idea would be appreciated ?.
Example ..
Tabl A
FirstName varchar2(10),
Age Number,
Add varchar2(100)
insert into A values('John',24,'Boston');
Table B
Filedname varchar2(200), -- contains all the fields of table A
Datatype varchar2(100), -- Contains the datatypes of the filedname
Length Number -- contains the length of the fileds
insert into B values('FirstName','varchar2',10); -- this is coming from table A.
Output should be like this...
John,Varchar2,10
Here (John is the FirstName - coming from table A, Varchar2 is a Datatype and 10 is the Length which are coming from table B ). Only column values are coming from table A , corresponding datatype and length are coming from B.
Any idea would be appreciated ?
Thanks. -
How to save the selected rows from Advance table into database
Hi
I have requirement like..
In custom page , Manager Search the Candidates and selects the candidate ROWS from advance table.
The reqt is how to save the selected multiple rows into the database.hi Reetesh,
In Custom page
Supoose the Recruiter Search is for Position Finance Mangager , it retrieves 100 rows , out of which Recruiter select 10 rows .
So in Such scenario how to save this 10 rows against Recruiter
, i mean , Is i need to create custom table, to save Recruiter , these selected 10 rows.
I hope u understand my question -
How can i create a new usb connection (service) on my iMac for sharing internet from my iPhone5 ( i seem have to deleted it )
i know its not a problem whit my carrier o data plan or sharing preferences on the ipone because when i use it un my laptop it works perfectly through
the usb and even works on the Imac through wifi and bluethood tethering but NOT through usb!!.
the problem is that trying to make it work i deleted the "profile" usb iphone on the network prefereces panel. Now i only have 3 options: ethernet / wifi / bluetooth
but not the usb iPhone i used to have.
And when i try to add a new one i dont get a USB option.
can some one help me please??
this is how it looks (after the bluetooth PAN i used to have USB iPhone option)The question would be more appropriate in the Mac forums as it is not really related to the iPhone.
Maybe you are looking for
-
I am on OS X 10.5.8 but want to upgrade to mavericks.
I am on OS X 10.5.8 but want to upgrade to mavericks. I purchased mountain lion so I could install it and then upgrade to mavericks but can't redeem my purchase voucher as I have to do it in the Mac App Store which I can't access on 10.5.8. Can anyon
-
It was possible in Adobe Acrobat IX to save always there where the original file (e.g. xxx.doc) was. The window that appears after clicking "save as ..." had always the location of the original file. How can I make this option in A.A. XI? I don't fin
-
Acrobat X crashes shortly after launch; Win7; Creative Cloud
I am on Windows 7 64bit with Creative Cloud (all updates applied) and whenever I try to open a PDF it opens for about 10 seconds, and then crashes. In fact, even if I just load Acrobat by itself (ie. not PDF opened), it still crashes shortly after. T
-
Z-Wave Interrupted by Smart Meter (ZigBee Technology)
Hi Digitial Life Community I am a current Digital Life customer and have been really happy with my service. Something unexpected happened and want to know if any of you have had this same problem. I have 4 Z-Wave devices (Smart Plug, Door Lock, Fro
-
Can anyone tell me how to delete previous "keep file" files? Im trying to free up some space on my mac.