ORA-01722: invalid number when you use the function TO_CHAR.

Hi all
I was using this query closely for 1 year and it worked fine.

Select to_char (' 2012/12/23 ', ' DD/MM/YYYY') twice;

How ever from Monday onwards it's me back with the following error.

ORA-01722: invalid number

The NLS_DATE_FORMAT is DD-MON-RR in my version of oracle 11g.

Please help me with this.

They should compare these values as values of date instead of under the form of strings. TO_DATE should be used instead of TO_CHAR.

Published by: Saran on January 2, 2012 23:00

Tags: Database

Similar Questions

  • Invalid number when you use to_number function

    Hello
    Both in SQL * more and SQL Deveoper when I type and run

    Select to_number ('1234.64 ','9999.9 ') of double;

    I get ORA-01722: invalid number error. What can be the reason for this error?

    Mikhail says:
    SQL > select to_number('1234.64','9999D9') from double;
    Select double to_number('1234.64','9999D9')
    *
    ERROR on line 1:
    ORA-01722: invalid number

    You pass it a string ("1234.64'") with two digits to the right of the decimal separator, but you tell it that you have only one digit to the right of the decimal separator ('9999 D 9')

  • ORA-01722: invalid number calculation error during the treatment.

    My version of the APEX is Application Express 4.2.6.00.03

    I imported apex application 4.0.2 and his object of decision-making support in my apex.

    Its installed successfully.

    But when I try to run this application it show me this error:

    ORA-01722: invalid number calculation error during the treatment.

    Thank you guys for your help.

    I found the solution.

    There was a problem in the authentication scheme.

    I called function as return function_name in 4.0.2

    but in the Apex 4.2.6 to call a function word return is not necessary.

    He was throwing the error caused that Word back.

  • CC 2015 Illustrator crashes when you use the function "save for Web".

    CC 2015 Illustrator crashes when you use the function "save for Web".

    Hello

    We have published a 19.0.1 hotfix that resolves this problem in discussion on this topic. Please apply the patch to your creative cloud application. The creative cloud application checks the update once a day, so you may see the update immediately.  If you want to force the check for an update at the beginning please logout and log back into the creative Cloud application.

    Link to 19.0.1 release notes: https://helpx.adobe.com/illustrator/kb/illustrator-cc-2015-crash-bug-fixes-19-0-1.html

    Kind regards

    Ashutosh

    The name of the Illustrator team engineering

  • ORA-01722: invalid number - when the last column has numbers that have a decimal separator

    Here are examples of data-

    FRT, 1.64, VAT, 23,36

    FRT, 1.64, VAT, 23,36

    When I try to convert 1.64 to_number everything is good, but when I do the same thing with 23,36 I get the following error

    ORA-29913: error in executing ODCIEXTTABLEFETCH legend

    ORA-01722: invalid number

    ORA-06512: at "SYS." ORACLE_LOADER', line 52

    I tried this query example

    Select to_number (CONSIGNMENT_NET_VALUE) as Col1 of DUMP_EXT

    Select to_number (CONSIGNMENT_NET_VALUE, '9999999999D' 99999', NLS_NUMERIC_CHARACTERS = ",". ") as Col1 DUMP_EXT-> 268906.1

    make the same mistake - any help greatly appreciated.

    T.

    Srini

    Try using:

    RECORDS DELIMITED BY newline

    Instead of:

    RECORDS DELIMITED BY '\n'


    on your table to create, in addition to just help to_number or to_number return with ' NLS_NUMERIC_CHARACTERS = ".," ' in your query, in the period before the comma as decimal separator comes before the grouping separator.

    What is probably happening is that your return to the line of the system data come from different East of your new line on the system that you load in.  You may need to experiment and

    Select dump (consignment_net_value) in the dump_ext;

    to determine what additional invisible characters, such as Chr (10) and Chr (13) can be added at the end of the number that you have to cut, so just using line feed does not work.  This is why it only happens with the numbers at the end of the line.

    Post edited by: BarbaraBoehmer

  • How to change the search engine when you use the functionality of Firefox Home button Search?

    In Firefox itself, I have configured duckduckgo as my default search provider.

    But when I use the host Firefox search button it is always defined on google and I don't see any possibility to change that?

    I love the Firefox Home button Search (or whatever we call it) otherwise, but it's annoying that it does not use the default Firefox.

    I use the Google Launcher now.

    Hi mrt181, it is planned to use the same search engine as in firefox - however, there is a bug at the moment, so it does not apply in all situations.
    usually, it will be enough to change the default engine in firefox back once to work around the problem in the search widget and get the same as set in the browser search provider.

  • How to add the warning message when you use the function 'print' in Adobe LiveCycle Designer

    I'm trying to make the pdf document for my business that requires the addition of a warning message while everyone to use the function 'print' page...

    Does anyone know how to add the warning message about LiveCycle Designer

    Also my supervisor mentioned something using "nag" If that sounds at all

    Not in the XML code, in the case of script of pre-publication of the "print" key. If you don't have the script editor to the top on your version of designer, you can press ctrl + shift + F5 to bring it.

  • Writing bug when you use the function to import .txt (Acrobat Pro DC)

    I'm trying to redact large sections of a document using the function import .txt to select phrases or expressions. It works great, except if there is - or '. In this case, Acrobat bad reads the text file, per the screenshot below. If I copy the sentence from the PDF file and add it in the same manual, it seems in good condition. If I paste the Clipboard even in a txt and then import the text, he result is bad reading and so cannot find the phrase in the document.

    Screen Shot 2016-04-17 at 9.42.45 PM.jpg

    It seems that the TXT file was done in Word and saved in Unicode format. and used quotation marks. Quotes in general are a big problem as three different characters are used for them and corresponding can be difficult; and 4 hyphen/as of the characters.

  • How to make appear the BCC in email, when you use the function of charms, hand

    I have sent a video about skydrive to friends but could not exercise the BCC field to send emails using the e-mail of charms, share.   Please don't tell me that it went unnoticed.  Thank you.

    Hey scottfactor,

    Unfortunately copy carbon (CC) and blind carbon copy (BCC) not currently being supported by the share to the mail scenario, you can use the Windows Mail application. If you have also installed the application SkyDrive, you can do the following:

    1. Start the Mail application
    2. Compose a new message
    3. Open the App bar
    4. Select attachments
    5. In the upper left corner of the file picker, select files
    6. Scroll and select SkyDrive

    Now you can select the video that you've uploaded to SkyDrive and share with your friends!

    -Chris

  • Muse randomly crashes when you use the function file/image of place. And is slow!

    Hi guys,.

    I use a MacBook Pro retina i7 with 8 GB of ram. I installed version track Adobe muse and I really love the product so far, except that it blocks a lot randomly, when I sometimes use the file from the location or place the image feature. (Command-D) Muse is also slow. I have some running applications, lots of free space etc but Muse stagnates, hang out and crashes a lot.

    Is there a reason known for this? This prevents me to consider buying the program.

    Help, please

    Kind regards

    Emmanuelle

    Please see Re: Muse crashing every time the image file is added

  • Error "Invalid line" when you use the command tableFile - ttImportFromOracle

    Execution of the order and got an error, as shown below:

    c:\oracle>ttImportFromOracle -oraConn myUser/myPassword@myDB -tableFile C:\oracle\table_list.txt
    Error: Invalid Line 'mySchema.myTable2' in file 'C:\oracle\table_list.txt'
    Use '-help' for more information
    
    

    table_list.txt looks to below, except I have 112 tables total in the list, a table by line, as indicated in the help documentation.

    mySchema.myTable

    mySchema.myTable1

    mySchema.myTable2

    I tried to make the file table_list.txt have only the table (without figure) names and the same error occurs.

    Invalid line is always the last table in the file. So if I take off the table she complains, she complains always just whatever the table is the last in the file.

    Can someone tell me what I am doing wrong?

    Thank you

    Matt

    To work around the error, I just used - tables instead.

  • Slow performance when you use the function

    Hi all

    I have a function that returns the name of the product based on a number of identifiers. I create a new table

    Insert into the product
    (
    Name
    )
    Select
    PRODUCT (PRODUCT_ID)
    OF x_table


    It works very well but there are approximately million rows in the table and preformance is incrediably slow. No idea how I could improce performace or if I have to do this another way?

    Thanks in advance


    CREATE OR REPLACE FUNCTION PRODUCT (P_PRODUCT_ID IN VARCHAR2)
    RETURN VARCHAR2
    AS
    L_Name VARCHAR2 (4000);
    BEGIN
    SELECT NAME
    IN l_name
    PRODUCTS
    WHERE PRODUCTID = P_PRODUCT_ID
    OR PRODUCTID = P_PRODUCT_ID1
    PRODUCTID = P_PRODUCT_ID2
    PRODUCTID = P_PRODUCT_ID3
    PRODUCTID = P_PRODUCT_ID4;

    RETURN l_name;
    END;
    /

    It would probably be best...

    Insert into Product
    (
    Name
    )
    Select PRODUCTS.NAME
    FROM x_table
         JOIN PRODUCTS ON (x_table.product_ID IN (P_PRODUCT_ID, P_PRODUCT_ID1, P_PRODUCT_ID2, P_PRODUCT_ID3, P_PRODUCT_ID4))
    
  • ORA-01789 - when you use the operator of TABLE and SEM_MATCH

    Client version: 11.1.0.7 on Windows 7 (32 bit)
    Server version: 11.2.0.3 on Windows 7 (64-bit)

    I am model prototyping a simple RDF, and I'm getting a ' ORA-01789: block has an incorrect number of columns in query results "when you use the SEM_MATCH with the SCOREBOARD operator.

    I can run this:
    select id, a.triple.GET_TRIPLE() from drik.rdf_data a
    and the first line is:
    (<http://www.ihc.com/drik/term#2>, <http://www.w3.org/2000/01/rdf-schema#subClassOf>, <http://www.ihc.com/drik/term#1>)
    Now, I want to use the TABLE like this:
    select
      c
    from 
      table(sem_match('{ <http://www.ihc.com/drik/term#2> <http://www.w3.org/2000/01/rdf-schema#subClassOf> ?c . }', 
            sem_models('Prototype'),
            sem_rulebases('RDFS'),
            sem_aliases(sem_alias('rdfs','http://www.w3.org/2000/01/rdf-schema/')),
            null
            ))
    But this performance gives the ORA-07189. Even try SELECT * gives the same error.

    I expect to get a refund:
    <http://www.ihc.com/drik/term#1>
    How should I approach troubleshooting this?

    Thank you, Steve

    Thanks for posting the script. I was able to reproduce the error locally.

    The problem is the use of the sem_apis.create_rules_index () procedure, which has been deprecated:
    http://docs.Oracle.com/CD/E11882_01/AppDev.112/e25609/sdo_rdf_newfeat.htm#autoId26

    Please use sem_apis.create_entailment () instead, and the error should disappear.
    http://docs.Oracle.com/CD/E11882_01/AppDev.112/e25609/sem_apis_ref.htm#CHEHDGBD

    Thank you
    Matt

  • Strange ORA-01722: invalid number on viewCriteria

    Hello

    I defined in jDev 11.1.1.5 do with viewCriteria and everything works until I have migrate jDev 11.1.1.6. Now, I get this exception run this view

    < Utils > < buildFacesMessage > ADF: addition of the JSF error message: ORA-01722: invalid number

    java.sql.SQLSyntaxErrorException: ORA-01722: invalid number

    After a few experiences, I found that this problem is viewCriteria, which is not so simple. It is used with condition NOT IN subquery.

    (P_P_ID_FK NOT IN (SELECT P_ID of P where NVL (VALID_FROM, CURRENT_DATE) < = CURRENT_DATE))

    I know that DOESN'T look good is not standard in ADF viewCriteria, but SQL work well. So tell me why there at - it SQLSyntaxErrorException!

    When I remove that part or AppModule viewCriteria viewCriteria, then everything works.

    Exception disappear even when I move the condition NOT IN with the main request viewCriteria subquery.

    I tried to rewrite viewCriteria using NOT EXISTS, but there is no possibility of query from same table due to the inability of aliasing table names.

    You have a work around?

    Thank you.

    Problem is resolved declaratively by manual editing of XML view this tutorial Andrejus Baranovskis Blog: implementation of criteria seen in Colombia - British ADF

  • Please help: instruction box - ORA-01722: invalid number error

    Hi all
    I am trying to use the Case statement to recode the status canceled in two groups
    "Reject" If the difference between the date of the first and the last date is less than 29 and
    'Accept' if the difference between the date of the first and the last date is greater than 30

    Here's my data 'test'

    STATUS FIRST_DATE LAST_DATE

    Transfer / / 10/08/2011-10/09/2011
    Mover 10/08/2011-15/09/2011
    Cancel the 16/09/2011 10/08/2011
    Cancel the 10/08/2011 5/09/2011

    Here's the syntax

    Select a.*,
    (CASE WHEN a.STATUS = 'Cancel' CAN (round(a.LAST_DATE-a.FIRST_DATE))
    0 OTHERWISE
    END CAN_DAYS),
    (BOX WHEN "CAN_DAYS" > 29 THEN "reject"
    WHEN "CAN_DAYS" < 30 THEN "accept."
    Reject_Accept END)
    try one

    The first CASE statement works very well and gives me this
    STATUS FIRST_DATE LAST_DATE CAN_DAYS

    Transfer 0 10/08/2011-10/09/2011
    Mover 0 10/08/2011-15/09/2011
    Cancel the 37 16/09/2011 10/08/2011
    Cancel the 26/10/08/2011 5/09/2011

    but the LATTER product ORA-01722: invalid number error. It's something to do with the type of data CAN_DAYS, Oracle does not see in the Numeric form I think.
    I want to see result
    STATUS FIRST_DATE LAST_DATE CAN_DAYS Reject_Accept

    Transfer 0 10/08/2011-10/09/2011
    Mover 0 10/08/2011-15/09/2011
    Accept to cancel 37 10/08/2011-16/09/2011
    Refuse to cancel the 26/10/08/2011 5/09/2011

    Could someone please help me fix the syntax?
    Thank you in advance,

    Hello

    The error is due to the fact that you are trying to compare "CAN_DAYS", which cannot be regarded as a number, a number.
    You can try this option for your results:

    select A.STATUS, A.FIRST_DATE, A.LAST_DATE,case
                                                when a.status ='Cancel' then round(a.last_date - a.first_date)
                                                else 0
                                                end as can_days,
                                                case
                                                when (a.status ='Cancel'  and round(a.last_date - a.first_date) > 29) then 'Reject'
                                                when (a.status ='Cancel'  and round(a.last_date - a.first_date)< 30) then 'Accept'
                                                else null
                                                end as Accept_Reject
    from test a 
    

Maybe you are looking for