ORA-1830: date format picture ends before converting entire input string RRS feed

  • Question

  • User-39953368 posted

    I am trying to create a new OraceTimeStampTZ object and I get the above error and can't see why. When I examine the string passed to "new", it looks OK:

    OracleTimeStampTZ dtzTimeIn = new OracleTimeStampTZ(sDTZ);

    sDTZ = "15-APR-13 AM US/EASTERN"

    Monday, April 22, 2013 10:42 AM


  • User269602965 posted

    Did you initialize the layout?

     // Set the nls parameters for the current thread    
    OracleGlobalization info = OracleGlobalization.GetClientInfo();
    info.TimeZone = "US/Eastern";     
    info.TimeStampFormat = "DD-MON-YYYY HH:MI:SS.FF AM";     
    info.TimeStampTZFormat = "DD-MON-YYYY HH:MI:SS.FF AM TZR";     
    // Create an OracleTimeStampTZ in US/Eastern time zone     
    OracleTimeStampTZ tstz1=new OracleTimeStampTZ("11-NOV-1999 11:02:33.444 AM US/Eastern"); 

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, April 24, 2013 10:27 PM