Chr()

What is the number for a tab for the chr() function?

hi,
Is 9
Connected to Oracle Database 10g Express Edition Release 10.2.0.1.0
Connected as hr
SQL>
SQL> SET SERVEROUTPUT ON
SQL> BEGIN
  2     dbms_output.put_line('hi' || chr(9) || 'you');
  3  END;
  4  /
hi     you
PL/SQL procedure successfully completed
SQL> Regards,

Similar Messages

  • Export to text and chr(13)||chr(10)

    Hi All,
    I have report (10g) and one column that formatted by PL/SQL to have multiply rows in it. This achieved by adding chr(13)||chr(10) to the row, so I have multiply rows result on report output.
    But when the same report is exported to text file, then chr(13)||chr(10) are ignored and result is one long row instead multi-rows…
    Is the way to overcome such result in export?
    Thank you.
    Edited by: user555411 on Nov 10, 2008 8:02 AM

    You can get multiple lines by using repeating frames. That's on the line level.
    On the field level, for example, if you have a varchar2 field containing string with 50 characters, but want to display in two lines, you can add a field in report layout that is not long enough for 50 char, but make the length of the box vertically variable in Property Palette. So when there is not enough space to show the whole string, it will go to next line.
    You can try this if inserting chr(13) or chr(10) can't do what you want.

  • Copying a table with the right-click menu in schema browser fails to copy comments when string has single quote(s) (ascii chr(39))

    Hi,
    I'm running 32-bit version of SQL Developer v. 3.2.20.09 build 09.87, and I used the built in context menu (right-clicking from the schema browser) today to copy a table.  However, none of the comments copied.  When I dug into the PL/SQL that the menu-item is using, I realized that it fails because it doesn't handle single quotes within the comment string.
    For example, I have a table named WE_ENROLL_SNAPSHOT that I wanted to copy as WE_ENROLL_SNAPSHOT_V1 (within same schema name)
    1. I right-clicked on the object in the schema browser and selected Table > Copy...
    2. In the pop-up Copy window, I entered the new table name "WE_ENROLL_SNAPSHOT_V1" and ticked the box for "Include Data" option.  -- The PL/SQL that the menu-command is using is in the "SQL" tab of this window.  This is what I extracted later for testing the issue after the comments did not copy.
    Result: Table and data copied as-expected, but no column or table comments existed.
    I examined the PL/SQL block that the pop-up window issued, and saw this:
    declare
      l_sql varchar2(32767);
      c_tab_comment varchar2(32767);
      procedure run(p_sql varchar2) as
      begin
         execute immediate p_sql;
      end;
    begin
    run('create table "BI_ETL".WE_ENROLL_SNAPSHOT_V1 as select * from "BI_ETL"."WE_ENROLL_SNAPSHOT" where '||11||' = 11');
    select comments into c_tab_comment from sys.all_TAB_comments where owner = 'BI_ETL' and table_name = 'WE_ENROLL_SNAPSHOT' and comments is not null;
    run('comment on table BI_ETL.WE_ENROLL_SNAPSHOT_V1 is '||''''||c_tab_comment||'''');
    for tc in (select column_name from sys.all_tab_cols where owner = 'BI_ETL' and table_name = 'WE_ENROLL_SNAPSHOT')
        loop
       for c in (select comments from sys.all_col_comments where owner = 'BI_ETL' and table_name = 'WE_ENROLL_SNAPSHOT' and column_name=tc.column_name)
       loop
       run ('comment on column BI_ETL.WE_ENROLL_SNAPSHOT_V1.'||tc.column_name||' is '||''''||c.comments||'''');
    end loop;
    end loop;
    EXCEPTION
      WHEN OTHERS THEN NULL;
    end;
    The string of the table comment on WE_ENROLL_SNAPSHOT is this:
    WBIG table of frozen, point-in-time snapshots of Enrolled Students by Category/term/pidm. "Category" is historically, and commonly, our CENSUS snapshot; but, can also describe other frequencies, or categorizations, such as: End-of-Term (EOT), etc. Note: Prior to this table existing, Census-snapshots were stored in SATURN.SNAPREG_ALL. All FALL and SPRING term records prior-to-and-including Spring 2013 ('201230') have been migrated into this table -- EXCEPT a few select prior to Fall 2004 (200410) records where there are duplicates on term/pidm. NO Summer snapshots existed in SNAPREG_ALL, but were queried and stored retroactively (including terms prior to Spring 2013) for the purpose of future on-going year-over-year analysis and comparison.
    Note the single quotes in the comment: ... ('201230')
    So, in the above PL/SQL line 11 grabs this string into "c_tab_comment", but then line 12 fails because of the single quotes.  It doesn't know how to end the string because the single quotes in the string are not "escaped", and this messes up the concatenation on line 12.  (So, then no other column comments are created either because the block throws an error, and goes to line 22 for the exception and exits.)
    When I modify the above PL/SQL as my own anonymous block like this, it is successful:
    declare
      c_tab_comment VARCHAR2(32767);
    begin
    SELECT REPLACE(comments,chr(39),chr(39)||chr(39)) INTO c_tab_comment FROM sys.all_TAB_comments WHERE owner = 'BI_ETL'   AND table_name = 'WE_ENROLL_SNAPSHOT'  AND comments IS NOT NULL;
    EXECUTE IMMEDIATE 'comment on table BI_ETL.WE_ENROLL_SNAPSHOT_V1 is '''||c_tab_comment||'''';
    for tc in (select column_name from sys.all_tab_cols where owner = 'BI_ETL' and table_name = 'WE_ENROLL_SNAPSHOT')
        loop
       for c in (select REPLACE(comments,chr(39),chr(39)||chr(39)) comments from sys.all_col_comments where owner = 'BI_ETL' and table_name = 'WE_ENROLL_SNAPSHOT' and column_name=tc.column_name)
       loop
       EXECUTE IMMEDIATE 'comment on column BI_ETL.WE_ENROLL_SNAPSHOT_V1.'||tc.column_name||' is '||''''||c.comments||'''';
    end loop;
    end loop;
    EXCEPTION
      WHEN OTHERS THEN NULL;
    end;
    On lines 4 and 8 I wrapped the "comments" from sys.all_tab_comments and sys.all_col_comments with a replace command finding every chr(39) and replacing with chr(39)||chr(39). (On line 8 I also had to alias the wrapped column as "comments" so line 10 would succeed.)
    Is this an issue with SQL Developer? Is there any chance that the menu-items can handle single quotes in comment strings? ... And, of course this makes me wonder which other context menu commands in the tool might have a similar issue.
    Thoughts?
    thanks//jacob

    PaigeT wrote:
    I know about quick drop, but it isn't helpful here. I want to be able to right click on a string or array wire, navigate to the string or array palette, and select the corresponding "Empty?" comparator. In this case, since I do actually know where those functions live, and I'm already using my mouse to right click on the wire, typing ctrl-space to open quick drop and then typing in the function name is actually more work than navigating to it in the palette. It would just be nice to have it on hand in the location I naturally go to look for it the first time. 
    I don't agree with this work flow.  Right hand on mouse, left hand on home keys.  Pressing CTRL + Space is done with the left hands, and then you could assign "ea" to "Empty Array" both of which is accessible with the left hand.  Darren posted a bunch of great shortcuts for the right handed developer.
    https://decibel.ni.com/content/docs/DOC-20453
    This is much faster than waiting for any right click menu navigation, even if it is found in the suggested subpalette.
    Unofficial Forum Rules and Guidelines - Hooovahh - LabVIEW Overlord
    If 10 out of 10 experts in any field say something is bad, you should probably take their opinion seriously.

  • Removing binary characters/ special chrs from string entered by user

    Dear gurus,
    I have a string entered by users in database from where i am pulling data into SAP BW.
    Th problem is that the string contains binary characters. It is showing error and cant be upoaded
    Is there any function module/ code that removes binary data an special chrs from string??
    Pls help. thanks.

    Hi,
    U can use the Tcode:  RSKC,
    to allow the special charecters...
    otherwise if u r sure that u r facing only that type of errors..then u can allow the
    errors in ERROR HANDLING tab present in the infopackage screen < Update tab
    bye,
    sunil4points

  • How to insert a carriage return chr(13) to a message box

    On my form I have a button, called "Instruction".
    When the user clicks on it, I present him with a message box expalining key points about the form and the fields.
    Here a dummy example:
    xfa.host.messageBox("Hello Everyone! The form contains 5 required field identied by Red border. Make sure you fill them before submitting the form. To calculate the winner percentage you Must fill in the number of tables first."
    , "INSTRUCTION", 3);
    There must be a way to insert a line in a message box, such as chr(13).
    What's the syntax?

    To enter a CR in a string for javascript use a \n in the text of your string.
    paul

  • How to send chr$(195) in Labview (MAX)

    I have an elderly Philips DMM that needs re-calibrating, using the GPIB commands.  I need to send it a character string starting with CHR$(195).  I have a GPIB-USB-HS interface and run Labview 9.  To get me going I have been using the Measurement and Automation Tool.  Sorry this is a newbie question but I can't find the answer.  Thanks
    Jeremy
    Solved!
    Go to Solution.

    Converting a numeric (U8) has actually been discussed a great number of times. Shown below are some of your options with the numeric being displayed in hex. The string constant is also set for hex display.
    Attachments:
    send hex.png ‏15 KB

  • Ff comes on, I go to site w/ pics the screen goes black & then w/ with a bubble from the bottom saying recovery from igfx display failure..Chr & Op = OK

    Firefox comes on, I go to a site rich w/ visual content & then the screen goes black & then white w/ with a bubble from the bottom bar saying recovery from igfx display failure..this used to happen on my Chrome browser (the Chr browser recovered spontaneously But I removed & reset it... still the problem went on & I quit using Chr for2-3 mos. There never was a problem on Opera. Hey! OPERA rule. As foe IE 8. That instrument is completely useless. Even all areon IE appears to be dead...Thanx!

    Try disabling hardware acceleration in Firefox.
    https://support.mozilla.org/en-US/kb/upgrade-graphics-drivers-use-hardware-acceleration#w_turning-off-hardware-acceleration

  • Regarding chr() function

    I am using function chr(13) in the form to get one Line(to move the remaining contents to next line). Instead of moving to next line, function is displaying some special character.
    I am using 10g forms. Whether chr(13) is supported by form or not??
    Edited by: user648759 on May 29, 2009 2:33 AM
    Edited by: user648759 on May 29, 2009 2:35 AM

    Hello,
    As well as I know chr(13) for new line is used in HTML (When we display strings in Html page).
    Regards
    Danish

  • CHR(10) function doesn't work in OBIEE

    Hi
    I wanted to display multiple column values in the same cell in OBIEE.
    In order to achieve this, I concatenated all the columns into a single column separated by CHR(10).
    This works fine in SQL, but doesn't work in OBIEE.
    Columns in the table
    Address1 City State Country Zip Code.
    12345, Main Street Fullerton California     USA     92835
    The Result needed
    12345, Main Street
    Fullerton
    California     
    USA 92835
    This is a specific requirement.
    Essentially, I need to know how can we have new line/carriage return/next line on OBIEE?
    Your earliest help would be highly appreciated
    Thanks
    ~Vijay

    Hi
    Thanks for your reply.
    Do you mean to use Narrative View and add the HTML Content there.
    If Yes, I guess it wouldn't meet my requirement.
    In fact, I want to use this in a pivot table so that user can select the customer name from the Page level and i can display relevant details based on user selection.
    In fact, I need to display the customer demograhics in one column and product info in next column.
    Also other fact/dimension info as row level objects in the same view.
    Any help/input would be highly appreciated
    Thanks
    ~Vijay

  • Remove the last chr(13) & chr(10) from a string

    Hello, all.
    I'm trying to get confirmation files to upload to Amazon for their "Charge When Ship" program.  I've got the file creating as it should be with one minor exception.
    I'm setting a variable, giving it the header column information and ending that with chr(13) & chr(10); then I'm looping through a query to add the information, each iteration tacks chr(13) & chr(10) to the end of it; then I'm taking that variable and writing the data to a file using CFFILE.
    But I think that the last chr(13) & chr(10) is causing Amazon servers to think there's one more line of information than there really is, and it's erroring.
    Can anyone tell me how to remove that last chr(13) & chr(10) from the variable before writing it to file?
    Thanks,
    ^_^

    giving it the header column information and ending that with chr(13) & chr(10); then I'm looping through a query to add the information, each iteration tacks chr(13) & chr(10) to the end of it; then I'm taking that variable and writing the data to a file using CFFILE.
    Trim() the variable or change the code so it does not generate an extra new line.
    Since your content has a header, place the new line characters at the beginining of each query iteration.
    #headerColumnsHere#  <!--- notice there is no new line after the column header  information --->
    <cfouput query="yourQuery">#chr(13)##chr(10)# #ColumnA##ColumnB#...etcetera...</cfoutput>

  • Chr(7)

    Hi, how to send a command to a CASH DRAWER for open?
    According from direction, it need chr(7) as command for action CASH DRAWER to open.
    Anybody can help me in coding?
    Thank You.

    jiong_rong wrote:
    CASH DRAWER is connected to PC with RJ232Have a look at RXTX:
    http://forum.java.sun.com/thread.jspa?forumID=31&threadID=698876

  • Chr(10) not working in isql *plus

    Hi,
    Im using oracle 9i. i executed the following statement in sql * plus,
    select 'sankar'||chr(10)||'naraya" from dual
    the output is ,
    sankar
    naraya
    but when i execute the same statement in iSQL *Plus
    the output is
    sankar naraya
    i need the first output in isql * plus. What to do?

    Hello Sankar,
    Here you go
    This can be resolved by modifying the preferences in the iSQL*Plus session to choose a text output format rather than the default HTML format. 
    Select the Preferences button at the top right and then select the Set system variables option to make preference-setting changes. 
    Move down the alphabetical list of settings until you find the Markup HTML area, as shown in Figure 10. 
    Within this area, set the Preformat option to On.
    Clicking OK and OK saves the setting and returns you to the work screen.Here is the link for your reference.
    http://www.dmacc.edu/instructors/rebullard/iSQLPlus%20Users%20Guide.doc
    Cheers!!!
    Bhushan

  • Chr function

    CREATE TABLE TEST
    (NAME_NUM               CHAR (8)      DEFAULT (LPAD(CHR(0),008,CHR(0))),
    ZAP_NAME               CHAR (2)      DEFAULT (LPAD(CHR(0),002,CHR(0))),
    SYSC_VARIABLE          VARCHAR (230) DEFAULT (LPAD(CHR(0),230,CHR(0))),
    );in above create table command what does "(LPAD(CHR(0),008,CHR(0)))" means ?

    user511621 wrote:
    CREATE TABLE TEST
    (NAME_NUM               CHAR (8)      DEFAULT (LPAD(CHR(0),008,CHR(0))),
    ZAP_NAME               CHAR (2)      DEFAULT (LPAD(CHR(0),002,CHR(0))),
    SYSC_VARIABLE          VARCHAR (230) DEFAULT (LPAD(CHR(0),230,CHR(0))),
    );in above create table command what does "(LPAD(CHR(0),008,CHR(0)))" means ?The chr(0) is the equivalent of a NULL, and what this function is doing is when a new record is created if there is no data supplied for the name_num, zap_name,sysc_variable then they will be filled with nulls ie NAME_NUM will have 8 nulls in it.
    The function is using LPAD "left pad" to pad on the left a single null character with enough nulls to fill the field.
    hope this is clear enough.
    Edited by: DavidGD on Feb 9, 2009 9:58 PM

  • CHR function for 18 times space?

    hi,
    Is there any function if i want 18 time space in my dbms output messages.
    I am using CHR(32) as
    DBMS_OUTPUT.PUT_LINE(chr(32)||chr(32)||chr(32)||chr(32)'** End Time ** : '||systimestamp );
    or
    DBMS_OUTPUT.PUT_LINE(' ** End Time ** : '||systimestamp );

    Like say Frank Kulash
    By default, SQL*Plus trims spaces from the beginning of each output line. To override that default, and allow spaces there, use FORMAT WRAPPED when you SET SERVEROUTPUT ON.
    SET  SERVEROUTPUT ON   FORMAT WRAPPED
    may i use also LPAD(' ',18)
    Yes
    can u explain,which 1 is good manner of programming?
    It is the same, chr(32) is ' '.
    I prefer chr(32) because is most visual. With it i understand better the code, but it is the same

  • To add an additional field of text of 50 chrs in bseg & bsis

    In trxn FB01 or F-02, we have a line item text of 50 chrs (sgtxt). We want to have one more field of text, of 50 chrs. Can i append structure in BSEG & BSIS & mount on the screen ??
    Or is there any other way ??
    thanks
    amit

    Hi,
    I have similar error . I am gettting short dump .And it says
    "Screen "SAPLKACB" 9999 could not be generated.
    When I go look at that screen in ecc6 and try to do a syntax check, I get an error stating that field cobl-yystpi_ind is not in the data dictionary.  The code is looking for this field but it is not there."
    I checked COBL. cobl-yystpi_ind is there and it is active.
    In oxk3 i can see the field cobl-yystpi_ind.
    in oxk1 the subscreen 9999 is not there.
    Is the dump b'coz of not adding subcreen thru oxk1.
    Is that mandatory to maintain the subscreen in oxk1 which is using those fields which are added thru oxk3?
    Its urgent and any help is appreciated and points will be rewarded.
    Regards,
    Pria.

  • Chr(166) is null in Forms 10g runtime

    Hi!
    In one form I use the following line to replace characters in a string:
      v_val := translate( v_val, '#$', chr( 166 ) || chr( 164 ) );The form was just migrated from 6i, and in that environment still runs fine. In the 10g environment it generated an error. As I found out, to my surprise, the string
       chr( 166 ) || chr( 164 )is actually NULL in the 10g session.
    I am pretty sure this has to do with the fact that the 6i version connects to a different database (8i) from the 10g version (9i). There are probably differences in charactersets in the database, but also the runtime charactersets may differ. I have tried all kinds of settings, but no luck.
    Does anyone know from the top of their head, how this problem may be explained, and hopefully, resolved?
    Thanks!
    Remco

    To see if it has to do with the database character set (very likely) do this in SQL*Plus for both databases:
    SQL> select chr( 166 ) || chr( 164 ) from dual;
    CH
    ¦¤

Maybe you are looking for

  • ICal default view

    How can I change default view back to week view in iCal, as it was before update (as it displays when searching)?

  • SAP-Script; Is it possible to handle the BOX -Statement dynamic?

    Hi Scripters! My consultant wants a box around some information in a SAP-Script form. Normally this is quite easy, BUT in this case i have the information (which needs the box around) printed after the positions. So problem is: the box can not have a

  • Ejecting iPod

    I've just gotten a the latest U2 iPod and have successfully loading all of my songs and videos onto it. But, it is now fully charged and even though the screen says "iPod update is complete" I try using the eject iPod button but the program keeps tel

  • Archivelog off - then back on again.

    Greetings , I was asked to turn off archivelog and flashback a few days ago and since the database collectors would not be talking to the database when these features were turned off I complied. Now I suspect in the next day or so they will finish th

  • How can we give values to the variable

    Oracle Forms6i Hai All I am generating an daily attendance regarding shift basis.In that i have written an ifelse condition it work successfull and but it fetches only 350 row out of 800. I have declared a variable and i need to know how to assign va