Data getting truncated while exporting report to a text file in crystal 10?
Hi All,
I am using crystal 10.When exporting report to a text file ,a dialog prompts asking for Character perinch with a default value 9.If I change the value from 9 to 16 i am getting the correct data(that means character per inch value is 16) and it update "CharPerInch" value in registry under following location to 16.
HKEY_CURRENT_USER\Software\Crystal Decisions\10.0\Crystal Reports\Export\Text
The dialog asked for character per inch also has option to select not to prompt again and i also selected that in first go.
When i export the report again in text format it didn't prompt for number of character per inch but the data gets truncated.
What i believe is even though it updates entry in registry and reads, it is not using the same value for export. It never consider the value that is in registry, if the check box is not selected then it is using the value entered in the dialog and if the check box is selected then in the next run it uses the default value as 9.
Can anyone suggest me how to override this problem ? Is there any other setting place in registry where i can enter the number of character per inch.I don't want to crystal to prompt always for character per inch.
Hi Venkateswaran,
The other option to avoid truncation of the data could be
Right click the text filed
Click on Format Text to open the Format Editor
On Common tab check the text box for Can Grow.
This will prevent the data from truncating in preview as well as while exporting to text.
Otherwise you will have to set the characters per inch to 16 each time. I donu2019t see changing the registry value causing any difference here.
Regards,
Aditya Joshi
Similar Messages
-
Zero is getting truncated while XI is creating a CSV file
Hi,
Scenario is IDOC to File.
in the IDOC i get some Serial number as 00000007856465 in the output CSV file i need this value as 07856465
Here when i run this map in the ESR Message mapping i could see 07856465 this value fine but while posting at the output directory the values are dropped with zeros truncated.
in the output CSV file -- the value is -- 7856465
Could you please help me out in solving this issue.
Thanks,
--Sai.Hi Sai Krishna,
As said by Bhaskar, use Formatnum function or UDF in your mapping. So that you would be able to get the 0's in the output.
I would prefer to go with FormatNum function.
Check the UDF provided by Raja Shekar in the below thread:
UDF for leading zero's in message mapping
Thanks, -
Getting error While attaching Report out put Pdf file to POAPPRV workflow
I am getting below error in workflow
Item Type = POAPPRV
Item Key = 60383-243513
User Key =40515
Error Name = WF_ERROR
Error Message = [WF_ERROR] ERROR_MESSAGE=3835: Error '-20002 - ORA-20002: [WFMLR_DOCUMENT_ERROR]' encountered during execution of Generate function 'WF_XML.Generate' for event 'oracle.apps.wf.notification.send'. ERROR_STACK=
GNE_PO_CREATE_FILE_ATTACHMENT.Gne_Create_File_Attachment(60383-243513 OAPPRV, text/html)
Wf_Notification.GetAttrblob(207046, PO_REPORT, text/html)
WF_XML.GetAttachment(207046, text/html)
WF_XML.GetAttachments(207046, http://gnedxbebsdev.gerab.ae:8003/pls/DEV, 850
WF_XML.GenerateDoc(oracle.apps.wf.notification.send, 207046)
WF_XML.Generate(oracle.apps.wf.notification.send, 207046)
WF_XML.Generate(oracle.apps.wf.notification.send, 207046)
Wf_Event.setMessage(oracle.apps.wf.notification.send, 207046, WF_XML.Generate)
Wf_Event.dispatch_internal()
Error Stack =
Activity Id = 124108
Activity Label = NOTIFY_APPROVER_SUBPROCESS:GNE_PO_NOTI_TO_CEO
Result Code = #MAIL
Notification Id = 207046
The Code used in procedure is given below
procedure Gne_Create_File_Attachment (document_id in varchar2,
display_type in varchar2,
document in out blob,
document_type in out varchar2)
is
l_itemtype varchar2(100);
l_itemkey varchar2(100);
l_output_directory varchar2(30);
l_filename varchar2(255);
src_loc bfile;
bdoc blob;
src_offset number := 1;
dst_offset number := 1;
amount number;
l_request_id varchar2(100);
begin
l_itemtype := substr(document_id, 1, instr(document_id, ':') - 1);
l_itemkey := substr(document_id, instr(document_id, ':') + 1, length(document_id) - 2);
select attribute4
into l_request_id
from po_headers_all
where to_char(PO_HEADER_ID)=l_itemtype;
l_output_directory := 'APPLCSF/APPLOUT';
l_filename := 'o'||l_request_id;
src_loc := bfilename(l_output_directory,l_filename);
dbms_lob.createTemporary(bdoc, FALSE, dbms_lob.call);
dbms_lob.fileopen(src_loc, dbms_lob.file_readonly);
dbms_lob.loadblobfromfile(bdoc,src_loc,dbms_lob.lobmaxsize,src_offset,dst_offset);
dbms_lob.fileclose(src_loc);
amount := dbms_lob.getLength(bdoc);
dbms_lob.copy(document,bdoc,amount,1,1);
document_type := 'application/pdf; name=attach.pdf';
EXCEPTION
WHEN OTHERS THEN
wf_core.CONTEXT('GNE_PO_CREATE_FILE_ATTACHMENT'
,'Gne_Create_File_Attachment'
,document_id
,display_type);
RAISE;
end GNE_Create_File_Attachment;
PROCEDURE Gne_Assign_wf_Attribute(
itemtype IN VARCHAR2,
itemkey IN VARCHAR2,
actid IN NUMBER,
funcmode IN VARCHAR2,
resultout OUT NOCOPY VARCHAR2)
IS
v_user_name varchar2(100);
BEGIN
IF FUNCMODE = 'RUN' THEN
wf_engine.setitemattrdocument
(itemtype => itemtype
, itemkey => itemkey
, aname => 'PO_REPORT'
, documentid =>'PLSQLBLOB:GNE_PO_CREATE_FILE_ATTACHMENT.GNE_Create_File_Attachment/'
|| itemkey
|| ':'
|| itemtype);
end if;
EXCEPTION
WHEN OTHERS THEN
wf_core.CONTEXT('GNE_PO_CREATE_FILE_ATTACHMENT'
,'Gne_Assign_wf_Attribute'
,itemtype
,itemkey);
RAISE;
END Gne_Assign_wf_Attribute;
Can Any Body Please help me....
It is very urgent..
Thanks In Advance
Anil KumarThere are two ways to look at what error the PLSQLBLOB API is throwing.
1) Call your PLSQLBLOB API GNE_PO_CREATE_FILE_ATTACHMENT.Gne_Create_File_Attachment directly from a PLSQL block and verify that it returns the BLOB data successfully.
You could also call another WF API that in turn executes the PLSQLBLOB API internally. For example,
<pre>
declare
l_document blob;
l_doctype varchar2(240);
l_aname varchar2(90);
begin
dbms_lob.CreateTemporary(l_document, true, dbms_lob.Session);
-- 207046 - This is the notification id of your failed workflow
-- PO_REPORT - Document type attribute
-- 'text/html' - Content Type being generated for
Wf_Notification.GetAttrBLOB(207046, 'PO_REPORT', 'text/html', l_document, l_doctype, l_aname);
-- Print the size of the document here to verify it was fetched correctly
end;
</pre>
2) Turn on log for SYSADMIN user with following attributes.
Log Enabled = TRUE
Log Level = ERROR
Log Module = wf.plsql%
Restart the Workflow Deferred Agent Listener and Workflow Notification Deferred Agent Listener and run your workflow process. Search for log messages written for above context and you can identify the error at wf.plsql.WF_XML.GetAttachment module with message starting as "Error when getting BLOB attachment ->"
Hope this helps.
Vijay -
Suppressing hyperlinks while exporting reports to xcel , pdf, etc etc
Post Author: SankhadipBiswas
CA Forum: Exporting
My
reports have hyper links in them. While exporting reports the hyper
links are also getting exported and I don't want to export those hyper
links. Please can any body tell me how to suppress those hyper links.Unfortunately, it looks like that font has many issues. Googling 'Univers Condensed Fonts .net' gets a number of interesting posts. E.g.;
Univers 67 Bold Condensed Font does not show in my Flash Fonts List
See if you can select the font in the properties window of the VS.NET IDE.
It would also be interesting to see if the following will work in a new test app:
Private Sub Form1_Load(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles MyBase.Load
Label1.Font = New Font("Univers 57 Condensed Font – Univers 57 Condensed", 12, FontStyle.Regular)
End Sub
- Ludek -
Indesign getting crash while exporting because of bad pdf inside file.
Hi,
My indesing is getting crash while exporting to pdf. I have link to pdf file inside the indesign file, when i export that indesign file to pdf indesign is getting crash without showing any error message. If i place another pdf file in same location then it is going fine and i can able to get the output pdf file. Please suggest me how can i check and correct that pdf file and is there any solution to this. Please help me i have thousands of indesign pages with the same issue. If you want pdf i can send it to your mail id. please i need fix for this problem.
Thanks
KiranFor all of you lurkers, Kiran sent me a copy of the PDF, and it looks like I found the problem (and learned a new technique which may help others in the same boat).
I tried re-frying the file by creating an eps and distilling, but the result was the same, then I tried exporting from CS3, just for fun, and it worked, but I realized the PDF had been cropped, so I started trying differnt sections and isolated an area that failed, though that wasn't particularly helpful.
Acrobat preflight didn't find anything that looked odd or problematic, and then I decided to run Examine Document. It came up with MetaData (no surprise) and also two items under a heading of Deleted and Cropped objects, with no preview or description. I unselected the MetaData from the list of found stuff, them clicked the Remove button in the Examine Document panel, and resaved (and while you have the opportunity to give it a new name, doing so doesn't remove the stuff untill you do the whole procedure again and save with the same name). Placed the new version of the PDF in a new file and exported no problem. -
Getting error while installing reporting servcies on existing sql server 2012.
Hi Expaerts,
sql 2012 sp1:
getting error while installing Reporting services on existing sql server. at final step
Error on scren: install_rsharepoint_cpu64_action : roll back , rolling back action.
error on popup windows: ' one or more files required to restore your computer to its previous state colud not be found. restoration will not be found.
Thanks in advance.Hello,
Please help to collect the useful log information while install SQL Server Reporting Services. Here is the article for your reference, please see:
Navigating the Setup Logs when you install SQL Server 2012 Reporting Services:
http://blogs.msdn.com/b/jtarquino/archive/2012/03/14/navigating-the-setup-logs-when-you-install-sql-server-2012-reporting-services.aspx
Regards,
Elvis Long
TechNet Community Support -
Is it possible to create a Data Driven Subscription report as a text file output to a shared folder? Thanks.
KahluaHi Vicky:
Thank you for your reply. I changed the config file in SSRS and it works. I managed to generate a text file with Data Driven Subscription as the report output in a shared folder. However is it possible not to have the "double quote" wrapping around
the text. Do I need to modify the config file to remove the "double quote" and how. Thanks.
Kahlua
<Render>
<Extension Name="XML" Type="Microsoft.ReportingServices.Rendering.DataRenderer.XmlDataReport,Microsoft.ReportingServices.DataRendering"/>
<Extension Name="NULL" Type="Microsoft.ReportingServices.Rendering.NullRenderer.NullReport,Microsoft.ReportingServices.NullRendering" Visible="False"/>
<Extension Name="CSV" Type="Microsoft.ReportingServices.Rendering.DataRenderer.CsvReport,Microsoft.ReportingServices.DataRendering"/>
<Extension Name="PDF" Type="Microsoft.ReportingServices.Rendering.ImageRenderer.PDFRenderer,Microsoft.ReportingServices.ImageRendering"/>
<Extension Name="TAB" Type="Microsoft.ReportingServices.Rendering.DataRenderer.CsvReport,Microsoft.ReportingServices.DataRendering">
<OverrideNames>
<Name Language="en-US">TAB (Tab Delimited Text File)</Name>
</OverrideNames>
<Configuration>
<DeviceInfo>
<FieldDelimiter xml:space="preserve">[TAB]</FieldDelimiter>
<UseFormattedValues>True</UseFormattedValues>
<NoHeader>True</NoHeader>
<FileExtension>txt</FileExtension>
<Qualifier xml:space="preserve"></Qualifier>
<ExcelMode>False</ExcelMode>
</DeviceInfo>
</Configuration>
</Extension>
<Extension Name="RGDI" Type="Microsoft.ReportingServices.Rendering.ImageRenderer.RGDIRenderer,Microsoft.ReportingServices.ImageRendering" Visible="False" LogAllExecutionRequests="False"/>
<Extension Name="HTML4.0" Type="Microsoft.ReportingServices.Rendering.HtmlRenderer.Html40RenderingExtension,Microsoft.ReportingServices.HtmlRendering" Visible="False" LogAllExecutionRequests="False"/>
<Extension Name="MHTML" Type="Microsoft.ReportingServices.Rendering.HtmlRenderer.MHtmlRenderingExtension,Microsoft.ReportingServices.HtmlRendering"/>
<Extension Name="EXCEL" Type="Microsoft.ReportingServices.Rendering.ExcelRenderer.ExcelRenderer,Microsoft.ReportingServices.ExcelRendering"/>
<Extension Name="RPL" Type="Microsoft.ReportingServices.Rendering.RPLRendering.RPLRenderer,Microsoft.ReportingServices.RPLRendering" Visible="false" LogAllExecutionRequests="false"/>
<Extension Name="IMAGE" Type="Microsoft.ReportingServices.Rendering.ImageRenderer.ImageRenderer,Microsoft.ReportingServices.ImageRendering"/>
<Extension Name="WORD" Type="Microsoft.ReportingServices.Rendering.WordRenderer.WordDocumentRenderer,Microsoft.ReportingServices.WordRendering"/>
</Render> -
Export Screen to Flat Text file
Hello,
I'm very new in SAP and need to modify a little program.
I would like to export the current screen in a flat text file.
The file must be stored on the SAP server ( /usr/sap/data/bel) so not on my local harddrive.
I searched and found found functions like WS_download and GUI_download, but I'm not sure how to use them. Can somebody help me please?
Curent Code of my report:
REPORT ZAT_CLRDEP01.
Tables declaration
tables : vbrp,bkpf,bseg.
Data declaration
data: begin of itab1 occurs 0,
vbeln like vbrp-vbeln,
arktx like vbrp-arktx,
belnr like bkpf-belnr,
end of itab1.
data: begin of itab2 occurs 0,
vbeln like vbrp-vbeln,
arktx like vbrp-arktx,
belnr like bkpf-belnr,
end of itab2.
data: begin of itab3 occurs 0,
kunnr like bseg-kunnr,
name1 like kna1-name1,
vbeln like vbrp-vbeln,
zfbdt like bseg-zfbdt,
belnr like bkpf-belnr,
augcp like bseg-augcp,
augbl like bseg-augbl,
arktx like vbrp-arktx,
end of itab3.
data: begin of itab4 occurs 0,
kunnr like bseg-kunnr,
name1 like kna1-name1,
vbeln like vbrp-vbeln,
zfbdt like bseg-zfbdt,
augcp like bseg-augcp,
augbl like bseg-augbl,
arktx like vbrp-arktx,
pswbt like bseg-pswbt,
end of itab4.
data: vbeln_tst like vbrp-vbeln.
Selections
parameters accgrp like vbrp-ktgrm default '03' obligatory.
parameters compcde like bkpf-bukrs default 'LOI' obligatory.
select-options: billdoc for vbrp-vbeln.
select-options: customer for bseg-kunnr.
select-options: fiscyear for bkpf-gjahr.
select-options: reldate for bseg-augcp.
select-options amount for bseg-pswbt.
INITIALIZATION.
fiscyear-low = sy-datum(4).
fiscyear-high = sy-datum(4).
append fiscyear.
reldate-high = sy-datum.
append reldate.
amount-low = '100'.
amount-high = '2000'.
append amount.
START-OF-SELECTION.
refresh: itab1,itab2,itab3,itab4.
clear : itab1,itab2,itab3,itab4.
clear: vbeln_tst.
select * into corresponding fields of table itab1
from vbrp inner join bkpf
on vbrpmandt = bkpfmandt
and vbrpvbeln = bkpfxblnr
where vbrp~ktgrm = accgrp
and bkpf~bukrs = compcde
and bkpf~gjahr = fiscyear.
loop at itab1.
if itab1-vbeln ne vbeln_tst.
move itab1-belnr to itab2-belnr.
move itab1-vbeln to itab2-vbeln.
move itab1-arktx to itab2-arktx.
append itab2.
endif.
vbeln_tst = itab1-vbeln.
endloop.
loop at itab2.
select * from bseg
where bukrs = compcde
and belnr = itab2-belnr
and gjahr = fiscyear
and buzei = '001'
and augcp in reldate
and augbl ne ''
and vbeln in billdoc
and kunnr in customer.
if sy-subrc = 0.
move itab2-belnr to itab3-belnr.
move bseg-kunnr to itab3-kunnr.
select single name1 from kna1
into itab3-name1
where kunnr = itab3-kunnr.
move itab2-vbeln to itab3-vbeln.
move bseg-zfbdt to itab3-zfbdt.
move bseg-augcp to itab3-augcp.
move bseg-augbl to itab3-augbl.
move itab2-arktx to itab3-arktx.
append itab3.
endif.
endselect.
endloop.
loop at itab3.
select * from bseg
where bukrs = compcde
and belnr = itab3-belnr
and gjahr = fiscyear
and hkont = '0000488600'
and pswbt in amount.
if sy-subrc = 0.
move itab3-kunnr to itab4-kunnr.
move itab3-name1 to itab4-name1.
move itab3-vbeln to itab4-vbeln.
move itab3-zfbdt to itab4-zfbdt.
move itab3-augcp to itab4-augcp.
move itab3-augbl to itab4-augbl.
move itab3-arktx to itab4-arktx.
move bseg-pswbt to itab4-pswbt.
append itab4.
endif.
endselect.
endloop.
END-OF-SELECTION.
sort itab4 by kunnr.
loop at itab4.
at first.
write:/ ' customer ','billing doc.',
'Billing date',' Release date','Release doc.',
' material ','G/L amount'.
endat.
write:/ itab4-name1.
write at 36 itab4-vbeln.
write at 47 itab4-zfbdt.
write at 61 itab4-augcp.
write at 74 itab4-augbl.
write at 88 itab4-arktx.
write at 127 itab4-pswbt.
endloop.
Thanks in advance!
Kindly regards,
NicoHello,
Thanks for your help and fast reaction, I added the 'open dataset' but probably made some minor error:
I'm getting field "result" (name of my text file) is unknown. It is neither in one of the specified tables or defined by a 'DATA' statement
Currently have following code:
Objet du programme : *
Recherche de documents de facturation SD sur base de *
l' "account assignment group" de l'article *
Stocker ces valeurs dans une table interne afin *
de retrouver les pièces comptables correspondantes. *
Afficher le N° du document de facturation, celui de la *
pièce comptable, la date de release du release document. *
REPORT ZAT_CLRDEP01.
Tables declaration
tables : vbrp,bkpf,bseg.
Data declaration
data: begin of itab1 occurs 0,
vbeln like vbrp-vbeln,
arktx like vbrp-arktx,
belnr like bkpf-belnr,
end of itab1.
data: begin of itab2 occurs 0,
vbeln like vbrp-vbeln,
arktx like vbrp-arktx,
belnr like bkpf-belnr,
end of itab2.
data: begin of itab3 occurs 0,
kunnr like bseg-kunnr,
name1 like kna1-name1,
vbeln like vbrp-vbeln,
zfbdt like bseg-zfbdt,
belnr like bkpf-belnr,
augcp like bseg-augcp,
augbl like bseg-augbl,
arktx like vbrp-arktx,
end of itab3.
data: begin of itab4 occurs 0,
kunnr like bseg-kunnr,
name1 like kna1-name1,
vbeln like vbrp-vbeln,
zfbdt like bseg-zfbdt,
augcp like bseg-augcp,
augbl like bseg-augbl,
arktx like vbrp-arktx,
pswbt like bseg-pswbt,
end of itab4.
data: vbeln_tst like vbrp-vbeln.
Selections
parameters accgrp like vbrp-ktgrm default '03' obligatory.
parameters compcde like bkpf-bukrs default 'LOI' obligatory.
select-options: billdoc for vbrp-vbeln.
select-options: customer for bseg-kunnr.
select-options: fiscyear for bkpf-gjahr.
select-options: reldate for bseg-augcp.
select-options amount for bseg-pswbt.
INITIALIZATION.
fiscyear-low = sy-datum(4).
fiscyear-high = sy-datum(4).
append fiscyear.
reldate-high = sy-datum.
append reldate.
amount-low = '100'.
amount-high = '2000'.
append amount.
START-OF-SELECTION.
refresh: itab1,itab2,itab3,itab4.
clear : itab1,itab2,itab3,itab4.
clear: vbeln_tst.
select * into corresponding fields of table itab1
from vbrp inner join bkpf
on vbrp~mandt = bkpf~mandt
and vbrp~vbeln = bkpf~xblnr
where vbrp~ktgrm = accgrp
and bkpf~bukrs = compcde
and bkpf~gjahr = fiscyear.
loop at itab1.
if itab1-vbeln ne vbeln_tst.
move itab1-belnr to itab2-belnr.
move itab1-vbeln to itab2-vbeln.
move itab1-arktx to itab2-arktx.
append itab2.
endif.
vbeln_tst = itab1-vbeln.
endloop.
loop at itab2.
select * from bseg
where bukrs = compcde
and belnr = itab2-belnr
and gjahr = fiscyear
and buzei = '001'
and augcp in reldate
and augbl ne ''
and vbeln in billdoc
and kunnr in customer.
if sy-subrc = 0.
move itab2-belnr to itab3-belnr.
move bseg-kunnr to itab3-kunnr.
select single name1 from kna1
into itab3-name1
where kunnr = itab3-kunnr.
move itab2-vbeln to itab3-vbeln.
move bseg-zfbdt to itab3-zfbdt.
move bseg-augcp to itab3-augcp.
move bseg-augbl to itab3-augbl.
move itab2-arktx to itab3-arktx.
append itab3.
endif.
endselect.
endloop.
loop at itab3.
select * from bseg
where bukrs = compcde
and belnr = itab3-belnr
and gjahr = fiscyear
and hkont = '0000488600'
and pswbt in amount.
if sy-subrc = 0.
move itab3-kunnr to itab4-kunnr.
move itab3-name1 to itab4-name1.
move itab3-vbeln to itab4-vbeln.
move itab3-zfbdt to itab4-zfbdt.
move itab3-augcp to itab4-augcp.
move itab3-augbl to itab4-augbl.
move itab3-arktx to itab4-arktx.
move bseg-pswbt to itab4-pswbt.
append itab4.
endif.
endselect.
endloop.
END-OF-SELECTION.
sort itab4 by kunnr.
EXPORT OUTPUT TO FLAT TEXT FILE : *
open dataset result for output in text mode.
if sy-subrc = 0.
loop at itab4.
at first.
write:/ ' customer ','billing doc.',
'Billing date',' Release date','Release doc.',
' material ','G/L amount'.
endat.
write:/ itab4-name1.
write at 36 itab4-vbeln.
write at 47 itab4-zfbdt.
write at 61 itab4-augcp.
write at 74 itab4-augbl.
write at 88 itab4-arktx.
write at 127 itab4-pswbt.
transfer itab4 to result.
endloop.
close dataset result.
endif.
Thank you!
Regards,
Nico -
How can I Cache the data I'm reading from a collection of text files in a directory using a TreeMap? Currently my program reads the data from several text files in a directory and the saves that information in a text file called output.txt. I would like to cache this data in order to use it later. How can I do this using the TreeMap Class? These are the keys,values: TreeMap The data I'd like to Cache is (date from the file, time of the file, current time).
import java.io.*;
public class CacheData {
public static void main(String[] args) throws IOException {
String target_dir = "C:\\Files";
String output = "C:\\Files\output.txt";
File dir = new File(target_dir);
File[] files = dir.listFiles();
// open the Printwriter before your loop
PrintWriter outputStream = new PrintWriter(output);
for (File textfiles : files) {
if (textfiles.isFile() && textfiles.getName().endsWith(".txt")) {
BufferedReader inputStream = null;
// close the outputstream after the loop
outputStream.close();
try {
inputStream = new BufferedReader(new FileReader(textfiles));
String line;
while ((line = inputStream.readLine()) != null) {
System.out.println(line);
// Write Content
outputStream.println(line);
} finally {
if (inputStream != null) {
inputStream.close();How can I Cache the data I'm reading from a collection of text files in a directory using a TreeMap? Currently my program reads the data from several text files in a directory and the saves that information in a text file called output.txt. I would like to cache this data in order to use it later. How can I do this using the TreeMap Class?
I don't understand your question.
If you don't know how to use TreeMap why do you think a TreeMap is the correct solution for what you want to do?
If you are just asking how to use TreeMap then there are PLENTY of tutorials on the internet and the Java API provides the methods that area available.
TreeMap (Java Platform SE 7 )
Are you sure you want a map and not a tree instead?
https://docs.oracle.com/javase/tutorial/uiswing/components/tree.html -
How to export structure DB to text file
I want to export structure DB to text file for report to my manager.
example: any objects(tables, indexs, constraints) and He need DDL command ("create table" command etc.)
How to do this?Varies by database version.
I would investigate DBMS_METADATA as described in the PL/SQL Packages and Types Reference manual and demoed in the Utilities guide at http://www.oracle.com/pls/db102/portal.portal_db?selected=3 -
How to download PF-STATUS of a Report to a Text File
Hi Friends,
Please guide me on this,
I want to download PF-STATUS of a Report into a text file,
Problem is how to get/capture the PF-STATUS.
Regards,
SowjanyaHi,
Please follow the following link
Upload / download PF Status
Regards,
Shailaja -
Getting error while exporting the report
Hi,
I am facing error while exporting the report. Getting below error.
"No data can be exported because there are no rows.Operation failed."
how come this error is coming even though my report contains data.
please do the needful.
i am using the version discoverer 10g.
Thanks,
RC.I am having the same problem. I found this article in which the user was exporting 100,000 plus records and had the same issue exporting (Discoverer workbook exported to excel error - No dta can be exported and they were able to fix it by adjusting two memory settings in their pref.txt file. However, in my report there are only 1,100 records with eleven columns being returned. I export much larger reports on a daily basis.
Originally, the report was returning records and when I would go to retrieve all records it would tell me that all the rows could not be returned and the data may be incomplete. After scrubbing my SQL I no longer get that message, but the report still will not export and I get the same error as you.
I have not tried the pref.txt settings fix but may try it today to see if that is a workaround. I will then have to evaluate whether it is a good fix or just a band-aid. -
Issue while exporting report in Excel Format
Hello,
I am facing problem while exporting the report in Excel Format. After analysis, I think that it could be due to two reasons, either we are using wrong versions of Jars, or we are using wrong API. Here is the code, approaches and problems we are facing. Please help.
First approach we are using is:
// using basic API
import com.crystaldecisions.reports.sdk.ReportClientDocument;
// get client document from crystal report API and open the report by specifying the report name, with path
ReportClientDocument reportClientDoc = new ReportClientDocument();
reportClientDoc.open( reportPath, 0 );
// give chance to extending classes to configure the report document by POJO or by sql parameter etc, just adding the parameters infromation using ParameterFieldController
configureReportDocument( reportClientDoc, reportMetadata, reportData, reportContext );
// get data source of crystal report
Object reportSource = reportClientDoc.getReportSource();
// export the data - we have also tried with MSExcel format
ReportExportFormat exportFormat = ReportExportFormat.recordToMSExcel;
LOGGER.debug( "exportFormat[" + exportFormat + "]" );
ByteArrayInputStream byteArray = (ByteArrayInputStream) reportClientDoc.getPrintOutputController().export(
exportFormat );
Problem Faced: Specified Excel format is not supported.
Second Approach: We come to know that excel format is supported with new releases and with occa package.
Then we tried with import com.crystaldecisions.sdk.occa.report.application.ReportClientDocument; It ask to set the ReportServer. When we are trying to set the server as
reportClientDoc.setReportAppServer(ReportClientDocument.inprocConnectionString);
Application is unable to find 'ReportClientDocument.inprocConnectionString' property. It seems like we are using some old jars. However we have downloaded the latest released jars for eclipse 2.
Please help for it. Issue is to export the report in excel format, which is currently working fine for PDF. If this problem is related to Jars, please suggest the path to download the latest jars. We also looking for the latest jars like rasapp and rascore etc. But these are not available with Crystal Report for Eclipse 2 release.
Waiting for urgent help. Thanks you..
Regards,
MohitHi,
Send me Environment Details .
Here is the code snippet for exporting report to excel format:
<%@ page import="com.crystaldecisions.sdk.occa.report.application.*" %>
<%@ page import="com.crystaldecisions.sdk.occa.report.definition.*" %>
<%@ page import="com.crystaldecisions.sdk.occa.report.data.*" %>
<%@ page import="com.crystaldecisions.sdk.occa.report.lib.*" %>
<%@ page import="com.crystaldecisions.sdk.framework.*" %>
<%@ page import="com.crystaldecisions.sdk.occa.managedreports.*" %>
<%@ page import="com.crystaldecisions.sdk.occa.infostore.*" %>
<%@ page import="com.crystaldecisions.sdk.occa.report.exportoptions.*" %>
<%@ page import="java.util.*" %>
<%@ page import="java.io.*" %>
<%
String username ="Administrator";
String password ="";
String cmsname ="localhost:6400";
String Authen ="secEnterprise";
//connecting to Enterprise
IEnterpriseSession es = CrystalEnterprise.getSessionMgr().logon(username,password,cmsname,Authen);
//get the report App Factory form the Crystal Enterprise
IReportAppFactory appFactory = (IReportAppFactory) es.getService("","RASReportService");
//get the infostore service form the Crystal Enterprise
IInfoStore istore = (IInfoStore) es.getService("","InfoStore");
//get the report by name from crystal Enterprise
IInfoObjects iobjects = istore.query("Select * From CI_INFOOBJECTS Where SI_NAME = 'sampleramz2.rpt' and SI_INSTANCE = 0 ");
//open the report in the report doc object.
ReportClientDocument Doc = appFactory.openDocument((IInfoObject)iobjects.get(0), 0, Locale.ENGLISH);
// WORKING WITH THE PRINT OUTPUT CONTROLLER
//Use the report documents PrintOutputController to export the report to a ByteArrayInputStream
ByteArrayInputStream byteIS = (ByteArrayInputStream)Doc.getPrintOutputController().export(ReportExportFormat.recordToMSExcel);
// EXPORTING THE REPORT
//Create a byte[] (same size as the exported ByteArrayInputStream)
byte[] buf = new byte[2000 * 1024];
int nRead = 0;
//Set response headers to indicate pdf MIME type and inline file
response.reset();
response.setHeader("Content-disposition", "inline;filename=ramz");
response.setContentType("application/xls");
//Send the Byte Array to the Client
while ((nRead = byteIS.read(buf)) != -1)
response.getOutputStream().write(buf, 0, nRead);
//Flush the output stream
response.getOutputStream().flush();
//Close the output stream
response.getOutputStream().close();
%>
Let me know any information is needed,
Regards,
Rameez -
Problem while exporting to PDF with japanese character in Crystal Report X1
Hi,
I am using Crystal report X1 with classic ASP on a Windows 2003 Enterprise Server, SP 2. In my application, I have to export the report into PDF, CSV, DOC formats. I am have Japanese strings in the report. While exporting to PDF, empty boxes has displayed in the place of Japanese string and in CSV file, question mark has been displayed instead of Japanese string. But the Doc file is exported correctly. I have not installed any language support software either in server or in client machine. I have used MS Gothic and Arial Unicode MS fonts for the text-objects which has Japanese strings.
Please give me a solution so that I will get PDF file with Japanese strings instead of empty box or question mark.
Do I need to install any language support pack software?
Thanks in advance.
Regards,
ManjuHi Don,
Thank You for your reply. I have resolved the issue of exporting to pdf from crystal report X1 having Japanese data after installing the language pack.
But when I am exporting to CSV or TXT, i am getting ??? instead of Japanese characters. I have tried "export" through crystal report designer and got ??? instead of Japanese.
The Crystal report version I am using is Crystal report X1 11.0.0.1282
Crystal Report Desinger is installed in Windows Xp machine
Font set for Text object is Arial Unicode MS, MS PMincho, MS PGothic
Does the Crystal report X1 11.0.0.1282 has the UTF-8 support for CVS / txt
Please provide me a solution
Thanks in advance,
Regards,
Manju -
"Memory full." error while exporting report to PDF format - CR2008SP2
<br>
Hello,<br>
<br>
I am developing a C#.NET application that uses the CR2008 SP2 .NET libraries. This application performs some database updates and uses CR2008 SP2 to run 7 different reports and export the results to PDF files. This application is a console application that only uses Crystal to export the rendered reports - it does not use previews or printing.<br>
<br>
The specific pattern of this application is as follows:<br>
<br>
- perform some database updates<br>
- render report #1 and export it as a PDF file<br>
- perform some database updates<br>
- render report #2 and export it as a PDF file<br>
... pattern repeats to report #7 ...<br>
<br>
This application works fine as long as I run only one instance of it at a time. The problem occurs when I try to run multiple instances of this application at the same time. When I run multiple instances of this application at the same time (against totally different databases) each instance will start up happily and begin running through the process described above. After a few moments one or more instances will fail during the report export. The specific error is as follows:<br>
<br>
"Memory full. Failed to export the report. Not enough memory for operation."<br>
<br>
The error always comes from the call to:<br>
<br>
CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToDisk(Format, FileName)<br>
<br>
I have watched the memory consumption of these instances of my application while they are running. They never seem to exceed approximately 52MB each. At this time task manager reports over 1GB of physical memory free. These numbers lead me to believe that memory is not actually "full".<br>
<br>
Here are some specifics about the environment:<br>
<br>
Dell Vostro 1720 / P8600 / 4GB<br>
Windows 7 Ultimate x64<br>
SQL Server 2008 SP1 x64<br>
Crystal Reports 2008 SP2<br>
<br>
Specifics about the C# application:<br>
<br>
IDE: Visual Studio 2008 SP1<br>
Type: Console Application<br>
Target platform: x86<br>
.NET Framework: 3.5 SP1<br>
Crystal References:<br>
- CrystalDecisions.CrystalReports.Engine (v12.0.2000.0)<br>
- CrystalDecisions.Shared (v12.0.2000.0)<br>
<br>
Specifics about the report templates:<br>
<br>
The report templates are RPT files saved from CR2008 SP2. They are relatively simple. A few of them (maybe 3) contain a single subreport.<br>
<br>
Specifics about the database:<br>
<br>
Each database is approximately 1GB in size. The database contains many tables but the reports only access a handful of tables. Each table that the reports access have maybe a few hundred rows tops. Most have less than 100. Likewise, when the reports perform their selections the resulting rowset for the reports is anywhere from about 20 records to a few hundred records tops.<br>
<br>
A few items to note:<br>
<br>
- Multiple instances of my application need to be able to run on a single machine at the same time. It is a specific design requirement.<br>
- My application works fine as long as I run only one instance of it at a time.<br>
- My application works fine when I run multiple instances if I comment out the Crystal part of it.<br>
- My application works fine when I run multiple instances if I change the export format from PDF to HTML32 or HTML40 (have not tried any others)<br>
- The machine has over 1GB of physical memory free when this error occurs.<br>
- I have taken steps to ensure that I am properly disposing of my CrystalDecisions.CrystalReports.Engine.ReportDocument instance just after each export is complete. I have tried to use the "using" keyword, as well as explicitly setting the instance to null and calling the .NET framework garbage collector. This did not seem to help.<br>
<br>
Any assistance with this issue would be greatly appreciated.<br>
<br>
Steve<br>
<br>
Edited by: scbraddy on Mar 11, 2010 1:53 AM<br>
Jonathan & Ludek,<br>
<br>
Thanks for the timely response and good suggestions guys!<br>
<br>
I have performed a few more tests today in order to help answer some of your questions.<br>
<br>
Below are my responses. Some of them are answers to questions and some of them are observations based on tests I have performed today.<br>
<br>
- The database system is SQL Server 2008 SP1 Developer Edition x64.<br>
<br>
- The C# application connects to the database using the native .NET SQL client (System.Data.Sql).<br>
<br>
- During runtime I connect the report to the database by looping through the ReportDocument.Database.Tables collection. For each Table found I create a CrystalDecisions.Shared.TableLogOnInfo instance, fill in the table name, server name, database name, user ID, and password, and use Table.ApplyLogOnInfo() to apply it. I do the same thing for the subreports collection if there are any. Like I said, about half of the reports contain a single subreport.<br>
<br>
- The report templates are currently set to use the "SQLOLEDB" Provider. The Database Type is set to "OLE DB (ADO)". I am not entirely sure what you mean by trying a different database driver. I assume you mean to change the provider? If so, given the fact that we are using SQL Server 2008, what would I change it to?<br>
<br>
- If I do not perform the database updates during application runtime (instead, perform them ahead of time and then allow the application to only render the reports) then I still have the same problem. Nothing changes.<br>
<br>
- I installed the Fix Pack 2.5, rebooted, and tried again. Same problem.<br>
<br>
- I do not beleive that I am using XML transforms. How would I know?<br>
<br>
- Regarding fragmented memory: It is hard for me to believe that, given the amount of memory free on the machine once all processes are up and running (1GB+), and the size of the processes (~50MB), that a contiguous block could not be found. Maybe there is some Crystal process that is attempting to balloon out of control, but as far as I can tell my application is not getting very big. I will not rule this out of course because I don't know for sure.<br>
<br>
- Regarding killing the process once a report is rendered: The problem with this is that the application needs to perform these 7 groups of updates and render these 7 reports in a specific sequence all as part of one complete "pass". Also, this application needs to be able to be able to handle a scneario where one or more instance of the application is started on a single machine at roughly the same time (pointed at different databases). The application actually does work fine in this regard (staying well within the capabilities of my 4GB laptop even when 8 of them are running) except that I always get the same error when I choose PDF as my export format.<br>
<br>
- I ran a test today where I changed the export format to HTML40 and started 8 instances of the application at the same time, each working from a different copy of the database. The instances ran a little slow but did complete in good time with no errors. Please note that changing the export format to PDF will cause the application to fail with the "memory full" error if even only 2 instances are running at the same time. The only way I can successfully complete a run with the export format set to PDF is to run only 1 instance at a time. I can run it over and over all day long and it will not fail, as long as only 1 instance is running at a given time. As of yesterday I had only proven that the application would complete when using the HTML40 export format when 2 or 4 instances are running, but today I doubled it again (to 8) and still no failure while using HTML40. This is possibly the most interesting fact about this problem, and is another reason why I am skeptical that memory fragmentation is the culprit.<br>
<br>
We would like to solve this problem because we would like to continue to target the PDF format. It is the standard report export format for our applications. If we cannot solve this problem we may call a meeting and decide whether to proceed with the HTML40 export format, or possibly dump Crystal from this project altogether.<br>
<br>
Thanks again for your interest in our problem and your timely and helpful responses. I'm really not sure where to go next ... maybe change the database provider in the templates? I will need some specific advice in this area because I'm not sure what to do. Any more ideas you guys have will be greatly appreciated on this end!<br>
<br>
Steve<br>
<br>
Edited by: scbraddy on Mar 12, 2010 2:18 AM
Maybe you are looking for
-
I screwed up trying to make my superdrive regionfree, so now I need a new one (since there is no firmware update, or any firmware downloads for the shaite!). At this point I'm inches from ******* on the f*#cker!! Back to the point; does anyone have a
-
No DVD/CD drive. How to install?
I have photoshop elements 13, and I am trying to download it on my macbook air- I have the discs but no disc drive on my computer. How can I still install it?
-
Hi, I have customized table for data maintenace and be accessed via SM30. Client's requirement is to have 2 steps similar to OX09, enter plant first then go in to storage location data maintenance for the selected plant. Is it dialog program? can we
-
Hi, Can anyone shed some light on the issue of EXP field propagation as labels are removed or added? Specifically.... 1. I understand that at ingress of MPLS cloud you would use class-based policy to apply the initial EXP value based on some class-ma
-
UCCX 8.5.1.11002-22 high CPU utilization - 99%
Hi Guys I have client running UCCX 8.5.1.11002-22 in VMWare environment. Client claim that he received email alerts from RTMT pointing out UCCX going over memory usage threshold of 70% constantly in every minutes since yesterday. Alerts show as below