Weird DATE

Hello there ! I`m using Oracle db.
The date returned in Oracle DB itself is in such format :-23-MAR-99
The date returned thru JDBC to my browser has an additional .0 (appended at the back ) .
How can I remove this ? Can someone help with a code to split it, or any other intelligent solutions ?
QUERY
innerRset = statement.executeQuery("select MACHINE_TEST_END_TIME from TRDB_MACHINE where MACHINE_TEST_END_TIME = TO_DATE('" + outerRset.getString(2) +"', 'yyyy-mm-dd HH24:mi:ss')");
OUPUT ON CONSOLE
2000-09-08 18:15:04.0
CANNOT BECOZ ORA-01830: date format picture ends before converting entire input
string

Hi ! I tried using the Tokenizer class but I`m not sure how to complete this code .
Can you GURU`s please help ???
innerRset = statement.executeQuery("select MACHINE_TEST_END_TIME from TRDB_MACHINE where MACHINE_TEST_END_TIME = TO_DATE('" + outerRset.getString(2) +"', 'yyyy-mm-dd HH24:mi:ss')");
/* Split Rset */
StringTokenizer st = new StringTokenizer(strFdate," ");
String [] strArr = new String[3];
for(int i=0;i<3;i++)
     strArr = st.nextToken();
return strArr;
String strFdate=strArr[0];
String strSdate=strArr[1];
String strTdate=strArr[2];

Similar Messages

  • Weird data obtained when running Task: AD Group Lookup Recon

    Hi,
    Im running the scheduled task named: AD Group Lookup Recon
    It works. and populates the lookup named Lookup.ADReconciliation.GroupLookup
    but when lookin in the design console, the Code Key and the Decode values have weird data ie:
    code key: 2~CN=TelnetClients,CN=Users,DC=adtest,DC=com     
    Decode: ADITResource~CN=TelnetClients,CN=Users,DC=adtest,DC=com
    in the code key there is an extra *2~*
    in the Decode is an extra ADITResource~
    I may think that it is some kind of coding for connector commands used in provision tasks, when I'm trying to provision an OIM user to Active Directory (in the Organization Lookup field) i get this data
    this is just one line:
    Value: 2~CN={6AC1786C-016F-11D2-945F-00C04fB984F9},CN=Policies,CN=System,DC=adtest,DC=com      
    Description: ADITResource~CN={6AC1786C-016F-11D2-945F-00C04fB984F9},CN=Policies,CN=System,DC=adtest,DC=com
    Any Ideas?
    Thank You.

    yes you are right, code key and decode key is because of the coding in the connector to distinguish lookup values coming from multiple IT resources.
    If you want to get rid of this [IT Resource~] you will have to modify the connector.
    One more thing looks like the base dn you have specified for lookup reconciliation is DC=adtest,DC=com with generic filter thats why you are getting entries like 2~CN={6AC1786C-016F-11D2-945F-00C04fB984F9},CN=Policies,CN=System,DC=adtest,DC=com which may not be a group you want
    Hope this helps,
    Sagar

  • Why does "last" give me weird dates?

    when I used the "last" command yesterday, I got a list of weird dates. An excerpt is below.
    First I thought these were in the future, but then looking at the weekdays I noticed that in fact they date back to 2009.
    Any ideas what could cause this?
    Thanks
    Last login: Thu Jul 23 23:43:25 on console
    preon:~ schnapp$ last
    schnapp  console                   Wed Aug 26 23:51   still logged in
    reboot    ~                         Wed Aug 26 23:50
    shutdown  ~                         Wed Aug 26 23:35
    schnapp  console                   Wed Aug 26 21:41 - 23:35  (01:54)
    reboot    ~                         Wed Aug 26 21:40
    schnapp  console                   Wed May 27 21:49 - 22:34  (00:45)
    reboot    ~                         Wed May 27 21:47
    shutdown  ~                         Wed May 27 01:46
    schnapp  console                   Tue May 26 22:53 - 01:46  (02:52)
    reboot    ~                         Tue May 26 21:35
    shutdown  ~                         Tue May 26 01:24
    wtmp begins Tue May 26 01:24

    I don't know - never used 'last' before but I get:
    $ last
    neville   ttys000                   Sun Jun 24 16:08   still logged in
    neville   console                   Sun Jun 24 11:27   still logged in
    reboot    ~                         Sun Jun 24 11:26
    shutdown  ~                         Sat Jun 23 23:25
    neville   ttys000                   Sat Jun 23 21:02 - 21:03  (00:00)
    neville   ttys000                   Sat Jun 23 14:44 - 15:34  (00:50)
    neville   console                   Sat Jun 23 11:39 - 23:25  (11:45)
    reboot    ~                         Sat Jun 23 11:39
    I am not sure if 'last' is affected by the failure to run maintenance tasks as intended but it can do no harm to correct the usual maintenance quirk as explained on my page at: http://links.zero.eu.org/os-x/period/
    Good luck.

  • Weird "date change" glitch...?

    I had a bunch of pictures with the wrong dates, but only off by a couple of days... so, thinking I was smart I tried to "merge" the events. Obviously, that didn't change the dates.
    So, in the new events I tried to select all the pics and changed the date. Only, it didn't work. The change actually PUSHED or PULLED the dates by a set number of days, based (I guess) in the first photo in the event) so only a couple of the pictures ended up with the correct date. Very weird.
    I've used both "change date and time" and "batch change"... but still the same result.
    This makes no sense... and is really frustrating. Any ideas?
    tia,
    e

    So, in the new events I tried to select all the pics and changed the date. Only, it didn't work.
    Of course it worked - you said to change the date on all the photos and it did
    What you want to do is select the photos with the incorrect dates and (assuming that they all or off by the same amount) use the adjust date and time command in the iPhoto Photo menu - it will modify the dates for the selected photos by the delta between the first photo's date and time and the new one you select.
    Batch change either sets all selected photos to the exact date and time or sets the first one to the selected date and time and then adds a fixed increment to that for each successive photo depending on the option you choose
    LN

  • Weird Date Problem in SQL Query

    Dear Members,
    Iam using the following query:
    SQL>select api.attribute2 PO_NO,
    substr(api.attribute4, 10, 5) REL_NO,
    api.invoice_num,
    SUM(T.ACCOUNTED_DR) DR,
    SUM(T.ACCOUNTED_CR) CR
    from gl.gl_je_lines t, GL_CODE_COMBINATIONS GCC, ap_invoices_all api
    WHERE T.SET_OF_BOOKS_ID IN (7)
    AND TO_DATE(TO_DATE(t.PERIOD_NAME, 'MON-YY'), 'DD-MON-YY') =
    TO_DATE(TO_DATE('&P_PERIOD_FROM', 'MON-YY'), 'DD-MON-YY')
    AND TO_DATE(TO_DATE(t.PERIOD_NAME, 'MON-YY'), 'DD-MON-YY') <=
    TO_DATE(TO_DATE('&P_PERIOD_TO', 'MON-YY'), 'DD-MON-YY')
    AND T.CODE_COMBINATION_ID = GCC.CODE_COMBINATION_ID
    AND GCC.SEGMENT5 = '&P_ACCOUNT'
    and t.reference_2 = api.invoice_id
    GROUP BY api.attribute2, substr(api.attribute4, 10, 5), api.invoice_num
    order by api.attribute2, substr(api.attribute4, 10, 5), api.invoice_num
    In the above query iam giving two types of parameters:
    Type1:
    Account:=17400650
    P_PERIOD_FROM:='JAN-07'
    P_PERIOD_to:='DEC-07'
    For the above type of parameters the query is running fine and giving desired results.
    Type2:
    Account:=36210040
    P_PERIOD_FROM:='JAN-07'
    P_PERIOD_to:='DEC-07'
    For the above type of parameters it is giving me the error: ora-01843 not a valid month_
    Can any one please tell me what is the reason for this weird problem.
    Your inputs will be of great help to me.
    Thanks in advance.
    Best Regards,
    Arun Reddy

    Please review Note:338832.1
    How to debug ORA-01843: not a valid month, ORA-01821: date format not recognized, ORA-1801

  • Weird data reached in text files

    Hi all,
    I am seeking for some opinions about a problem I encouter in an
    experiment. I would very much appreciate your thoughts. There are the
    well-known programs in the Example Finder:
    1. Write binary file - which takes inputs from a sinus wave generator.
    2. Cont Acq& Graph Voltage - which in my case takes the input from a channel of a DAQ NI 6255
    So with these two I get two binary files from which I want to extract the information by means of a conversion to a text file.
    When I convert the bin files to text, I use the same VI program (which
    I attached) to do that. The conversion for the 1st VI looks as
    expected, but for the 2nd is really weird!.
    For the data in the 1st text file see textFile.txt file attached.(One would get the same result if it runs the VI):
    For the data in the second text file, see textmydaq2.txt file
    attached.(The data should normally record values ranging from 4.XX to
    8.XX):
    Should I constraint the data with some data format to avoid such strange values? Or is it something else I should do?
    Thank you very much for any kind of support.
    Dana
    Attachments:
    myRead Binary File8.vi ‏28 KB

    I can see there is a problem for the server to upload maybe other files(like txt files) different than VIs.
    As I cannot attach the txt files, I will provide you with samples:
    Here is a sample for the 1st text file(One would get the same result if it runs the VI):
    0.00    376.74    752.00    1124.29    1492.14    1854.10    2208.75    2554.68    2890.52    3214.96    3526.71    3824.54    4107.28    4373.81    4623.08    4854.10    5065.97    5257.84    5428.96    5578.66    5706.34    5811.50    5893.72    5952.69    5988.16    6000.00    5988.16  
    Here is the result in the second text file(The data should normally record values ranging from 4.XX to 8.XX):
    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    73333305348950320900000000000000000000000000000000000000000000000000000000000000000000000000.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    633318785695744.00    0.00    0.00    0.00    9663677760.25    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00    0.00  
    Best!
    Dana

  • Datagrid itemrenderer causing weird data scrolling behaviour

    I have a datagrid bound to an array for editing and viewing.
    I have a listener for an ItemEditEnd event which looks at the
    input, chomps any whitespace and writes back to the itemrenderer
    the updated string. But... if I then reload the data into the
    dataprovider the datagrid doesn't render it properly because it
    retains a memory of the previously edited value and re-displays it
    on the line below where it was. So repeatedly reloading the data
    causes edited values to magically scroll themselves downwards in
    the datagrid!
    I gues this is something to do with itemrenderers being
    recycled, but I have no idea how to code around it. Any help would
    be gratefully received. A simplified mock up of the problem is
    attached.
    Many thanks in advance,
    Steve

    Nothing new in that article, maybe as the series
    progresses...
    I have a found a hack around this but it's not the way I want
    to do it. If I add the itemeditend event listener with a very low
    priority (-100) so it gets executed after flex has already updated
    the datagrid I can interact directly with the data, instead of the
    itemeditor/renderer before the data is updated. This means I can't
    do a preventUpdate() and force the user to correct the input so is
    not ideal, but it works in this limited application.
    I did find this:
    http://livedocs.adobe.com/flex/3/html/help.html?content=celleditor_8.html
    which has exactly the same case of needing to modify data sent back
    from an itemeditor. It pokes the modified data back to
    TextInput(myGrid.itemEditorInstance).text which is the same object
    as my (event.itemRenderer as TextInput).text. Doesn't work.
    I attach my code for anyone else struggling with this. If
    anyone has a better solution I'd love to see it.
    Steve

  • Very weird date issue.

    I have a client that is using CFMX7 Enterprise and an Oracle database. One of the database fields we're pulling in is a date. If the date/time is 04/04/2010 02:xx (2am range), coldfusion is automatically adding an hour to it and making it 03:xx.  I changed the time in the field to 1am and 3am and it worked fine with both those numbers and I also left the time at 2am and changed the date to 04/05/2010 and the time remained correct.
    Is there some daylight savings time issue from CF7?  Anybody have a work around, besides putting in a catch for this specific date and time?

    With a version of ColdFusion as old as CF7 you have to be aware that the daylight saving rules in the United States changed since that version was released.  If the JVM has not been updated to understand the new rules, then that version is going to be operating on the previous set of day light savings rules.
    http://kb2.adobe.com/cps/447/d2ab4470.html

  • LS HTML Client, weird Date issue

    Here's a strange one... In an application that I've just made, upon saving a record, LS seems to automatically modify the date of the record by exactly minus 1 day (say from 9/17 to 9/16). Now, there is some criteria for this to happen:
    1. An value must be modified that has not previously been modified in the record.  An example would be "Temperature", this is a required INT.  If I start a record and leave it at 0, Save, then go back into the record and add a value and
    Save, the date on the record is automatically changed back a day.
    Here's the kicker... the date change is only visual, the date value in the DB has not changed.  As soon as I hit F5 on my browser the date is correctly updated back to what was originally saved.
    The app does not have any events happening in the Updated/Updating/Inserting/Inserted methods.  The date is automatically added in the _Created event for the DB Entity.
    (this happens in both debug mode and when published to an Azure website).

    Hi!
    I've been having the exact same problem and unfortunately the workaround proposed above did not fix the issue or this workaround (from http://stackoverflow.com/questions/28483086/datetime-textbox-in-lightswitch-html-increments-one-hour-on-save/28491688#28491688)
    // Open msls-2.5.2.js
    // Locate this section of code:
    entitySet._loadedEntities[entityData.__metadata.uri] = entity;
    } else if (entityState === _EntityState.modified) {
    originalEntityData = entityData.__original;
    $.each(entityDetails.properties.all(), function (j, property) {
    // You need to add:
    convertDatesToLocal(changeResponse.data);
    // Example:
    entitySet._loadedEntities[entityData.__metadata.uri] = entity;
    } else if (entityState === _EntityState.modified) {
    convertDatesToLocal(changeResponse.data);
    originalEntityData = entityData.__original;
    $.each(entityDetails.properties.all(), function (j, property) {
    // Hope this helps.
    One fortunate thing is that the change is only 'visual'.. so I'm okay with it for now although I would love to have a fix for this until I wait for VS 2015.
    Thanks,
    Mani

  • Weird data paging issue

    I just upgraded to flash builder 4 from the beta version. I imported my project
    and now my datagrid is acting funny. I have data paging enabled. The one thing I
    tweaked was on this part:
    http://sujitreddyg.files.wordpress.com/2009/06/165.png
    Instead of setting the "Count operation" to "count()", I've set it to "None". I
    have a large amount of data and setting it to "None" makes the thumb larger so
    that users can use it. It also disables the ability to "jump" pages (which uses
    a lot of memory if you have a datagrid).
    Everything worked fine in the beta version of flash builder but in the non-beta
    version I came across a problem: I can initially page (with my mouse wheel) a
    few times and then it just stops for no reason. I try to keep scrolling w/ the
    mouse wheel and nothing. However, if I click on a row, then it will get another
    page. I have to continue to click on the rows in order to get another page.
    Annoying, to say the least.
    Anyone notice this? I didn't change anything so figured it must be the updated
    version. (You can see for yourself w/ your own project...just change the Count
    operation to "none" and then try to page through the datagrid).....any
    suggestions?

    Can you please file a bug with a simple test case @ http://bugs.adobe.com/flex and we can take a look.
    Thanks,
    Peter

  • Weird Date and Time warning?

    Hi, I keep getting a prompt/warning window (?) that pops up at start up that says, "Your computer's clock is set to a date before March 21, 2001. This may cause some applications to behave erratically. Please use Date and Time preferences panel to set clock manually. For more info see Help..."
    The date and time were wrong the first time, like year 2000 (can't remember the month and day) and I corrected it. After that, the date and time are correct but that prompt still comes up.
    Is this something viral? How to fix? Thanks.

    LOL!!! Of course the PRAM reset didn't really work--like 3X it didn't work. After basically wasting time with 2 more tech calls to Apple, I'm headed for the store to get the battery replaced. The next call had me fix the Disk Permissions via Disk Utility, why I don't know (they did need to be fixed according to the Utility). I'm really surprised at how little Apple's tech "experts" really know. I'll update on the battery change. Thanks.

  • Weird date of clip in Event Library (2021, not 2007)

    I just imported some footage from my DV video camera. Because there was some blank space at the beginning, and a snippet of previous stuff on the tape I used, it imported as 3 clips. Which is fine, because I just deleted the first and last clips. This is not my problem, but I mention it in the hopes that it might give you a clue to the solution to my REAL problem, which is...
    In the Event Library (lower left-hand panel), instead of being listed with my other 2007 videos, it's listed as an item in the year 2021! Stranger still, when I click on the clip itself (either in the lower right-hand panel with the thumbnails, or its listing under the 2021 year in the lower left-hand panel), its date is listed correctly (as September 22, 2007) in the horizontal gray bar running across the top of the thumbnails. Hmmm! Somehow, iMovie has decided that this event took place in 2021, even though this particular clip in that event comes from 2007.
    The date is set correctly in my DV camera. And I have imported other clips from this DV camera and they all showed up in the 2007 list. My MacBook Pro's date and time are set correctly.
    I've tried to move the clip to the 2007 year, but it insists I merge it with another clip. How can I tell iMovie to change the date it thinks this thing is from? iMovie is supposed to be strong in finding video on my hard drive and making it organized and available to me in the Event Library... but how can it do this if it insists that video I shot and imported today was actually done 14 years in the future???
    Message was edited by: James Weinrich1

    I don't know what caused the problem, but here's how I solved it. Thanks, everyone, for your help.
    I searched for 2021 using Sherlock. I found two files with the date in their names; one was the .dv clip itself, the other was the file for the thumbnails. I changed their names from 2021 to 2007.
    I also found the text file entitled "iMovie Data" which was in the folder named with the movie clip's name. The 2021 date was in that file once and was presumably the link to the video files whose name I just changed. I changed that date from 2021 to 2007 and saved it.
    I relaunched iMovie and the clip was in the 2007 area, where it should be.
    I wasn't in the mood to experiment, so I don't know if it was necessary to change all 3 things. It probably was, for consistency at least.
    Darn! I changed all those dates without checking what the lottery numbers were gonna be in 2021!! I guess I can't retire then after all...

  • ICal date bug...

    My ical has started to show some weird dates..
    an appt i have on the 8/5/06 shows like this
    from 08G05G06 at 215pm
    to 08G05G06 at 215pm
    This is now applicable on every apptmoint since i started using iCal, circa 2003
    Anyone got any suggestions - I am using an Intel MacBook Pro 2.16Ghz.
    Thanks
    Jeloz

    jeloz,
    Next, I would recommend that you check out Font Management in Mac OS X Tiger and Panther, by Kurt Lang. Pay particular attention to this paragraph: For garbled text, the most common cause is corrupt font caches. These can easily be cleared from the system with Font Finagler. Download and run the application. First click the "Inspect Font Cache Files" button, then the "Clean Font Cache Files" button. You must then restart your Mac. Other utilities that can clear your font caches are Cocktail and OnyX. These last two are powerful utilities which can do far more than just cleaning font caches. If you are not familiar with these applications, then I would caution you in their use as you could cause your Mac to become non functional, requiring a reinstall of the OS. Font Finagler is the safer choice as it performs only the one function.;~)

  • How do i restore to earlier date without using time machine

    I logged in to my Mac a couple of days ago and it said it was restore to some weird date. It does not appear anything changed, but now when I am trying to download a Sims game (don't judge me lol) it won't download saying there is no Internet connection even though there is. Is there anyone to restore the system to a date that I know it was working properly without using time machine? I never bought an external drive so my time machine is not set up. Thanks.

    If you don't keep a backup, you can't restore your machine to any state except the state in which you received it, brand new, with none of your own stuff on it. That makes a pretty convincing argument for backing up, doesn't it?

  • Contents of iPhoto 6 data files

    I'm trying to get a comprehensive understanding of the data structures of iPhoto 6. For the life of me I can't find any previous postings that explain all the files. In particular, I'd like to understand (high level) the contents of the following files:
    AlbumData.xml
    Dir.data
    iPhoto.ipspot
    iPhotoLock.data
    Library.data
    Library.iPhoto
    Library6.iPhoto
    Thumb32Segment.data
    Thumb64Segment.data
    ThumbJPGSegment.data
    I know that the Thumb*.data files have thumbnails in them, but don't know what the difference is between the three files. I'm assuming the iPhotoLock.data is a semaphore to lock out multiple accesses to these data files. And I have divined that AlbumData.xml contains the roll and album information for every photo, in addition to some other good stuff.
    What I understand the least are the three Library*.iPhoto files. In particular Library6.iPhoto is big (~100Mb for 6000 pics)--what's in there?!
    Thanks!
    iMac   Mac OS X (10.4.7)  
    iMac   Mac OS X (10.4.7)  

    So I want to know what they are so I can experiment with doing some of my photo management in iPhoto, and some directly through the file system. And I want to try to do things like delete Library6.iphoto but I don't want to spend an hour re-entering the dates for all of my rolls when iPhoto recreates the rolls with the weird dates that it grabs.<<<</div>
    That's what I had expected. Don't tamper with the iPhoto library unless you enjoy bleeding ulcers. The following is pasted from the iPhoto "Help" screens:
    IMPORTANT: If you move, delete, rename, or otherwise touch files or folders within this folder, you may be unable to see your pictures in the iPhoto application.
    What is it that you want to do that you're unable to do from INSIDE iPhoto?

Maybe you are looking for

  • Error in File to Mail Scenario

    Hi All,   I am getting the following errror at adapter level in File to Mail Scenario in XI production Mail: error occured: com.sap.aii.af.ra.ms.api.RecoverableException: java.io.IOException: server not responding OK to RCPT TO; 554 Relay access deni

  • G3 B&W 450 worked great then... NO CHIME! nada. After Zif CPU & RAM upgrade

    I never should have added ram and a Zif 1ghz G3 at the same time... can't trouble shoot as easily now. I've done my personal obligatory 2 day search for answers before posting a question.... I've done all the yada yadas with CUDA and battery.... I've

  • Want to reduce execution time

    Hi all, I am executing an insert query with about 2 million of records. I is taking around 4 hrs to execute. Sometime it is giving error of (ORA-01652: unable to extend temp segment by string in tablespace). I cannot increase temp. tablespace. Thanks

  • Sales order cancellation with points comsuption

    issue is the following : As a consumer, i create a sales order in WCEM with points consumption : i "give" 8 points to get my stuff -> fine. Then, i decide to cancel this order, still in WCEM, as delivery is late .. -> i don't have any member activity

  • Why cannot add friends on game center

    Hi! I tired adding friends on game center but it doesnt work. My friends cannot add me as well. This happens for all of my friends. Anyway to resolve this? Have tried both ways in adding email and ID but cannot work. HELP!!!