Java Time conversion

Hi
I know this must a simple thing to do in Java but I can't seem to find it.
I need to convert UTC time in millisec into GMT regular time. i.e.
1155000000000 should be converted to Tue Aug 8 01:20:00:000 GMT 2006
Thnx

Crossposted and answered:
http://forum.java.sun.com/thread.jspa?threadID=759645&messageID=4337407#4337407
Don't waste your time on this.

Similar Messages

  • Can I have a Face Time conversation between two Apple devices using the same Apple ID?

    Can I have a Face Time conversation between two Apple devices using the same Apple ID?

    Yes, you can, but the two devices can't have the same e mail address associated with both.  Each, device needs its own unique e mail ADR.  In your case, the iPod can call your iPhone if you use the phone number, but the iPhone can not call your iPod because it must use the e mail address, and if the email address is the same on both, the iPhone will think it's calling itself, so the call will not go through.

  • Error while loading : Time conversion from 0CALDAY to 0FISCPER

    Hi ,
           I get the following error when loading to an ODs .
    My 0FISCPER is mapped to one of the date fields from the extractor (Document date) and also Have 0FISCVARNT as part of data fields  .
    " Time conversion from 0CALDAY to 0FISCPER (fiscal year ) failed with value 20060405 " .
    thanks .

    Hello CG
    Please refere this forum
    Time conversion problem
    Thanks
    Chandran

  • Date/time conversion from UTC to CET

    Hello,
    Jjust a little question to our SAP BI community!
    Is there a BI function/ggod way that converts a (datetime) string DDMMYYYYHH:MM:SS  in UTC time zone into a string DDMMYYYYHH:MM:SS in  CET timezone ?
    We receive this string in input in a flat file and need it to convert from UTC to CET.
    Or do you know any way to convert a date/time from IUTC to CET, eveen using an ABAP function?
    Thanks a lot,
    Matthieu

    Hi,
    Check this thread for time conversion from UTC to Local time
    [ABAP statement for converting UTC date/ time to local date/time],
    Regards,
    Daya Sagar

  • Automatic time conversion is not possible

    Hi Friends,
    I have a problem in Transformation Level when i am mapping "automatic time conversion is not possible for source field FISCPER to 0FISCYEAR,FISCPER3".can any one help me in this issue.
    Thanks
    Narasimha

    Yes if it was date filed then it would have been possible.If you are trying to derive the fiscal year between datasource and cube then you can get it with the help of simple filed level routine.
    Map your fiscper field from source to fiscal year--Rule type Routine.
    RESULT = SOURCE_FIELDS-(Technical name of source field)+0(4).
    For Posting period
    Map your fiscper field from source to fiscper3 year--Rule type Routine.
    RESULT = SOURCE_FIELDS-(Technical name of source field)+4(3).
    This will give you the required output.
    Regards,
    AL

  • Java Timer problem

    hi,
    i am finding some problem using java timer.
    I have a server program that regularly needs to save its data. i want to do it using java Timer.
    i got the following sample code as an example. it works perfectly but how can i send new data each time to save?
    import java.util.Timer;
    import java.util.TimerTask;
    import Core.General;
    public class test_timer {
    public static void main(final String args[]) {
    final Timer timer = new Timer();
    timer.scheduleAtFixedRate(new ttask(), 3000, 3000);
    class ttask extends TimerTask
    public void run() {
    System.out.println("hello ");
    As an example i would like to send current time to the timer task and print it. how is it possible?
    regards
    tom

    For the current time you can just go ahead and do the following call:
    System.currentTimeMillis();
    This will get you the current time in milleseconds.
    When timer is called, get the crrent time and print it.
    Hope this helps.
    hi,
    i am finding some problem using java timer.
    I have a server program that regularly needs to save
    its data. i want to do it using java Timer.
    i got the following sample code as an example. it
    works perfectly but how can i send new data each time
    to save?
    import java.util.Timer;
    import java.util.TimerTask;
    import Core.General;
    public class test_timer {
    public static void main(final String args[]) {
    final Timer timer = new Timer();
    timer.scheduleAtFixedRate(new ttask(), 3000,
    000, 3000);
    class ttask extends TimerTask
    public void run() {
    System.out.println("hello ");
    As an example i would like to send current time to the
    timer task and print it. how is it possible?
    regards
    tom

  • How do I export a Final Cut Express 4 movie using quick time conversion without stretching the image?

    I have created a movie in Final Cut Express 4 using videos and still photos of various aspect ratios and resolutions.  Some of the photos are verticals.  When I try to use File>Export>Using Quick Time Conversion, my images end up being stretched horizontally when the video is finally processed.  I have tried preserving the aspect ratio but the video still ends up stretched horizontally.  What should my settings be in Quick time conversion?  I just want to make a video for YouTube.
    Thanks.  -Bob

    If you shoot in one of the following modes you should be able to Log & Transfer directly into FCE:
    HD:  1920x1080/60i (FX or FH mode)
    HD:  1440x1080/60i (HQ or LP mode)
    SD:  720x480/60i
    1080/60p (PS mode) seems to be the default mode in your camcorder.  FCE only supports progressive video in 720p50 or 720p60.   That's probably why you have had to import via iMovie.
    It would be better to upgrade to Final Cut Pro X, the version currently supported.  FCE was discontinued over 18 months ago and is not supported on Lion or Mountain Lion.

  • Urgent : FLTP  to time conversion

    I have used the function module as C14W_NUMBER_CHAR_CONVERSION for time conversion.
    But it produces the output as follows.
    E_STRING                        86,400.000000000
    E_FLOAT                         8.6400000000000000E+04
    E_DEC                           86,400.0000
    E_DECIMALS                      15
    Here which one will have to be converted as time output.
    Regards.
    Sankar.

    I think the o/p is given in seconds ... 1 Day : 86400secs
    Use this
    E_DEC 86,400.0000

  • Record 1 :Time conversion from 0CALDAY to 0FISCPER (fiscal year A1 ) failed

    Get red error when loading Delta data and the red error is:
    Record 1 :Time conversion from 0CALDAY to 0FISCPER (fiscal year A1 ) failed with value 20060426
    We went to RSA1 -> Source Systems page, right click on the source system, choose Transfer Global Settings, check "Fiscal year variants" and check "Rebuild tables" and then run it twice, but still not helpful that we always get the above red error!
    Any idea?
    Thanks

    hi Anurag,
    You are right that run OB29 on BW, find there is no any period entry for variant A1.  Since all the variant should come from R3 by run "Global Transfer Settings" on the source system, I run OB29 on R3 and find the same thing that there is no any period entry for fiscal year variant A1.  I will go ahead to ask R3 people to correct it on R3, then conduct the "Global Transfer Settings".
    Thanks

  • Time conversion from u0085.Any help on this error in the PSA?

    Hi,
    In IDES, I chose a random infosource to test init and delta loads; in the process I created an infopackage for the load. During the load, Monitor displayed showed failure (Red); The details of the message in PSA is:
    “Time conversion from 0Calday to 0FISCPER (discal year) failed with value 19911021 “
    Any guide on how to fix this problem?
    Thanks

    hi Amanda,
    0fiscper has compound infoobject 0fiscvarnt (you can check RSD1 tab 'compound').
    when uploading data, conversion will failed if 0fiscvarnt is blank/initial or the date format/value is incorret, your date from 0calday seems correct so 0fiscvarnt blank
    seems it's your case, try to check in your transfer rules and mapped 0fiscvarnt infoobject, you can fill it with constant value, choose option 'constant' and fill with K4, you can only fill with values that exist in table T009T.
    you can transfer these values from r/3 via rsa1->source system->transfer global settings, mark 'fiscal year' something and option 'update table' and execute.
    hope this helps.

  • Java 8: Pb with new java.time api

    Hello,
    I'm trying to use the new java.time api that comes with Java 8 (I already know joda-time).
    I'm using the latest build B124.
    I've a String "01/08/2012_00:00:01", I know that the time ref. is UTC, and I want to convert it to an 'Instant';
    I tried:
    DateTimeFormatter FORMAT_DT = DateTimeFormatter.ofPattern("dd/MM/yyyy_HH:mm:ss").withZone(ZoneOffset.UTC);
    Instant instant = Instant.from(FORMAT_DT.parse("01/08/2012_00:00:01"));
    But it fails with following error:
    java.time.DateTimeException: Unable to obtain Instant from TemporalAccessor: {},ISO resolved to 2012-08-01T00:00:01 of type java.time.format.Parsed
         at java.time.Instant.from(Unknown Source)
    I don't understand what's wrong with my code, and I can't figure out how I should proceed to convert the String to an Instant ...
    Any suggestion welcome,
    Best regards,
    Bernard.

    Originally you stated this:
    I don't understand what's wrong with my code,
    So naturally we focused on how to "understand what's wrong' with your code.
    You will never learn to troubleshoot problems if you just throw your hands up in the air and ask for help just because a complex series of steps doesn't complete successfully. 
    Break the process into its individual steps and check the results of each step to identify which step is FIRST producing an error.
    When a complex or multi-step process has an error you start checking the individual steps of the process to see how far it gets successfully.
    I would expect that converting a String to an Instant should be a basic/simple need, so it should be possible to do it in two lines of code; for the time being, the only way I found is to use a LocalDateTime intermediate variable, which seems quite verbose, and I'm wondering if someone knows a better way to do it, and would be willing to share it here.
    Just a technical distinction: your latest example using a LocalDateTime intermediate variable CAN be done in one line of code by just using dot-notation to avoid creating an explicit intermediate variable. But that variable will still be created implicitly behind the scenes.
    Converting a String to an Instant might be considered a basic/simple need but the set of functionality related to dealing with times, dates, calendars, etc is extremely complex. It makes much more sense to develop the requisite functionality in modules.
    Especially when introducing new functionality such as the 'Instant' class are related package elements introduced in 1.8. That functionality builds on what came before and parsers already existing that know how to deal with all of the possible String variants and formatting options and so on.
    Since that work CAN BE done on-the-fly using dot notation and anonymous implicit intermediate classes there isn't much need to reinvent that functionality in the new classes. If certain uses become standard new methods can always be added (e.g. to the Instant class) that will 'appear' to do things in one step.
    And, being an early adopter release, you can always file a 'bug' or enhancement request from the 1.8 download page. That page has links for 'Report Bugs' and 'Feedback forum' that you can use.
    In this current forum no one can give you an 'official' answer as to why something was implemented a particular way and/or whether that implementation is a 'bug' or was designed to work that way. Only Oracle can do that.

  • Time conversion ZVAR_UNIT with FLTP InfoObject gives an error

    Hello,
    Situation:
    ZVGW03X is "a copy" of AFVV.VGW03 but with FLTP instead of QUAN data type:
    It has to be FLTP, because we do some divisions and multiplications with the InfoObject. When doing the same calculations with Data Type QUAN we get results that are slightly wrong (because of omitted data for QUAN values (QUAN saves only 2 or 3 digits behind the comma, FLTP has many moe digits behind the comma)).
    So, we have the FLTP values in the cube and we can use them in the report and also the UoM (MIN or H) is displayed correctly in the report.
    The problem: Unit Conversion
    tcode RSUOM -> we created the Quantity Conversion Type Z_MIN_H.
    This works very well for all Time Key Figures that are QUAN.
    But when I use it for the FLTP InfoObjects the report does not even get to the Variable Page:
    Any idea why the TIME conversion does not work with FLTP and how I can fix that?
    br
    Alex

    Hi Alexander,
    The link below might help you:
    CONVERSION OF FLOAT TO DATE IN BI
    Regards,
    Ashvin

  • Using java.time.LocalDate class

    Hello,
    I am using the latest JDK8 build b87 and JDeveloper 11.1.2.1. In the editor, the code insight does not show the java.time.LocalDate class. When I use the LocalDate class, it is highlighted in red. However, I can compile and run the application fine. Other classes in the java.time package, for example, the Clock class is fine. I can use classes from the java.time subpackages fine. How can I fix this issue?
    Thanks
    Kishori

    JDeveloper does not support JDK 8 as indicated by the certification matrix.
    http://www.oracle.com/technetwork/developer-tools/jdev/index-091111.html
    java.time.LocalDate being a new class, code insight does not support the class.

  • When i try to export my videos using quick time conversion FCE exits out on me. why does it do that?

    When i try to export my videos using quick time conversion FCE exits out on me. why does it do that?

    Does it always happen at the same time during the export?
    Can you play through the entire Sequence in FCE without any problems?
    What are your Sequence settings in FCE>
    Have you rendered fully prior to exporting?
    Which export settings did you use?
    -DH

  • Scorecard Time Conversion Issues

    Hi -
    I'm having an issue with getting the right calculation for the latest year (to date) for a monthly metric with the following 3 values.  This is with 3/31/2010 selected for the 'As Of' date in the scorecard, and the metric has the time conversion set to 'Average'.
    Jan 2010- 32,905
    Feb 2010- 32,766
    Mar 2010- 36,940
    I would expect the latest year (to date) for the above values to equal 34,203.67, but it is coming back as 34,251.59 (FISCAL is set to standard calendar year).  Does anyone know why this may be happening?
    Also, when I select 'latest quarter' with different 'As Of' dates within the 1st quarter, the result yields different numbers.  I was expecting the same number to come back since the dates selected are within the same quarter.  Does anyone know why this may be happening?
    Any help would be greatly appreciated.
    Thanks,
    Jason

    Hi Jason,
    Please check the following thread for an explanation on how the latest and latest to date selections work:
    Re: Time Period with Respect to As of Date
    Hope this helps!
    Best regards,
    Ricardo

Maybe you are looking for

  • Oam file in Muse generate error

    After having integrated a ".oam" file  in a Muse and exported the site in Html, the browser returns this error: "MuseJSAssert: Error calling selector function:SecurityError: Failed to read the 'contentDocument' property from 'HTMLIFrameElement': Bloc

  • MacBook Pro has been acting up for a while.

    My MacBook Pro started acting up at the beginning of this year. The first thing I noticed was a clicking noise that came from the top left corner. It wouldn't happen often, but over time it started to happen more frequently. Then, a few months later,

  • NullPointerException after upgrading to Portal 7.0.5 from 7.0.4

    Hi, I just upgraded to Portal 7.0.5 and I am getting a nullPointerException logging in to the portal site. I put in debug statements and found that for 7.0.4, portalManager.getGroupPortalMembership returns an empty list [], while for 7.0.5 it returns

  • ORA-34492: Analytic workspace object cubename _STORED does not exist.

    I am having issues accessing cube data from a user other than where the AW was built. Following is what I have done in User-1: 1. Create two AW's in User-1 : AW-1 and AW-2. 2. Create all objects in these two AW's 3. AW-2 is dynamically attached on at

  • Tiger and os9

    installing Tiger. can i also install OS9. have old games would like to keep.how to install?