Issues caused by changing length semantics

Hi All,
Our database was formerly using BYTE for columns of tables and for stored procedures. We recently changed the Length Semantics to CHAR but caused some issues. An ORA-06502 pl/sql numeric or value error character string buffer too small appears when we access the database's stored procedures via Java. What could be the possible cause of this? Could you give me some paths to take in troubleshooting this issue?
Thanks to all!
Edited by: 1002671 on 25.4.2013 23:55

1002671 wrote:
Thanks for answering Sir! Are you kidding!!! No 'Sir' please... Common I don't know anything yet.
Correct me if I'm wrong but doesn't CHAR already handle multi-byte characters passed to or used in stored procedures? I'm really not that knowledgeable when it comes to the effects of changing the Length Semantics. We already changed the columns from VARCHAR2(BYTE) to VARCHAR2(CHAR). The problem lies within the stored procedures.I'm not clear on your doubt, but please check this -
Link: http://docs.oracle.com/cd/E11882_01/appdev.112/e10472/datatypes.htm (Section 'Declaring Variables for Multibyte Characters')
>
When declaring a CHAR or VARCHAR2 variable, to ensure that it can always hold n characters in any multibyte character set, declare its length in characters—that is, CHAR(n CHAR) or VARCHAR2(n CHAR), where n does not exceed FLOOR(32767/4) = 8191.
>
What i feel is you getting confused with the SQL data-type 'VARCHAR2' (i.e. used in specifying column type) and PL/SQL data-type 'VARCHAR2' (i.e. used while declaring variables)
Then check this : difference between BYTE & CHAR
Read and thoroughly research each comment given by the Experts there.

