Multiple tables and templates in a main window
Hi,
Is it possible to have multiple tables and templates in a main window of a smartform?
If so then how they are positioned in the main window? Means which table to come first and which to be the next?
Thanks in advance.........
Prinan
Hi!
both tables and templates can be printed any number of times ina main window.
The tables as in sequence are printed...after ending with the first it gets on to the another.
If u want to print it under some cdonditions you can do it using the condition tabs.As per it is a main window the dats gets flowing to the next page so as the order goes thae data goes on printed.
Regards.
Similar Messages
-
Calling pages and more than 1 main window
Hi All,
Hi All,
I am designing a Smartform.It contains 2 sections.In 1st section
page1 contains only templates and no main window.On page2 i have
4 dynamic tables which i have included in main window.If the data
is large content of page2 extends to page3.Now the 2nd section begins.I
have to display details of various materials. page4 again contains
templates and no main window.Page5 contains again 4 dynamic tables
and if the data is large it can extend to page6.Ideally these 4 tables
should be included in main window.but i already have 1 main window in
page2.As per my knowledge in 1 smartform there can be only 1 main window.
So please suggest any way to do this.
1 more thing.....
As i said in 2nd section i am displaying details of materials-- page4,
page5,page6 display details of only 1 material.These 3 pages--page4,page5
page6 should repeat for other materials also.
How do i achieve this.
Thanks and Regards,
Shital Chheda.Hi
The Solution can be achieved but in a different way.
Let the First Page be fired as ur default page and at the end of the first page call the command to go to the 2nd Page.
In the 2nd Page call the Main Window once and print the information for the first Table, this is fine.
After that comes the Second Section, in this i hope that you a single table for printing the material Specific data, the number of lines that can be displayed in a A4 page is approx 70, so you can find out the number of lines remaining to be printed in the page for the table and print data conditionally based on this data.
Hope that Helps
Anirban M. -
Diffrence between Table and Template In Smartform
Hi,
Please could u tel me Difference between Table and Template In SmartformTable exteds dynamically.
Template is fixed in size.
template is Output of a table containing static data
these are the Possible direct successors-All except window, page, table,
and template nodes
Table - Output of a table containing application
data and these are the Possible direct successors-as with template node
Template is used for proper allignment of data which table is used for displaying multiple data.
We can say Template is for static data and Table is for dynamic data.
Suppose we have a requirement in which we have to allign the customer address in such a way as shown below:-
Name- Krishna Company- WIPRO Location- Chennai
Desig- S/W Native - Mumbai
Then for proper allighnment we can create a template and split that into 3 columns and 2 rows and create text elements for each cell display a proper allighned data at the output.
When we include a template inside a loop it gives the same property as a table.
When we have mutiple data which is to be extended to the next page like when we display all employee details in a company we use table.
Table has 3 sections , HEADER, ITEM ,FOOTER
The header secntion will be executed once and it will loop at the item level. at the end footer will be executed.
SmartForms Useful links
http://www.sapgenie.com/abap/smartforms.htm
http://www.sap-img.com/smartforms/sap-smart-forms.htm
http://help.sap.com/saphelp_46c/helpdata/en/a5/de6838abce021ae10000009b38f842/frameset.htm
http://help.sap.com/printdocu/core/Print46c/en/Data/htm/english.htm
http://www.sap-img.com/smartforms/smart-001.htm
http://www.sap-img.com/smartforms/smartform-tutorial.htm
http://www.sap-img.com/smartforms/smart-002.htm
http://www.sapgenie.com/abap/smartforms.htm
http://www.sap-img.com/smartforms/sap-smart-forms.htm -
Diff. between table and template in smartforms
hi there,
please tell me what the diff. between table and template options available in smartformsHI
GOOD
TABLES=>
In forms of business procedures you usually want to list details such as open items of an invoice. You can use a Smart Form to display this data in a table. You can design the layout of the table independent of the number of lines it will contain. The size of the table depends on how much data the application program passes to the form at runtime (unlike with templates, where you specify the number of columns and lines explicitly). The table can cover one or more pages, depending on the number of lines. This is why you display tables in the main window.
TEMPLATES=>
Use node type Template to display a table whose layout and size (number of lines and columns) is determined before the runtime of the application program. For this reason, a template is also called a static table.
To create a template, define a table layout to determine the cell structure for each line. The cells are used to display the contents of the inferior nodes of the template node. This allows you to position text and a graphic side by side (see Displaying Graphics in Templates).
The template node is also suited for label printing.
GO THROUGH THIS LINK
http://help.sap.com/saphelp_nw04/helpdata/en/4b/83fb4edf8f11d3969700a0c930660b/content.htm
THANKS
MRUTYUN -
Dbms_xmlgen.newcontext query from multiple tables and ||
I have two questions
How do I get a dbms_xmlgen.context to query from multiple tables? I have been able to make it work with using one table only, but not with multiple tables.
And how to get the || (concat) to work within my query for my output to an xml file?
Here is my current query:
create or replace function get_xml return clob is
result clob;
qryctx dbms_xmlgen.ctxHandle;
SELECT DBMS_XMLGEN.getxml('select prefix, suffix, fiscal_yr
FROM rcv.recv_accessions ra
where ra.prefix = 8 and ra.fiscal_yr = 11')xml into result FROM dual;
result := DBMS_XMLGEN.getXML(qryCtx);
This is what I desire:
SELECT DBMS_XMLGEN.getxml('select ra.prefix||'-'|| ra.suffix||'-'|| ra.fiscal_yr accession, ss.date_in, st.test
FROM rcv.recv_accessions ra, ser.sero_samples ss, ser.sero_tests st
where ra.prefix = 8 and ra.fiscal_yr = 11 and ss.raid = ra.id and st.ssid = ss.id')xml into result FROM dual;
On this both the reference to multiple tables and the concat function cause errors.
Thank you
Edited by: user583094 on Mar 2, 2011 3:36 PMHi,
for the concat do I use xmlconcat?No, XMLConcat is used to concatenate XMLType fragments.
The || operator will do fine, but you must escape any single quote inside the string :
SELECT DBMS_XMLGEN.getxml(
'SELECT ra.prefix ||''-''|| ra.suffix ||''-''|| ra.fiscal_yr as accession,
ss.date_in,
st.test
FROM rcv.recv_accessions ra,
ser.sero_samples ss,
ser.sero_tests st
WHERE ra.prefix = 8
AND ra.fiscal_yr = 11
AND ss.raid = ra.id
AND st.ssid = ss.id'
INTO result
FROM dual;Or, use the quoting operator to define a custom string delimiter :
SELECT DBMS_XMLGEN.getxml(
q'{SELECT ra.prefix ||'-'|| ra.suffix ||'-'|| ra.fiscal_yr as accession,
ss.date_in,
st.test
FROM rcv.recv_accessions ra,
ser.sero_samples ss,
ser.sero_tests st
WHERE ra.prefix = 8
AND ra.fiscal_yr = 11
AND ss.raid = ra.id
AND st.ssid = ss.id
INTO result
FROM dual;BTW, a good practice would be to use bind variables for the query. DBMS_XMLGEN can handle them nicely :
CREATE OR REPLACE FUNCTION get_xml
RETURN CLOB
IS
qryctx DBMS_XMLGEN.ctxHandle;
v_out CLOB;
qrystr VARCHAR2(4000) :=
'SELECT ra.prefix ||''-''|| ra.suffix ||''-''|| ra.fiscal_yr as accession,
ss.date_in,
st.test
FROM rcv.recv_accessions ra,
ser.sero_samples ss,
ser.sero_tests st
WHERE ra.prefix = :b_prefix
AND ra.fiscal_yr = :b_fiscal_yr
AND ss.raid = ra.id
AND st.ssid = ss.id';
BEGIN
qryctx := DBMS_XMLGEN.newContext(qrystr);
DBMS_XMLGEN.setBindValue(qryctx, 'b_prefix', '8');
DBMS_XMLGEN.setBindValue(qryctx, 'b_fiscal_yr', '11');
-- to generate empty elements if necessary :
DBMS_XMLGEN.setNullHandling(qryctx, DBMS_XMLGEN.EMPTY_TAG);
v_out := DBMS_XMLGEN.getXML(qryctx);
DBMS_XMLGEN.closeContext(qryctx);
RETURN v_out;
END; -
Import Table and Template Table
Hi all,
I have a question regarding Data Services Component. What are the difference between "Import Table" and "Template Table"?
Thanks,Hi,
Template table means temporary table. It will take all the input data. We don't need to create this table. Import table means you are importing already created table. That means you had already defined the field names and field lengths. Hope this helps.
Thanks, -
Table and template in smartforms
what r the diff.s between TABLE AND TEMPLATE in smartforms..
ALso.. the diff. between LOOP and TABLE.. in smartforms..Hi,
Template :
1. No of rows & coloumns are fixed.
2. u can directly mention, which data has to be fill in which row & coloumn.
3. Templates are used, where u r having static no of data.
( ex : Name, rollno, age, ***)
4. No header & footer
Table :
1. No of cols are fixed, u can have 'n' no of rows.
2. it has header & footer concept
A table is meant to be used to display dynamic number of lines (eg. invoice line items), whereas a template is for fixed number of column and lines (labels).
Please reward points if it helps
Thanks
Vikranth -
In smart forms-- difference between table and template
can you please tell me what is the difference between table and template in smart forms,
and als give me some object developed in smart forms.it is not recommended because, when ever we activate the smartform it generates one function module.
if we transport that driver program and smartform to testing or production, in that server the generated function module name will be differ.
hope u got it.
for this we need to use these function modules.
SSF_FUNCTION_MODULE_NAME
FM_NAME
regards.
santhosh reddy
reward if useful
Edited by: Santhosh Reddy on Feb 16, 2008 7:52 PM -
What is exact difference between table and template in script
hello all
what is exact difference between table and template in scriptHi there.
Tables alow you to achieve more complex flows with internal tables. You can use different types os lines, like footer, header, line items, and differente types of line items. Also, and most important, you have different processing blocks, again header block (processed before processing of first row), body block (rows) and footer block (after last row or page break).
If you don't need any of this, use a template inside a loop to achieve something like a table. I personaly use templates only to draw lines, for example, before and after a loop, or to align some header in my documents.
A table, is a loop and template mixed to become a very good tool.
Regards.
Valter Oliveira.
Edited by: Valter Oliveira on Jun 5, 2008 5:10 PM -
Read header text from vf01 and print in script main window
Hi Gurus,
I need to read text from vf01 header note 1, there user type max 10 lines i want to read that 10 lines and print in sap script main window after line item printed. i used read text but one line only fetched. i declare variable like data : NEXRSP LIKE TLINE-TDLINE and read_text function module. pls provide solution for this.
Regards
G.VendhanHI GURUS,
Thank u for reply i declare like
ID = '0002'.
PERFORM READTEXT USING EN NAME OBJECT ID TEXT_OUTPUT.
NEXRSP = TEXT_OUTPUT . CLEAR TEXT_OUTPUT.
FORM READTEXT USING P_EN
P_NAME
P_OBJECT
P_ID
P_TEXT_OUTPUT.
CALL FUNCTION 'READ_TEXT'
EXPORTING
CLIENT = SY-MANDT
ID = P_ID
LANGUAGE = P_EN
NAME = P_NAME
OBJECT = P_OBJECT
TABLES
LINES = LINES
EXCEPTIONS
ID = 1
LANGUAGE = 2
NAME = 3
NOT_FOUND = 4
OBJECT = 5
REFERENCE_CHECK = 6
WRONG_ACCESS_TO_ARCHIVE = 7
OTHERS = 8.
LOOP AT LINES.
P_TEXT_OUTPUT = LINES-TDLINE.
EXIT.
ENDLOOP.
FREE LINES. CLEAR LINES.
ENDFORM. " READTEXT -
Linking multiple tables and Trying to insert records into Detail
Hello,
I have been struggling with this one for years...
Work Order, Employee Labor, and Materials. I then create a group headers using the Location field from the Work Order table. I then create another Group, suppress the group name, and insert several fields from the Work Order table (work order number, wo description, status and completion date into Group 2 section. Multiple rows of info are displayed. I then enter some Employee Labor fields from the Labor table into the Details section (employee name, labor hours, pay rate, etc.). I get several lines of employee labor transaction information grouped below each row of work order info from the Group 2 section. So far, so good.
Now I attempt to bring a field into the Details section from the 3rd table (Materials). The moment I introduce the record, the rows of employee labor are duplicated over and over. In fact, there are multiple duplicate labor transaction rows (over and over).
What am I doing wrong??? I've tried every combination of Linking Order that I can think of... I need help.
Please reply.
ps. Let me know if I need to attach a screen shot.
Thank you
Roberthi Robert,
this is a common issue when you add several details tables to a report. once you add the fields, then the sql generated will include those parent tables and you get a multiplier of records.
my recommendation to you would be to use a subreport for the materials table instead.
go to the Insert menu, choose Subreport and create a new subreport using the Wizard then add your current connection but this time only add the materials table. in the Linking tab, choose your Work order and then add the subreport to the Work order group header. now in the subreport add some fields from your materials table onto the subreport canvas.
what this is essentially doing is a subquery to the database and returning all associated materials records based on a filter for the work order.
the main report should not include any materials records and you can also remove this table from the database expert for the main report.
i hope this helps,
jamie -
Search a text in a multiple tables and one table has BLOB column
Hi,
I couldn't find a solution/examples for below scenario in oracle text documentation or related forums.
I need to search a text in a multiple tables,in that one table has blob column which is used to store the documnents(pdf,doc,jpg..etc) and other tables have varchar2 columns,These tables have realation each other.
Please provide a sample examples for above scenario.
Thanks in advance..Have a look at my blog entry here:
https://blogs.oracle.com/searchtech/entry/indexing_data_from_multiple_tables
That describes two methods of achieving what you are looking for. -
User Datastore for multiple tables and columns!
Hi,
I hop so much, someone can help me.
I've made a user datastore to index multiple columns of multiple tables.
Now, the Documentation of Oracle explains the idexing of one table.
I have multiple tables, which have all, the columns descr and tagnr. I want to make a query sth like this:
select table1.column, table2.columnd... where contains(indexed field,'gas within descr',1)>0
is it possible to index 4 seperate tables, without having a collective key? I dont want to make a Concatenated Datastore.
I have wrote this code.
But it doesn't work. It's been compiled fine. But I don't get any result with my queries.
create or replace
procedure My_Proc_Wide
Must be in ctxsys schema.
In a full-scale example, this would be a wrapper
for a proc in the user schema.
rid in rowid,
tlob in out NOCOPY clob /* NOCOPY instructs Oracle to pass
this argument as fast as possible */
is
v_descr varchar2(80);
v_tagnr varchar2(30);
v_descr_name constant varchar2(20) := 'descr';
v_descr_start_tag constant varchar2(20) := '<' || v_descr_name || '>';
v_descr_end_tag constant varchar2(20) := '</' || v_descr_name || '>';
v_tagnr_name constant varchar2(20) := 'tagnr';
v_tagnr_start_tag constant varchar2(20) := '<' || v_tagnr_name || '>';
v_tagnr_end_tag constant varchar2(20) := '</' || v_tagnr_name || '>';
v_buffer varchar2(4000);
v_length integer;
begin
/* verify the env which called this */
if Dbms_Lob.Istemporary ( tlob ) <> 1
then
raise_application_error ( -20000,
'"IN OUT" tlob isn''t temporary' );
end if;
/* the real logic */
/* first tabel to be indexed */
select t1.tagnr, t1.descr
into v_tagnr, v_descr
from tweb.pdp_positions t1
where t1.rowid = rid;
v_buffer := v_tagnr_start_tag ||
v_tagnr ||
v_tagnr_end_tag ||
v_descr_start_tag ||
v_descr ||
v_descr_end_tag;
v_length := length ( v_buffer );
Dbms_Lob.WriteAppend(tlob, length(v_buffer) + 1, v_buffer || ' ');
/* second table to be indexed */
select t2.tagnr, t2.descr
into v_tagnr, v_descr
from tweb.pdp_schema_equ t2
where t2.rowid = rid;
v_buffer := v_tagnr_start_tag ||
v_tagnr ||
v_tagnr_end_tag ||
v_descr_start_tag ||
v_descr ||
v_descr_end_tag;
v_length := length ( v_buffer );
Dbms_Lob.WriteAppend(tlob, length(v_buffer) + 1, v_buffer || ' ');
/*third table to be indexed */
select t3.tagnr, t3.descr
into v_tagnr, v_descr
from tweb.pdp_equipment t3
where t3.rowid = rid;
v_buffer := v_tagnr_start_tag ||
v_tagnr ||
v_tagnr_end_tag ||
v_descr_start_tag ||
v_descr ||
v_descr_end_tag;
v_length := length ( v_buffer );
Dbms_Lob.WriteAppend(tlob, length(v_buffer) + 1, v_buffer || ' ');
/* fourth table to be indexed */
select t4.tagnr, t4.descr
into v_tagnr, v_descr
from tweb.pdp_Projcode t4
where t4.rowid = rid;
v_buffer := v_tagnr_start_tag ||
v_tagnr ||
v_tagnr_end_tag ||
v_descr_start_tag ||
v_descr ||
v_descr_end_tag;
v_length := length ( v_buffer );
Dbms_Lob.WriteAppend(tlob, length(v_buffer) + 1, v_buffer || ' ');
end My_Proc_Wide;
what have I to do, to make this work?
Any Help would be appriciated!!
Kind Regards,
ArsinehArsineh,
I realise that it has been quite some time since you posted this question but I thought I'd reply just in case you never did manage to get your user datastore working.
The reason your procedure will not work is simple. A user datastore procedure accepts a rowid input parameter. The rowid is the ID of the row that Oracle Text is currently trying to index. In the example you have given, you are attempting to use the supplied rowid as the primary key for multiple tables, this will simply never work as the rowid's across multiple tables will never correspond.
The best way to achieve your goal is to create the index on a master table which contains the common primary keys for each of your four tables e.g.
MASTER_TABLE
COL:COMMON_KEY (NUMBER(n))
COL:USER_INDEX_COLUMN (VARCHAR2(1))
If you create the user datastore index on the MASTER_TABLE.USER_UNDEX_COLUMN column your stored proc simply needs to read the correct row from the MASTER_TABLE (SELECT t.common_key into v_CommonKey FROM master_table t WHERE t.rowid = rid) and issue subsequent queries to extract the relavant data from the t1..t4 tables using the common key e.g.
SELECT t1.tagnr, t1.descr into v_tagnr, v_descr FROM t1 WHERE t1.[PRIMARY_KEY_FIELD] = v_CommonKey;
SELECT t2.tagnr, t2.descr into v_tagnr, v_descr FROM t2 WHERE t2.[PRIMARY_KEY_FIELD] = v_CommonKey;
and so on...
Hope this helps
Dean -
ALV for fields from multiple tables and make them editable
Hi,
I am working on a forecasting report. We have created few custom table e.g. store forcaset detail for whole year month wise. tables are say sales data, budget data, forcast data etc.
Now i need to make a report based on monthwise based on above mention table.
eg.o/p looks like:
column name type desc monthapr monthmay .......
table forcast Qty sales 100 150
table budget/sales amt amou 20.50 130.50
table sales vs forcast amt amount 3000 50000
-Now i don't know how to display data from multiple table in single ALV list that to with different field type.
-2nd issue is i need to make only perticuler row editable so that user can chage data.
-3rd when user change data and press calulate button - it should calculate data for future month - i got formula for that and disply the calulated data.
- 4th if user like the forcast data then when press save - change data should update dbtable.
Is this all possible with simple abap FM Or need to use ABAPOO.
I will appericiate all expert help.
Many thanks in advance.
KDE.
Edited by: kde_test on Jun 4, 2010 5:44 PMHi,
Solutions :
1. You can use FM REUSE_ALV_HIERSEQ_LIST_DISPLAY as guided by Ashutosh.
You can also check out this
[http://www.sap technical.com/Tutorials/ABAP/3DGraph/demo.htm] change link to saptechnical without space
2. [How to make certain rows in ALV grid editable...;
3 & 4. Use two importing paramaters 'PF_STATUS_SET' 'USER_COMMAND' of REUSE_ALV_GRID_DISPLAY.
create two function codes 'CALC and 'SAVE' in pf-status and provide your required functionality to these function codes using User-Command.
Sorry am unable to provide you with supporting code, but you can search for it and It can solve your problem
Regards,
Rohit -
Dear All,
My database is 11gR1 and Linux is the platform.
I have more then 50 very important tables and around 15 database users.
I want to implement fine grained auditing on these important tables.
This is how I am going to implement it:
SQL>BEGIN
DBMS_FGA.add_policy(
object_schema => 'Scott',
object_name => 'SAL',
policy_name => 'SALARY_CHK_AUDIT',
audit_condition => NULL,
handler_schema => 'imran',
statement_types => 'SELECT,INSERT,UPDATE,DELETE',
audit_column => NULL);
END;
what is i have to pass multiple tables in object_schema and multiple users in handler_schema.
I hope i am able to clear my question, any doubts please let me know.
Regards, ImranHi,
object_schema - The schema of the object to be audited. (If NULL, the current log-on user schema is assumed.)
in case if you like to audit for multiple users - then try to test by holding a null value and test access the important tables -where the relevant auditing records are generated as per your requirement or not. i have not tested.. try it
- Pavan Kumar N
Maybe you are looking for
-
Why don't some of my .ttf fonts appear in the font menu?
Hello, I have a number of .ttf fonts installed on my system (located in Win7/Windows/Fonts folder) which do not appear in Flash or other Adobe applications such as InDesign. I did try putting them in the Fonts folder of these programs instead of the
-
How to hook my camera to my laptop?
I got Sony HDV 1080i and i tried to feed the 'easy setup' on my fcp but it wont show the picture. I struggled with it for an hour! please help me!
-
"Back in the day" when we had OSX server, perhaps version 10.1 , running with Macintosh Manager there was a utility called File Blaster which could be used to send or "blast" files into special places we might need. For example if we wanted to put so
-
I want to import old QT movies (MPEG-1) to Final Cut Pro 3 but when imported they are without sound. What can be the problem or how can I configurate FCP to import correctly the movies ? Elsa
-
I'm trying to get bluetooth working with my new laptop. I've looked at the wiki, but it doesn't seem to help