Next line character error
Hello All,
I am trying to concatenate two strings along with next line character. I am using the following syntax.
v_str1||chr(13)||chr(10)||v_str2;
The problem I am facing is if the string is like greater than about 40 characters, then the new line character is not getting appended . Instead they are concatenated together without the new line character.
I also tried using only chr(10). But it is not working. Can anybody plz suggest me a soln to this.
Thanks,
Myway
Edited by: myway on Mar 29, 2009 3:16 PM
Hi,
Please post your code that raises the problem, I use this simple example and works fine:
Connected to Oracle Database 10g Express Edition Release 10.2.0.1.0
Connected as hr
SQL> select 'line 1' || chr(13) || 'line 2' from dual;
'LINE1'||CHR(13)||'LINE2'
line 1
line 2
SQL>
SQL> SET SERVEROUTPUT ON
SQL> DECLARE
2 v_string VARCHAR2(4000);
3 v_line1 VARCHAR2(4000) := 'LINE 1';
4 v_line2 VARCHAR2(4000) := 'LINE 2';
5 c_line_break CONSTANT VARCHAR2(1) := CHR(13);
6 BEGIN
7 v_string := v_line1 || c_line_break || v_line2;
8 dbms_output.put_line(v_string);
9 END;
10 /
LINE 1
LINE 2
PL/SQL procedure successfully completed
SQL> Regards,
Similar Messages
-
Long text to be taken into next line
Hi,
I am passing a text in a FM in a BADI, but the text being long enters in the next line which gives an error saying that 'Literals that take up more than one line are not allowed in OO context'.
Can someone suggets some way of overcoming this other than storing the text in variables & concatenating it.
Thanks.Hi
I guess there is no other way apart from concatenating
the text into a variable. If you dont want to declare a
new variable for that you can use the same variable.
move 'First Line' to l_text.
concatenate l_text 'continuing' into l_text separated
by space.
Kind Regards
Eswar -
Want to know how to check for new line character in text file
Hi All,
I`m trying to read data from text file. However I`m not sure whether the data is in 1st line or nth line. Now I`m trying to read the text from the readline. But if text is "" and not NULL then my code fails. So I want to know how to check for new line character and go to next line to find the data. Please help.
Thanks
static int readandwriteFile(Logger logger,String filepath){
BufferedWriter out = null;
BufferedReader in = null;
File fr = null;
int get_count = 0;
try {
if(new File(filepath).exists())
fr= new File(filepath);
System.out.println("FileName: "+fr);
if(fr != null){
in = new BufferedReader(new FileReader(fr));
String text = in.readLine();
if(text != null){
get_count = Integer.parseInt(text);
in.close();
else{
get_count = 0;
else{
out = new BufferedWriter(new FileWriter(filepath));
out.write("0");
out.close();
} //Reading of the row count file ended.
catch(Exception e) {
e.printStackTrace();
finally {
try{ if (in != null) {
in.close();
if (out != null) {
out.close();
catch(Exception e) {
e.printStackTrace();
return get_count;
}You are calling the readline() only once which means you are reading only the first line from the file...
Use a loop (Do-While preferably)
do{
//your code
}while(text == "") -
LV crashes when I try to save a VI - "fpsane.cpp line 269 error"
Dear LV users:
“Fpsane.cpp, line 269 error”
I have this error when I modify the VI and try to save it. Often I run it once and save it without problem. When I modify it again and try to save it, the error appears and LV crashes.
First I made a 6.0.2 upgrade and later I followed the “solving troubles” procedure at NI home page, like empty the TEMP directory and so on.
Later I sent my VI to NI support and I received the confirmation that they were able to reproduce the error, but not able to isolate it. Also they wrote that “Maybe can be a problem with the charts” and “it could be a bug in LV 6.0.2 which is fixed in LV 6.1”.
They saved my VI as a 6
.1 version and there were no problems (any error).
The problem is:
“ LV 6.1 is the next release (newest version) of LV and it will be released this year (the date is not fixed). That's not an update like LV 6.0.2 but a new version of LV. It must be purchased”
So I have a trouble here. I have some VIs that contains some parts in common. Now they are crashing too. I’m not confident anymore to make tests and modifications, since LV will crash again. What I’m doing after run my VI is exiting LV and open the VI again. Only after I can realize (and save) the modifications. This way is really a pain in a neck....
Please, can someone tell me a good way to isolate this problem or to solve it? I really don’t want to wait LV 6.1 nether to buy it to solve this “bug”....
Thank you in advance
Rodolfo
OS: Nt4 sp 6
LV 6.0.2Dear LV users
Sorry for not have included the VI.
"test time save format.vi" is a learning program that contains some ideas to be used in another one. The error (fpsane.cpp) that appears here also was detected in LV 6. On the first time after grouping/edit some controls.
This error occurs when you modify the VI and try to save it. Often you run it once and save it without problem. When you modify it again and try to save it, the error appears. This is the same problem that happened with 2 other VI, even with one LV original example (after grouping).
The same error happened in another computer (also running NT4). All libraries were rebuilt during the installation of LV 6.02 and the TEMP directory is empty.
I hope that this vi will help us.
Thanks ag
ain
Rodolfo
Attachments:
Test_time_save_format.zip 92 KB -
SQL Loader Multibyte character error
Hello,
Oracle Database 11g Release 11.2.0.2.0 - 64bit Production
Database Characterset: WE8MSWIN1252
To load an utf8 File (UTF-8 Unicode text) i use option characterset UTF8 in controlfile.
All went fine until in textfile the column is filled up with 40 chars and
german umlaute included (ÜÖÄüöä...)
Loader stops (errors=0) and gives:
Record 146466: Rejected - Error on table 'TableName', column 'ColumnName'.
Multibyte character error
* use CHAR(40) and POSITION(start-end) for field description - no help
* modify column, from VC2(40 char) to VC2(50 char) - no help
* without characterset UTF8 option i got wrong characters for german umlaute - no help
* manual insert the data from this row with NO problems !
any hint or workaround?
Regards
MichaelHi Werner,
on my linux desktop:
$ file test.dat
test.dat: UTF-8 Unicode text, with very long lines
my colleague is working on a windows system.
On both systems exact the same error from SQL Loader.
Btw, try with different number of special characters (german umlaute and euro) and there is no chance to load without the error
when to many (?) special characters or data is long as column length and special characters included.
Regards
Michael -
SQL Loader Multibyte character error, LENGTH SEMANTICS CHARACTER
Hi,
startet SQL Loader Multibyte character error
{thread:id=2340726}
some mod locked the thread, why?
the solution for others:
add LENGTH SEMANTICS CHARACTER to the controlfile
LOAD DATA characterset UTF8 LENGTH SEMANTICS CHARACTER
TRUNCATE
INTO TABLE utf8file_to_we8mswin1252
ID CHAR(1)
, TEXT CHAR(40)
)Regards
MichaelHi Werner,
on my linux desktop:
$ file test.dat
test.dat: UTF-8 Unicode text, with very long lines
my colleague is working on a windows system.
On both systems exact the same error from SQL Loader.
Btw, try with different number of special characters (german umlaute and euro) and there is no chance to load without the error
when to many (?) special characters or data is long as column length and special characters included.
Regards
Michael -
Multibyte character error... (SQL*Loader)
Hi,
I am getting error while loading data via SQL*Loader:
"Multibyte character error." while loading data from flat files comgin from mailframe into oracle 10g Rel2 with character set AL32UTF8
here is my .ctl loader file
OPTIONS (ERRORS=9999, ROWS=500, BINDSIZE=65536, SILENT=(FEEDBACK) )
LOAD DATA
APPEND
INTO TABLE GLSTB270
GLS27001_CONUMBER POSITION(0001:0011)
, GLS27002_STORE POSITION(0012:0012)
, GLS27003_STATUS POSITION(0013:0013)
, GLS27004_CUST_TYPE POSITION(0014:0014)
, GLS27005_EXTERN POSITION(0015:0025)
, GLS27006_ADD_DATE POSITION(0026:0039) DATE "yyyymmddhh24miss"
, GLS27007_EXTCUST POSITION(0040:0071)
, GLS27008_LPICKCHRO POSITION(0072:0073)
, GLS27009_LAST_ITEM POSITION(0074:0075)
, GLS27010_DLVADD1 POSITION(0076:0107)
, GLS27011_DLVADD2 POSITION(0108:0139)
, GLS27012_DLVADD3 POSITION(0140:0171)
, GLS27013_DLVPOSTAL POSITION(0172:0181)
, GLS27014_DLVCOUNTY POSITION(0182:0213)
, GLS27015_DLVCNTRY POSITION(0214:0215)
, GLS27016_SPECADD POSITION(0216:0216)
, GLS27017_GROUPING POSITION(0217:0217)
, GLS27018_CO_TYPE POSITION(0218:0218)
, GLS27019_QUOTATION POSITION(0219:0226) DATE "yyyymmdd"
NULLIF (GLS27019_QUOTATION = "00000000")
, GLS27020_USHIP POSITION(0227:0227)
, GLS27021_CONFIRM POSITION(0228:0228)
, GLS27022_UNUDEMAND POSITION(0229:0229)
, GLS27023_FREECHARG POSITION(0230:0230)
, GLS27024_CONF_DATE POSITION(0231:0238) DATE "yyyymmdd"
NULLIF (GLS27024_CONF_DATE = "00000000")
, GLS27025_CONTACT POSITION(0239:0270)
, GLS27026_LICENCE POSITION(0271:0290)
, GLS27027_WARRANT POSITION(0291:0291)
, GLS27028_WARR_AUTH POSITION(0292:0301)
, GLS27029_CURRENCY POSITION(0302:0304)
, GLS27030_FSE POSITION(0305:0310)
, GLS27031_CARRIER POSITION(0311:0320)
, GLS27032_MANPRICIN POSITION(0321:0321)
, GLS27033_ADD_USER POSITION(0322:0329)
, GLS27034_AUTO_INV POSITION(0330:0330)
, GLS27035_PRIFACT POSITION(0331:0338)
, GLS27036_CRELETTER POSITION(0339:0353)
, GLS27025_CONTACT POSITION(0239:0270)
, GLS27026_LICENCE POSITION(0271:0290)
, GLS27027_WARRANT POSITION(0291:0291)
, GLS27028_WARR_AUTH POSITION(0292:0301)
, GLS27029_CURRENCY POSITION(0302:0304)
, GLS27030_FSE POSITION(0305:0310)
, GLS27031_CARRIER POSITION(0311:0320)
, GLS27032_MANPRICIN POSITION(0321:0321)
, GLS27033_ADD_USER POSITION(0322:0329)
, GLS27034_AUTO_INV POSITION(0330:0330)
, GLS27035_PRIFACT POSITION(0331:0338)
, GLS27036_CRELETTER POSITION(0339:0353)
, GLS27037_SHIPMENT POSITION(0354:0354)
, GLS27038_DIVISION POSITION(0355:0356)
, GLS27039_ACCREF POSITION(0357:0365)
, GLS27040_EXPENSE POSITION(0366:0366)
, GLS27041_ALREADY POSITION(0367:0367)
, GLS27042_SITE POSITION(0368:0375)
, GLS27043_SITE_DES POSITION(0376:0395)
, GLS27044_ADDTYPE POSITION(0396:0396)
, GLS27045_PROJECT POSITION(0397:0406)
, GLS27046_SITE_DOWN POSITION(0407:0407)
, GLS27047_QUOTATION POSITION(0408:0408)
, GLS27048_DELIVERY POSITION(0409:0428)
, GLS27049_CONSPERM POSITION(0429:0429)
, GLS27050_CHARACT POSITION(0430:0432)
, GLS27051_CONTRACT POSITION(0433:0434)
, GLS27052_FSE POSITION(0435:0435)
, GLS27053_SYSTEM POSITION(0436:0445)
, GLS27054_SYSTEM_D POSITION(0446:0465)
, GLS27055_JOBSTATUS POSITION(0466:0468)
, GLS27056_BO_L_CHRO POSITION(0469:0470)
, GLS27057_BUYER POSITION(0471:0480)
, GLS27058_SCREASON POSITION(0481:0481)
, GLS27059_L_M_DATE POSITION(0482:0495) DATE "yyyymmddhh24miss"
, GLS27061_L_M_USER POSITION(0496:0503)
, GLS27062_SCREEN POSITION(0504:0507)
, GLS27063_CUST_EXP POSITION(0508:0508)
, GLS270F1_GLS08001 POSITION(0509:0509)
, GLS270F2_GLS08002 POSITION(0510:0511)
, GLS270F3_GLS25001 POSITION(0512:0512)
, GLS270F4_GLS25002 POSITION(0513:0522)
)and here is the .log file containing error msg for sql*loader:
SQL*Loader: Release 9.2.0.8.0 - Production on Thu Apr 5 15:35:21 2007
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
Control File: /opt/oracle/test/admin/glsdbt01/load/glstb270.ctl
Data File: /opt/oracle/test/admin/glsdbt01/download2/GLSTB270.ZZ.CRE
Bad File: /dblog02/glsdbt01/load/results/glsltb270zz.bad
Discard File: /dblog02/glsdbt01/load/results/glsltb270zz.dis
(Allow all discards)
Number to load: ALL
Number to skip: 0
Errors allowed: 9999
Continuation: none specified
Path used: Direct
Silent options: FEEDBACK
Table GLSTB270, loaded from every logical record.
Insert option in effect for this table: APPEND
Column Name Position Len Term Encl Datatype
GLS27001_CONUMBER 1:11 11 CHARACTER
GLS27002_STORE 12:12 1 CHARACTER
GLS27003_STATUS 13:13 1 CHARACTER
GLS27004_CUST_TYPE 14:14 1 CHARACTER
GLS27005_EXTERN 15:25 11 CHARACTER
GLS27006_ADD_DATE 26:39 14 DATE yyyymmddhh24miss
GLS27007_EXTCUST 40:71 32 CHARACTER
GLS27008_LPICKCHRO 72:73 2 CHARACTER
GLS27009_LAST_ITEM 74:75 2 CHARACTER
GLS27010_DLVADD1 76:107 32 CHARACTER
GLS27011_DLVADD2 108:139 32 CHARACTER
GLS27012_DLVADD3 140:171 32 CHARACTER
GLS27013_DLVPOSTAL 172:181 10 CHARACTER
GLS27014_DLVCOUNTY 182:213 32 CHARACTER
GLS27015_DLVCNTRY 214:215 2 CHARACTER
GLS27016_SPECADD 216:216 1 CHARACTER
GLS27017_GROUPING 217:217 1 CHARACTER
GLS27018_CO_TYPE 218:218 1 CHARACTER
GLS27019_QUOTATION 219:226 8 DATE yyyymmdd
NULL if GLS27019_QUOTATION = 0X3030303030303030(character '00000000')
GLS27020_USHIP 227:227 1 CHARACTER
GLS27020_USHIP 227:227 1 CHARACTER
GLS27021_CONFIRM 228:228 1 CHARACTER
GLS27022_UNUDEMAND 229:229 1 CHARACTER
GLS27023_FREECHARG 230:230 1 CHARACTER
GLS27024_CONF_DATE 231:238 8 DATE yyyymmdd
NULL if GLS27024_CONF_DATE = 0X3030303030303030(character '00000000')
GLS27025_CONTACT 239:270 32 CHARACTER
GLS27026_LICENCE 271:290 20 CHARACTER
GLS27027_WARRANT 291:291 1 CHARACTER
GLS27028_WARR_AUTH 292:301 10 CHARACTER
GLS27029_CURRENCY 302:304 3 CHARACTER
GLS27030_FSE 305:310 6 CHARACTER
GLS27031_CARRIER 311:320 10 CHARACTER
GLS27032_MANPRICIN 321:321 1 CHARACTER
GLS27033_ADD_USER 322:329 8 CHARACTER
GLS27034_AUTO_INV 330:330 1 CHARACTER
GLS27035_PRIFACT 331:338 8 CHARACTER
GLS27036_CRELETTER 339:353 15 CHARACTER
GLS27037_SHIPMENT 354:354 1 CHARACTER
GLS27038_DIVISION 355:356 2 CHARACTER
GLS27039_ACCREF 357:365 9 CHARACTER
GLS27040_EXPENSE 366:366 1 CHARACTER
GLS27041_ALREADY 367:367 1 CHARACTER
GLS27042_SITE 368:375 8 CHARACTER
GLS27043_SITE_DES 376:395 20 CHARACTER
GLS27044_ADDTYPE 396:396 1 CHARACTER
GLS27045_PROJECT 397:406 10 CHARACTER
GLS27046_SITE_DOWN 407:407 1 CHARACTER
GLS27047_QUOTATION 408:408 1 CHARACTER
GLS27048_DELIVERY 409:428 20 CHARACTER
GLS27049_CONSPERM 429:429 1 CHARACTER
GLS27050_CHARACT 430:432 3 CHARACTER
GLS27051_CONTRACT 433:434 2 CHARACTER
GLS27052_FSE 435:435 1 CHARACTER
GLS27053_SYSTEM 436:445 10 CHARACTER
GLS27054_SYSTEM_D 446:465 20 CHARACTER
GLS27055_JOBSTATUS 466:468 3 CHARACTER
GLS27056_BO_L_CHRO 469:470 2 CHARACTER
GLS27057_BUYER 471:480 10 CHARACTER
GLS27058_SCREASON 481:481 1 CHARACTER
GLS27059_L_M_DATE 482:495 14 DATE yyyymmddhh24miss
GLS27061_L_M_USER 496:503 8 CHARACTER
GLS27062_SCREEN 504:507 4 CHARACTER
GLS27063_CUST_EXP 508:508 1 CHARACTER
GLS27063_CUST_EXP 508:508 1 CHARACTER
GLS270F1_GLS08001 509:509 1 CHARACTER
GLS270F2_GLS08002 510:511 2 CHARACTER
GLS270F3_GLS25001 512:512 1 CHARACTER
GLS270F4_GLS25002 513:522 10 CHARACTER
Record 20405: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20418: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20419: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20420: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20425: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20426: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20436: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20452: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20481: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20482: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20483: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20484: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20485: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20486: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20487: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20494: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20499: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20502: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.
Record 20503: Rejected - Error on table GLSTB270, column GLS27043_SITE_DES.
Multibyte character error.Can you pls help..?
thanksHi Werner,
on my linux desktop:
$ file test.dat
test.dat: UTF-8 Unicode text, with very long lines
my colleague is working on a windows system.
On both systems exact the same error from SQL Loader.
Btw, try with different number of special characters (german umlaute and euro) and there is no chance to load without the error
when to many (?) special characters or data is long as column length and special characters included.
Regards
Michael -
New-line character in stacked message pop-up
I have run into a brick wall with this situation--
Our clients are running Client/Server Forms 6i, and Web Forms 6i using Patch 10. They are about to upgrade web forms to the latest version 9.0.4.1.0 (10g).
We have a few PLL routines that use the stacked message method: Message('text here'); Message(' ',no_acknowledge);to display important error messages to the user. It is especially useful to display the multiple ORA- errors when an unexpected server error occurs.
Throughout all versions of Client/Server forms, and even in our old version of Web forms, I can use chr(10) or another character to start each error message on a new line.
Somewhere after Patch 10, Oracle has removed that capability. Instead, pop-up stacked messages word-wrap into a multi-line message, and display the new-line character as a box indicating an unprintable character. Our nicely formatted messages are a mess!
I have been told I should use an alert, which supports chr(10) as the new line. However, this is a PLL routine, and I would have to create an alert in hundreds of forms just to accommodate this short-sightedness. The changes and subsequent testing and release issues make this an unworkable solution.
I am clueless as to why this feature would be removed. Oracle support is treating it as an enhancement request. Any ideas?Steve,
If you really have hundreeds of forms ... create one more - to display your messages. Make it modal and nice looking. Call it through the library. Design it to work both as [OK] message and as an users responce [Yes]/[No]/[Cancel].
And honestly - I don't think message(); message() is the best way to display messages. Whoever designed the application should've think about alerts with standartized naming convention, so they can be handled easily through the PLL.
Venko -
Pasting in JTextPane adds the text in the next line not the cursor positon
Hi,
I have a problem with pasting the text in a JTextPane. The content type is text/html and the document is HTMLDocument. When I paste the text, it goes to the next line instead of inserting at the current cursor position. The problem is when pasting, the html writer adds a paragraph tag with the selected text. Can any one please help me with this issue for pasting a selected text in the position where I want, without loosing the character attributes and other html tags, but only the paragaraph tags?
Thanks
sijuHi Tariq,
If you are specifying some .prt files(printer definition files) in the desformat, please examine them if you have set the width and height to proper values.
Otherwise look at $ORACLE_HOME/reports/printers/dflt.prt (default file) and see if the width and height are set to proper values.
Thanks,
Siva B -
New line character in File adapter
I am having a receiver file adapter which generates files with multiple lines.
My problem is when the target file is opened in notepad there is no line break and the lines comes as continous string with small rectangle as separator.This fails the target upload program.
When I remove those small squares in notepad and hit enter and then upload it gets uploaded successfully.
Is there any way to have line break so that new line will be generated each time (the documenation says the by-default it adds new line character then why in notepad it opens like a continous string?)
Thanks in advance.
Regards
RajeevHello
I know by default File Adapter value is line break. But if I open that generated file in notepad, the record does'nt appear on the new line. Instead at the end of each line there is special character added at the end of each record. When I hit enter and deletes that special character and then try to load that file it gets loaded successfully.
So my problem is how to generate the file will give record on the new line. I tried to give 'nl' as endSeparator.
How to give hexadecimal values? I tried giving '0xHH' but that gives error in File Adapter
"Error: Conversion initialization failed: Exception: java.lang.NumberFormatException: For input string: "HH"
Thanks in advance.
Regards
Rajeev -
New Line Character in OSB for sending email in proper format
Hi
We have a client requirement, where in we send an error email when ever an exception occurs in the OSB flow. We are using OSB 11g and we need to format the body within or before the publish activity using a replace activity something in the below manner (replace . in variable body (replace node contents))
fn:concat("Following Exception Occurred <NEW LINE>","ErrorCode: ",fn:data($fault/ctx.errorCode) etc etc)
Please tell us if there is a new line character available within OSB to format the email message. Please help its urgent. ThanksThanks a lot for the reply, but still in the email body, i see everything in one line (no enter0). I tried " ","",\n and CHR(13). All dont seem to work.
Also can you provide an example for 
: (Ampersandhash13colon)
Please help.
Regards
Amit Sachdev
Edited by: user638094 on Mar 8, 2011 12:01 AM -
Text tool: Text doesn't goto the next line
Hi,
I ran into a problem where my text doesn't go to the next line when I press ENTER. If I keep on typing, the text would overwrite itself.
This is only happening in After Effects (it is fine in other apps...Email, Photoshop, etc.). I know it is probably something I clicked but for the longest time, I couldn't figure it out.
Any help appreciated.As Mylenium suggested, you may have a problem with line spacing. For example, you may have leading set to 0. One way to clear problematic settings is to reset the settings in the Character panel.
-
Why text wraps to next line in Chacacter Mode Report?
I have developed a Character Mode report. I have followed all guidelines mentioned in on-line help topic 'Setting properties of an ASCII (character mode) report'.
The problem is that when I print the report, the printer prints around 80 characters and then wraps the remaining text on to the next line. Yes I have set Report Width and Height properties of the report to 132 and 66 resp.
Shows OK in preview.
Both Horizontal and vertical Elasticity are FLEXIBLE.
Result is same on different printers.
What can be the problem.
Pl. guide.
TariqHi Tariq,
If you are specifying some .prt files(printer definition files) in the desformat, please examine them if you have set the width and height to proper values.
Otherwise look at $ORACLE_HOME/reports/printers/dflt.prt (default file) and see if the width and height are set to proper values.
Thanks,
Siva B -
Write to text file (including spaces/next line) using oracle??
How to write to text file using oracle? And how do I handle spaces/next line? (i was trying to use spaces(ch(32)), however it is just converted into squares in the text file.) thanks!
989873 wrote:
How about tabs?It does not matter what character it is. UTL_FILE deals correctly with any text file. Tabb is CHR(9):
SQL> declare
2 v_file utl_file.file_type;
3 v_total_rec number := 0;
4 v_total_sal number := 0;
5 begin
6 v_file := UTL_FILE.FOPEN('TEMP','TEST.TXT','w');
7 for v_rec in (select * from emp) loop
8 v_total_rec := v_total_rec + 1;
9 v_total_sal := v_total_sal + v_rec.sal;
10 UTL_FILE.PUT_LINE(
11 v_file,
12 lpad(v_rec.deptno,2) || chr(9) || rpad(v_rec.ename,14) || chr(9) || to_char(v_rec.sal,'99999D99')
13 );
14 end loop;
15 UTL_FILE.PUT_LINE(v_file,'Total Salary:' || chr(9) || v_total_sal);
16 UTL_FILE.PUT_LINE(v_file,'Total Records:' || chr(9) || v_total_rec);
17 UTL_FILE.FCLOSE(v_file);
18 end;
19 /
PL/SQL procedure successfully completed.
SQL> declare
2 v_file utl_file.file_type;
3 v_line varchar2(100);
4 begin
5 v_file := UTL_FILE.FOPEN('TEMP','TEST.TXT','r');
6 loop
7 UTL_FILE.GET_LINE(v_file,v_line);
8 DBMS_OUTPUT.PUT_LINE(v_line);
9 end loop;
10 exception
11 when no_data_found
12 then
13 UTL_FILE.FCLOSE(v_file);
14 end;
15 /
20 SMITH 800.00
30 ALLEN 1600.00
30 WARD 1250.00
20 JONES 2975.00
30 MARTIN 1250.00
30 BLAKE 2850.00
10 CLARK 2450.00
20 SCOTT 3000.00
10 KING 5000.00
30 TURNER 1500.00
20 ADAMS 1100.00
30 JAMES 950.00
20 FORD 3000.00
10 MILLER 1300.00
Total Salary: 29025
Total Records: 14
PL/SQL procedure successfully completed.
SQL>SY. -
Removing New Line Character in Input file
Hi Experts,
I Have a question about "New Line Character". I searched in SDN before posting this thread, But I didn't get answer.
Question:
Let me say my Client requirement first. After loading the data(Millions of Records) into SAP through LSMW, they asked write a program for validation of those loaded records based on I/P file. I wrote a program and It is success full.
But, the problem is when file is in Application server in 'BIN' format, a new line character(#) is created. While comparing the last record of each line, it doesn't match. How to remove this new line character(#) in I/P file for each line of record? Please see the below records for example
PROVINCIA DE BUENOS AIRE| |1870|AR| #
PROVINCIA DE BUENOS AIRE| |1876|AR| #
BOX 7407 PRINCETON| |085437407|US|NJ#
5756 2 A CAPITAL FEDERAL| |1431|AR|00#
Note: This New line character is not matching the string "#".
Please help me guys, so many objects are related with this concept. I appreciate quick response. Please.
Thanks
SaiHi Arun, Ravi,
I wrote the code like this, here 'fil_curre' is currency key.
IF <l_wa_file_data>-fil_curre CS cl_abap_char_utilities=>newline.
REPLACE ALL OCCURRENCES OF REGEX cl_abap_char_utilities=>newline
IN <l_wa_file_data>-fil_curre WITH ''.
ENDIF.
While executing the code, the cursor here, simply jumps to next step.
Any enhancements to this code or any new ideas?
Thanks
Sai
Maybe you are looking for
-
Completeness indicator of an asset missing
Dear FI-AA experts, We are on 46C and have a problem with the asset module. We have assigned the cost center in the time-dependent tab as a required field. Yet we are able to save and post to an asset that does not have a cost center assigned. Now I
-
Remove Bridge Favorite that no longer exist?
In CS2 Bridge, How do I remove a "favorite" from the favorite menu if the favorite folder does no longer exist. The "remove from favorite menu" command does not show up when a non existent folder is selected. I have all these folders that were delete
-
Hard drive chatters for a long time whenever I go on the Internet
For some reason, whenever I click on a new website, the hard drive on my iMac starts chattering (accessing) for about 30 seconds. Also, at the beginning of every on-line session, it chatters for about a minute. Also it will not do anything until th
-
Font Size Change works on all except menu & Lists
Hi folks. I've searched the forum and gone through about 100 pages of issues with Font size and font changes but have not found an answer that fixes the issue i'm having. Issue: I change the font size in Menu, options, screen/keyboard. This change
-
How do I go back to Tiger until Leopard fixed?