Similar Messages

  • Issue caused by change of Publisher ID and Product ID?

    I developed a Windows Phone app for a charity free of charge. I was developing the app under my own moniker and submitted all my code to a GitHub repository they had from when they had the iPhone app developed. When it came to publishing the app,
    it was one of their IT own staff which did the job, not me, and they registered themselves with Microsoft.  They received a new Publisher ID and Product ID as part of the app submittal process and updated GitHub.
    I downloaded the changes from GitHub and am no longer able to run the app from Visual Studio (2013 Ultimate) on an emulator or a physical device.  I can revert back to the original files for Package.appxmanifest, WMAppManifest.xml and the app is
    able to run.  However, this leaves me running with out of date code.
    Is the issue that I am not a registered developer with their Publisher ID?  If not, then what is the solution, other than running with the original files?  I have seen other suggestions that it may be the SplashScreen causing the issue but that
    is not the issue here.
    Thx

    This should do the trick for you:  If you're asked for the password to your previous Apple ID when signing out of iCloud - Apple Support

  • Oracle length semantics migration documention

    Due to the oracle documention to migrate length semantics:
    To convert an existing schema and its associated data from byte semantics and a single-byte character set to character semantics and a multibyte character set, such as UTF-8, you need only follow these steps: [The following steps have been corrected since the magazine was printed.]
    1. Export the schema.
    2. Issue an ALTER SYSTEM SET NLS_LENGTH_SEMANTICS=CHAR SCOPE=BOTH command on the target database.
    3. Stop and restart the instance so that the parameter change takes effect.
    4. Drop the original schema.
    5. Recreate the original schema and its tables (you can use import's show=Y option to get the CREATE TABLE statements). Columns in the recreated tables will use character semantics, because that's now the default.
    6. Import the schema into the target database using the IGNORE=Y import option.
    What is the meaning of the terms target and original?
    Suppose there is a (source) database with length semantics byte. If a (target) database
    is to be created as a clone of the (source) database, except for the length semantic char, does one have to migrate the (source) database first?
    Or rather, why is it not possible to
    1. Export the data from the source database with length semantic byte,
    2. Create a target database with length semantics char,
    3. Import the data from the source database?)

    This documentation is, unfortunately, poorly written.
    If you want to migrate data from one database to another, with both databases having different character sets, you can avoid some data expansion issues, if you migrate to character set semantics at the same time.
    You cannot just export data, and import it into a character semantics database, because export/import preserves original semantics of the exported tables.
    Note: there is actually no such thing as a character semantics database. Character semantics is a column/variable property. The "character semantics database" is a confusing, though commonly used, term that actually means an instance which has NLS_LENGTH_SEMANTICS set to CHAR in its initialization file. The only significant meaning of this parameter is to be the default for session-level NLS_LENGTH_SEMANTICS. It is used for sessions that do not set this parameter explictly (through environment variable or ALTER SESSION). The session-level parameter is significant for CREATE TABLE/PROCEDURE/FUNCTION/PACKAGE [BODY] statements and tells the default for column and variable declarations that do not specify BYTE or CHAR explicitly.
    To migrate semantics of an original schema you need to create a script that will contain all CREATE statements needed to recreate this schema (at least CREATE {TYPE | TABLE | MATERIALIZED VIEW | PROCEDURE | FUNCTION | PACKAGE [BODY]}). Then, you can just add the ALTER SESSION SET NLS_LENGTH_SEMANTICS=CHAR after any CONNECT command in this script. You can than run the script in the target database. How you create the script is irrelevant. You can use any reverse-engineering tool available (e.g. SHOW=Y option of import, DBMS_METADATA package, etc.)
    After you pre-create the schema with the new semantics, you can import the data from the original (source) database with IGNORE=Y. The original semantics saved in the export file will be ignored for pre-created objects.
    Note: PL/SQL may need manual corrections to migrate to character semantics. For example, SUBSTRB used to trim values before assignment may need to be replaced with SUBSTR.
    -- Sergiusz

  • [svn] 2815: Fixed issue caused by revision 2234.

    Revision: 2815
    Author: [email protected]
    Date: 2008-08-12 07:35:00 -0700 (Tue, 12 Aug 2008)
    Log Message:
    Fixed issue caused by revision 2234.
    tests Passed: checkintests, fdbunit
    Needs QA: YES
    Needs DOC: NO
    Bug fixes: SDK-16323
    API Change: NO
    Reviewer: jspiro
    Code-level description of changes:
    embedding/avmplus/ActionBlockEmitter.java
    Added clearMethodInfo() call to the end of FinishMethod().
    Modified setPosition() to no longer set debug_linenum to -1 when
    the position is not greater than zero. See comment for
    explanation.
    semantics/CodeGenerator.java
    Modified evaluate(Context, ProgramNode) to call clearMethodInfo()
    before FinishMethod() if StartMethod() has been called.
    Ticket Links:
    http://bugs.adobe.com/jira/browse/SDK-16323
    Modified Paths:
    flex/sdk/trunk/modules/asc/src/java/macromedia/asc/embedding/avmplus/ActionBlockEmitter.j ava
    flex/sdk/trunk/modules/asc/src/java/macromedia/asc/semantics/CodeGenerator.java

    Revision: 2815
    Author: [email protected]
    Date: 2008-08-12 07:35:00 -0700 (Tue, 12 Aug 2008)
    Log Message:
    Fixed issue caused by revision 2234.
    tests Passed: checkintests, fdbunit
    Needs QA: YES
    Needs DOC: NO
    Bug fixes: SDK-16323
    API Change: NO
    Reviewer: jspiro
    Code-level description of changes:
    embedding/avmplus/ActionBlockEmitter.java
    Added clearMethodInfo() call to the end of FinishMethod().
    Modified setPosition() to no longer set debug_linenum to -1 when
    the position is not greater than zero. See comment for
    explanation.
    semantics/CodeGenerator.java
    Modified evaluate(Context, ProgramNode) to call clearMethodInfo()
    before FinishMethod() if StartMethod() has been called.
    Ticket Links:
    http://bugs.adobe.com/jira/browse/SDK-16323
    Modified Paths:
    flex/sdk/trunk/modules/asc/src/java/macromedia/asc/embedding/avmplus/ActionBlockEmitter.j ava
    flex/sdk/trunk/modules/asc/src/java/macromedia/asc/semantics/CodeGenerator.java

  • [svn] 4690: * Fixed an issue caused by revision 4330.

    Revision: 4690
    Author: [email protected]
    Date: 2009-01-27 13:12:47 -0800 (Tue, 27 Jan 2009)
    Log Message:
    * Fixed an issue caused by revision 4330. Due to leaving the backing
    variables and functions in the public namespace, they were showing
    up in FlexBuilder's code hinting and DataGrid's without specified
    columns. Now they are "hidden" in the mx_internal namespace.
    tests Passed: checkintests, mxunit databinding
    Needs QA: YES
    Needs DOC: NO
    Bug fixes: SDK-18853, SDK-18604
    API Change: NO
    Reviewer: Pete F.
    Code-level description of changes:
    frameworks/projects/framework/src/mx/binding/BindingManager.as
    Modified set() to no longer require a userNamespace arg. The
    mx_internal namespace is now assumed.
    modules/compiler/src/java/flex2/compiler/as3/genext/GenerativeSecondPassEvaluator.java
    Renamed makeAttrListPublic() to makeMxInternalAndRemoveOverride(DefinitionNode)
    and updated it to handle IdentifierNodes in the
    AttributeListNode's items.
    Added makeMxInternalAndRemoveOverride(IdentifierNode, Iterator) as
    a helper method for common code in
    makeMxInternalAndRemoveOverride(DefinitionNode).
    modules/compiler/src/java/flex2/compiler/as3/genext/GenerativeClassInfo.java
    Modified AccessorInfo's constructor to create a more unique backingPrefix.
    Modified getQualifiedBackingPropertyName() to always use the
    mx_internal namespace.
    modules/compiler/src/java/flex2/compiler/as3/binding/BindableProperty.vm
    Modified BindingManager.set() call to no longer pass in the userNamespace.
    modules/compiler/src/java/flex2/compiler/as3/binding/BindableFirstPassEvaluator.java
    Modified evaluate(Context, ClassDefinitionNode) to add an import
    for mx_internal.
    Ticket Links:
    http://bugs.adobe.com/jira/browse/SDK-18853
    http://bugs.adobe.com/jira/browse/SDK-18604
    Modified Paths:
    flex/sdk/trunk/frameworks/projects/framework/src/mx/binding/BindingManager.as
    flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/as3/binding/BindableFirstPassEval uator.java
    flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/as3/binding/BindableProperty.vm
    flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/as3/genext/GenerativeClassInfo.ja va
    flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/as3/genext/GenerativeSecondPassEv aluator.java
    flex/sdk/trunk/modules/compiler/src/java/flex2/compiler/as3/managed/ManagedProperty.vm

    After days of tweaking and suspecting antivirus behind the problems, I reverted back to MSI's default drivers as listed on the product webpage. It appears to be stable so far. Well at least I can use it now.
    I'm not sure if Killer's drivers are suck or MSI don't allow drivers 'not certified by them'. But its bad news if someone wants to use the latest drivers considering we're talking cutting edge gaming laptops here.

  • Editing the Text May Cause Layout Changes Message

    I have tons of files created in old illustrator 6.0 and now that I have CS2 loaded on Mac OS X.5.8 I'd like to open and edit some of these documents.
    It says, "This file contains text that was created in a previous version of Illustrator. This legacy text must be updated before you can edit it." It asks you to either Choose Update or OK to update later.
    So I chose Update for one of the files, save without compression. Then I open it and it looks OK. I thought that this UPDATING would allow me to work with the document freely. However, when I attempt to change some type I get a warning saying that "Editing the text may cause layout changes.• Choose Copy Text Object to update the text and preserve the original layout as a separate object. • Choose Update to update the text without creating a separate reference object." Why am I getting this warning? Do I really have to click on every bit of type I wish to edit and deal with this message each time? If I choose "update" the type disappears entirely and if I choose "copy text object" it grays out and I can't select it. Either way I have no way of editing my document.
    Please advise and keep answers as simple as possible.
    Thanks.
    http://s277.photobucket.com/albums/kk61/exitrealestate001/?action=view&current=bydefault2. jpg
    http://i277.photobucket.com/albums/kk61/exitrealestate001/bydefault2.jpg
    <a href="http://s277.photobucket.com/albums/kk61/exitrealestate001/?action=view&current=bydefault2. jpg" target="_blank"><img src="http://i277.photobucket.com/albums/kk61/exitrealestate001/bydefault2.jpg" border="0" alt="Photobucket"></a>
    [IMG]http://i277.photobucket.com/albums/kk61/exitrealestate001/bydefault2.jpg[/IMG]

    Hi Mylenium,
    Wow. What a nightmare. We're not talking just retyping, it's really re-typesetting etc.
    Tell me, if I were to copy and paste the old document into a new one or something like that, would that bypass this problem?
    Also, someone in another thread which I started (link to it below) mentioned that I could "batch update the files as CMYK and with the legacy type updated as well." I know that it's separate issue, but I was wondering if I were to do this, might it help with this Text Editing issue?
    http://forums.adobe.com/message/2740960#2740960
    Please advise.
    Thanks in advance, very much.

  • Data Length Semantics?

    Dear memebers,
    what is Data Length Semantics property of text box?
    what's its behavior?
    thanks
    Muhammad Nadeem
    [email protected]

    Values CHAR, BYTE, null
    Refer to Built-in
    GET_ITEM_PROPERTY
    Usage Notes
    - If a null value is specified, then byte semantics will be used unless the environment variable NLS_LENGTH_SEMANTICS is set to CHAR when the form is compiled.
    - When the Synchronize with Item property is set, DATA_LENGTH_SEMANTICS will be ignored in a subordinate mirror item. The DATA_LENGTH_SEMANTICS property is always taken from the master mirror item. A compiler (generator) warning will be issued if a non-null value is specified in a subordinate mirror item.
    - A compiler (generator) warning will also be issued if a non-null value is specified in an item whose datatype is neither CHAR, ALPHA, nor LONG.

  • [svn:fx-4.x] 14245: * Fixed inactive incremental compilation issue where library changes

    Revision: 14245
    Revision: 14245
    Author:   [email protected]
    Date:     2010-02-18 08:53:00 -0800 (Thu, 18 Feb 2010)
    Log Message:
    Fixed inactive incremental compilation issue where library changes
      were not causing application recompilation.
    QE notes: We should add a JUnit OEM API test for this scenario.
    Doc notes:
    Bugs: SDK-25513
    Reviewer: Pete F.
    Tests run: checkintests
    Is noteworthy for integration: yes, affects active incremental
                                   compilation from FB.
    Code-level description of changes:
      Modified the loadCompilationUnits() used by
      flex2.tools.oem.Application to pass the "sources" and "units" args
      down, so that the PersistenceStore can populate them.  This is
      necessary to get OEMUtil.isRecompilationNeeded() called in
      Application.recompile().
    Ticket Links:
        http://bugs.adobe.com/jira/browse/SDK-25513
    Modified Paths:
        flex/sdk/branches/4.x/modules/compiler/src/java/flex2/compiler/CompilerAPI.java

    Dear Pallavi,
    Very useful post!
    I am looking for similar accelerators for
    Software Inventory Accelerator
    Hardware Inventory Accelerator
    Interfaces Inventory
    Customization Assessment Accelerator
    Sizing Tool
    Which helps us to come up with the relevant Bill of Matetials for every area mentioned above, and the ones which I dont know...
    Request help on such accelerators... Any clues?
    Any reply, help is highly appreciated.
    Regards
    Manish Madhav

  • Issue with PO change output - Service line items

    Hi All,
    This is issue with PO change output. We have PO with line item 10, 20 and item 10 has 4 service line items. PO is approved and initial print out is taken.
    Some one goes and makes changes to 1st service line items of PO line item 10.
    A change output gets triggered. When this output is printed, it prints line item 10 details. This is standard functionality as this item is changed. But its printing all the service line items for this PO line item. Consider a case where there are 3000 service lines for a PO item. If I add 1 service item to this PO line item, the change form prints 3001 services for that line item. There were no changes done to first 3000 service line items.
    Currently PO change form takes care of changes at PO line item but it does not take care of changes at service line item level.
    Is there any setting that needs to be done for this so that it only considers the changes at Service line item level also.
    Regards,
    Shahu

    If you're using a standard form, send a message to SAP. Otherwise make a change in the form.

  • HT1918 I'm having some issues trying to change my account billing---I have a new debit card and i need to punch in the new number but when i go to edit my info itunes says my 'session has timed out.' i've logged in and out more than once. what's the probl

    i'm having some issues trying to change my account billing---I have a new debit card and i need to punch in the new number but when i go to edit my info itunes says my 'session has timed out.' i've logged in and out more than once. what's the problem?

    Try to change the credit information from your iphone or other ios device. Tap on settings > store > tap Apple ID > tap view account > tap payment information > change

  • 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
    Michael

    Hi 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

  • How change length name in legend on chart

    Hello.
    version:OBIEE 10.1.3.4.1.090414.1900
    source: Essbase
    I use hierarchy Essbase on the chart.
    And i can't see full name product in legend and i don't understand,
    how change length name in legend?

    user8995811 wrote:
    I don't understand your solve.
    What mean cast(product as Int), it's not work
    I also use drill down in legend, and I should see full name.
    And I have other problem, now drill down work only products name, which length <11http://img693.imageshack.us/img693/8193/pic130.jpg
    will this helpful?
    Thanks,
    Saichand.v

  • Querying CHAR columns with character length semantics unreliable

    Hi again,
    It appears that there is a bug in the JDBC drivers whereby it is highly unlikely that the values of CHAR columns that use character length semantics can be accurately queried using ResultSet.getString(). Instead, the drivers return the value padded with space (0x#20) characters out to a number of bytes equal to the number of characters multiplied by 4. The number of bytes varies depending on the number and size of any non-ascii characters stored in the column.
    For instance, if I have a CHAR(1) column, a value of 'a' will return 'a ' (4 characters/bytes are returned), a value of '\u00E0' will return '\u00E0 ' (3 characters / 4 bytes), and a value of '\uE000' will return '\uE000 ' (2 characters / 4 bytes).
    I'm currently using version 9.2.0.3 of the standalone drivers (ojdbc.jar) with JDK 1.4.1_04 on Redhat Linux 9, connecting to Oracle 9.2.0.2.0 running on Solaris.
    The following sample code can be used to demonstrate the problem (where the DDL at the top of the file must be executed first):
    import java.sql.*;
    import java.util.*;
    This sample generates another bug in the Oracle JDBC drivers where it is not
    possible to query the values of CHAR columns that use character length semantics
    and are NOT full of non-ascii characters. The inclusion of the VARCHAR2 column
    is just a control.
    CREATE TABLE TMP2
    TMP_ID NUMBER(10) NOT NULL PRIMARY KEY,
    TMP_CHAR CHAR(10 CHAR),
    TMP_VCHAR VARCHAR2(10 CHAR)
    public class ClsCharSelection
    private static String createString(char character, int length)
    char characters[] = new char[length];
    Arrays.fill(characters, character);
    return new String(characters);
    } // private static String createString(char, int)
    private static void insertRow(PreparedStatement ps,
    int key, char character)
    throws SQLException
    ps.setInt(1, key);
    ps.setString(2, createString(character, 10));
    ps.setString(3, createString(character, 10));
    ps.executeUpdate();
    } // private static String insertRow(PreparedStatement, int, char)
    private static void analyseResults(PreparedStatement ps, int key)
    throws SQLException
    ps.setInt(1, key);
    ResultSet results = ps.executeQuery();
    results.next();
    String tmpChar = results.getString(1);
    String tmpVChar = results.getString(2);
    System.out.println(key + ", " + tmpChar.length() + ", '" + tmpChar + "'");
    System.out.println(key + ", " + tmpVChar.length() + ", '" + tmpVChar + "'");
    results.close();
    } // private static void analyseResults(PreparedStatement, int)
    public static void main(String argv[])
    throws Exception
    Driver driver = (Driver)Class.forName(
    "oracle.jdbc.driver.OracleDriver").newInstance();
    DriverManager.registerDriver(driver);
    Connection connection = DriverManager.getConnection(
    argv[0], argv[1], argv[2]);
    PreparedStatement ps = null;
    try
    ps = connection.prepareStatement(
    "DELETE FROM tmp2");
    ps.executeUpdate();
    ps.close();
    ps = connection.prepareStatement(
    "INSERT INTO tmp2 ( tmp_id, tmp_char, tmp_vchar " +
    ") VALUES ( ?, ?, ? )");
    insertRow(ps, 1, 'a');
    insertRow(ps, 2, '\u00E0');
    insertRow(ps, 3, '\uE000');
    ps.close();
    ps = connection.prepareStatement(
    "SELECT tmp_char, tmp_vchar FROM tmp2 WHERE tmp_id = ?");
    analyseResults(ps, 1);
    analyseResults(ps, 2);
    analyseResults(ps, 3);
    ps.close();
    connection.commit();
    catch (SQLException e)
    e.printStackTrace();
    connection.close();
    } // public static void main(String[])
    } // public class ClsColumnInsertion

    FYI, this has been mentioned as early as November last year:
    String with length 1 became 4 when nls_lang_semantics=CHAR
    and was also brought up in Feburary:
    JDBC thin driver pads CHAR col to byte size when NLS_LENGTH_SEMANTICS=CHAR

  • Oracle Hint not causing any change to explain plan

    Hi,
    I was facing a problem about ORA-00600 for using Connect by Prior query,
    details of which are at -
    Connect by Prior - ORA-00600: internal error code, arguments: [kkqcbydrv:1
    As is documented by Oracle, workaround for this is to use /*+ NO_UNNEST */ in query.
    I displayed the explain plan for original query and after putting hint in query.
    There is no difference in the explain plans, I am a starter for explain plans and don't know much of it.
    But shouldn't the hint cause some change in explain plan?
    Even the hash values as mentioned in explain plans are same.
    Thanks in advance.
    Av.

    Perhaps it would help if you put the query (with the hint) and the explain plan here.

  • Titles are automatically changing length and shortening - imovie '11 version 9.0.2

    Titles are automatically changing length and shortening no matter what I do. I'm using imovie '11 version 9.0.2  I have tried everything and they keep reverting back to random sizes. I have several 4 sec still pictures and I want the titles to match in length so I make them the same size but as soon as I move away or do anything else the revert back to some random size like 2.2s or 1.2s. I don't know why but it is very frustrating.
    Thanks in advance.

    It's been a month now and I just installed the new update (9.0.4) and it is still doing this. I took a screenshot of what it is doing. I want all of the titles to be the same length as the pictures. They are all 3.9 or so seconds. I drag the titles so they are the same size and then as soon as I do anything else it automatically changes back to this. Any Ideas? I just don't know why it's doing this and it's really bothering me. Please help!

Maybe you are looking for