on 2015 Dec 01 7:59 AM
Hi Experts,
I'm new to the sourcing. I have requirement like generate PDF output for Custom Tab fields in project.Please give suggestions on this
Request clarification before answering.
Hi Pakkurti,
Try below options:-
1. you can write a query/report wich will have custom field of project's as resultset(column). By default system will give you option to download the resultst as Excel or PDF. You can write a schedule task so system will send the query/report outcome to the specific user.
2. you can write scirpt (i.e. toolbar) and use "import java.io.File; " import package for I/O opearation you can generte require PDF file. With the help of doc object of current session you can read the custom filed value and write in PDF.
Please let us know the final approach you will try to meet the requirement for our future reference.
Cheers,
Deepak
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Eswar,
Check IAPI library under reference guide. System is able to generate PDF file for query output so it should have supported jar deployed in server. Please take help of basis consultant and request to locate the JAR file in server. If not able to locate then you need to deply the JAR file.
How to deploy jar:-
Please find few thread related to it:-
Or onemore thing you can do is:-
Via Eclipse write a class and put your script logic to generate PDF in it. Compile and create jar file out of it. Then as per option 3rd menioned above deploy the jar file and then you can import cutom jar in toolbar script and call the method to generate the PDF file.
Cheers,
Deepak
Hi Experts,
I have another query - How to add Collection extension in this query
SELECT <%RESULTS%>
FROM <%SCHEMA%>.FCI_PRO_PROJECTS T1
LEFT OUTER JOIN <%EXT_TABLE(projects.projects)%> T2
ON T1.OBJECTID = T2.PARENT_OBJECT_ID
WHERE
T1.CONTEXTID IN
(<%CONTEXT(projects.projects)%>)
Any suggestions on this
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Experts,
Any suggestion on this.Please help me on this.
I have another query - How to add Collection extension in this query
SELECT <%RESULTS%>
FROM <%SCHEMA%>.FCI_PRO_PROJECTS T1
LEFT OUTER JOIN <%EXT_TABLE(projects.projects)%> T2
ON T1.OBJECTID = T2.PARENT_OBJECT_ID
WHERE
T1.CONTEXTID IN
(<%CONTEXT(projects.projects)%>)
Hi Roo,
Please go through below link.
Query Definition: Attribute Substitution - SAP Sourcing - SAP Library
Regards
Peeyush
Hi Eswar,
You can also try writing a custom query and in result fields tab of query definition list down all the custom fields created under project.
In Query Definition you will have to join Project Table(class name : projects.projects) with Attribute Database Table created in Extension Definition under Project Class.
Once you list all the custom tab fields in you Query you can export the result of query definition to PDF.
Thanks,
Rajiv
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Rajiv,
As per your suggestion I try to build query.But I'm facing error in this query can you please help me on this.
SELECT <%RESULTS%> FROM <%SCHEMA%>.FCI_PRO_PROJECTS T1 <%SCHEMA%> LEFT OUTER JOIN <%SCHEMA%>.<%EXT_TABLE(projects.projects)%> T2 ON T1.OBJECTID = T2.PARENT_OBJECT_ID WHERE T1.CONTEXTID IN (<%CONTEXT(projects.projects)%>) <%ORDERBY%>
Hi Eswar,
I used the below query and it is working fine for me.
SELECT <%RESULTS%>
FROM <%SCHEMA%>.FCI_PRO_PROJECTS T1
LEFT OUTER JOIN <%EXT_TABLE(projects.projects)%> T2
ON T1.OBJECTID = T2.PARENT_OBJECT_ID
WHERE
T1.CONTEXTID IN
(<%CONTEXT(projects.projects)%>)
Can you please look at the query definition you are using or share a screenshot that will help to analyze if there is any change in your query definition.
Thanks & Regards,
Rajiv Yadav.
Hi Eswar,
Column ID is used when a column definition needs to be identified by a unique name.The form of Column ID which is usually followed is TableAlias.COLUMN_NAME.
The Column ID is the same as the Database Column Name field when the database column name is a simple column name. For all other column definitions that do not correspond to a database column name, such as an expression that includes an SQL function or a concatenation operator, use a unique string as the Column ID, in UpperCamelCase format. For example, “UpperDisplayName” is an appropriate Column ID value for UPPER(T1.DISPLAY_NAME).
Thanks & Regards,
Rajiv.
Hi Eswar,
If I got your doubt correctly,you want to get the output for a single business document.For this you can add a filter prompt to your query definition where the user can enter the document id and your query definition can then fetch data related to that particular business document only.
Thanks & Regards,
Rajiv Yadav.
Thanks Rajiv Yada ,
Your suggestions very helpful for me.I have another query - How to add Collection extension in this query
SELECT <%RESULTS%>
FROM <%SCHEMA%>.FCI_PRO_PROJECTS T1
LEFT OUTER JOIN <%EXT_TABLE(projects.projects)%> T2
ON T1.OBJECTID = T2.PARENT_OBJECT_ID
WHERE
T1.CONTEXTID IN
(<%CONTEXT(projects.projects)%>)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.