Take out time difference from 2 dates....

Hi Guys,
I have two date columns with date datatype in my table.
Office_Time and Employee_Time, date and time is stored in these columns.
I want to get the time difference between to dates and times.
Like if the office_time is 12-MAR-05 09:00:00 and Employee_Time is 12-MAR-05 10:15:00 then the differnce shud be 01:15:00 hours.
How to apply such a formula.. please help!
Imran Baig

Hi,
You can read the next topic :
Re: how to get time diff between to date
Nicolas.

Similar Messages

  • HT4759 Hello .. I've been subscribed for ic;oud for 20$ per year and I found it useless for many reasons: that I can not disconnect my mobile while the uploading process and it takes long time for uploading my data .. Its not a reliable system that's why

    Hello .. I've been subscribed for ic;oud for 20$ per year and I found it useless for many reasons: that I can not disconnect my mobile while the uploading process and it takes long time for uploading my data .. Its not a reliable system that's why I need to deactivate the space service and take my money back .. Thanks

    The "issues" you've raised are nothing to do with the iCloud service.
    No service that uploads data allows you to disconnect the device you are uploading from while uploading data. Doing so would prevent the upload from completing. It is a basic requirement for any uploading service that you remain connected to it for uploading to be possible.
    The time it takes to upload data to iCloud is entirely dependent on how fast your Internet connection is, and how much data you are uploading. Both of these things are completely out of Apple's control. Whichever upload service you use will be affected by the speed of your Internet connection.

  • Take out multiple values from a db and handle them in an applet.

    I have a db with tables. I want to take out several values from them and make them visible in a JFrame (or applet).
    I dont know how to do. I have an app that connects to the db and selects the values and puts the Strings in a Vector. But now then?
    I have looked at examples that retrieve Strings but not vectors, isn't that possible?

    Hi,
    On initialization of your frame you can loop over your vector and display them.
    Now the problem is in what type of component do you want to put your data.
    I can give you an example.
    What you can do is create a String which will contain all the data from
    your vector and set that string to the component.
    Example:
    Vector data;
    String result;
    for(int i=0; i < data.size(); i++) {
    result += (String)data.elementAt(i) + "\n";
    Now you need to put the string into a component which is easy done.
    Let take a textarea component.
    JTextArea txaTest = new JTextArea();
    txtTest.setText(result);
    Now all the data will be shown in the textarea component on your frame.

  • How do I get date and time component from a DATE object?

    Hi All,
    I need to get date and time separately from a DATE object, does
    anyone know what function I should call? GetDate()? GetTime()?
    I need this in a SELECT statement.
    Thanks in advance and looking forward to your early reply.
    Regards.
    Gladywin
    30/11/2001

    Hello,
    See following SQL.
    select to_char(sysdate,'dd/mm/rrrr') today_date,
    to_char(sysdate,'hh24:mi') now_time
    from dual
    Adi

  • My iTouch is being recognized as a digital camera and cant take out my music from it.

    i have an iphone and an ITouch and also a Ipod nano and and i just got a brand new computer cause my old 1 died. i still have music in my ipod iTouch and iPhone. i want to fill my new laptop with music. but since my iTouch and iPhone are both being read as a digital camera i can only take out photos from both. witch right now i dont care about the photos. my iPod nano on the other hand is being read as a storage device meaning i can take out the music out of the nano. i want to make it so i can also take out my misic from my iTouch and iPhone. in need of assistance. tried a bunch of methods but im tired of it. im im going to need professional help.

    - It is normal and expected for the iPod to be seen as a camera
    - What do you mean " when I put it in hard disk mode"?  iPod touches do not have a disk mode.
    - Does the iPod show in iTunes?  If not try:
    iPhone, iPad, or iPod touch: Device not recognized in iTunes for Windows

  • How to take out a report from WEB

    Hi,
    I have to take out a report from web. It needs to be passed two parameters from WEB. Which is the URL that i have to put in the Explorer, to get the report (made with Reports 9i). If it it with VALUE0=PARAMETER1&VALUE1=PARAMETER2 why doesn't it work?
    What i need is this part: http://.............&desformat=pdf&destype=cache&report=lgv_solicitud_viaje.rdf&valor0=200700000301

    Sounds like you need to use the rwservlet. Look here for more details but an example URL for the rwservlet looks like:
    http://myias.mycomp.com:7779/reports/rwservlet?server=myrepserv+report=test.rdf+userid=scott/tiger@mydb+desformat=pdf+destype=file+desname=test.pdf

  • How to calculate the Time difference between 2 dates

    HI All,
    I am using HR_hk_diff_btw_2_dates to calculate the employee service dates.
    For that i  am inputing his hire date and Term dates and Output format as '05' i am getting output perfectly....
    But problem is  whe i am inputting the employee hire date is Dec 1 2007 and Term date is
    March 31 2009 It is coming as 1 year 3 months  31 days instead of 1 year 4 months directly .......How could we make it make last date also working day and get the O/p as 1 year 4 months ?Please Advice..
    Regard
    sas

    1. FM for difference betwwen two times:SCOV_TIME_DIFF
    Import parameters               Value
    IM_DATE1                        2008-01-01
    IM_DATE2                        2008-01-01
    IM_TIME1                        10:00:00
    IM_TIME2                        11:30:00
    Export parameters               Value
    EX_DAYS                         0
    EX_TIME                         01:30:00
    2. SD_CALC_DURATION_FROM_DATETIME : Finds the difference between two date/time and report the difference in hours
    L_MC_TIME_DIFFERENCE : Finds the time difference between two date/time

  • Time calculation from one date to some other date

    Hello,
    I want to time calcualtion from one date to other date period.
    for calculating total hr's from one date to other date.plz let me know the logic.
                           Date                      Time
    Eq:  1st date:   22.05.2008             01.10.00
          2nd date:   25.05.2008             12.10.00
    I want the total hrs from 22.05 to 25.05 like i need result as
    from 22 to 25 total hrs based on the time given.

    Hello,
    Instead of FM..We can achieve by the following program...
    REPORT YRT_TEST1.
    parameters : date1 like sy-datum,
    date2 like sy-datum.
    data: days(3) type n.
    data: years(10) type p decimals 3.
    start-of-selection.
    days = date2 - date1.
    years = days / 365.
    write: / days,
    years.
    Now Multiply 24  to days to get hours and the multiply with 60*60 to get the seconds
    ***************Reward points,if found useful

  • How to find out time difference between 2 consecutive characters coming in

    Hi
    Data is coming on serial port and m taking this data in a input stream.I need to know the time difdference between consecutive characters.Any ideas?

    What do you mean? If you meassure the time between two characters, you want to calculate how accurate it is? First you would need to find out how accurate the System.currentTimeMillis is on the platform you run on. That may be easy
    long start = System.currentTimeMillis();
    long end;
    while ((end = System.currentTimeMills()) == start);
    long delta = end - start;But sometimes (on win98) it reports 50, other times 60. So its not quite accurate. But you could redo that test a couple of times and take the avg or the max.
    Then if you get a time difference of 0ms between two characters, you know it will be somewhere 0 and 60ms. If you get 60ms between two characters, you know it will be somewhere between 0 and 120 ms. It's +/- delta seconds accurate.
    Would this be a way to calculate the percentage accuracy: 100.0-100.0*delta/(time+delta)
    Still better to meassure the time over more than just 2 characters unless it is a very slow stream.

  • DateDiff Help (Need time difference FROM Time 1 TO Time 2 - one direction)

    I hope I am putting this in the right section. This is my first post. Thank you all ahead of time for your help.
    I am new to both SQL and Report Builder so please bear with me and thank you ahead of time.
    I need to find the time difference (in minutes) between Time 1 and Time 2. I've figured out the basics in how to do this but I need the logic to work in ONE DIRECTION. Meaning I need the statement to find the difference STARTING FROM TIME 1 and then ENDING
    WITH TIME 2. I need the statement to always assume that Time 1 is FIRST and that Time 2 is LAST.
    Here's an example of my results now with a basic DateDiff statement.
    Time 1 | Time 2 | Time Difference (in minutes)
    11:30 | 1/15/2015 11:50:00 AM | 20
    23:50 | 1/15/2015 12:00:00 AM | 1430
    23:45 | 1/15/2014 2:05:00 AM | 1300
    Please note that Time 1 does NOT have a date at all and came over from its table as a simple 4 digit string so I had to convert it to datetime format using a concatenate statement. If it DID have a date then this probably wouldn't be a problem.
    Thoughts?
    Thanks.

    Thanks, Patrick. I'll look into understanding that (I'm still new to both SQL and Report Builder). Could you explain to me what it does?
    I was able to answer my own question only to find that it didn't quite work the way I need it to. I was able to make the logic work so that "if the time is 12AM then change the date for Time 1". However, I ran into another problem and realize that
    I ultimately just need to get this to work in one direction. Meaning I need it to find the difference in time STARTING from the Time 1 field TO the Time 2 field. Here's why (using the statement I got to work but only for 12AM):
    Time 1 | Time 2 | Time Difference (in minutes)
    23:45 | 1/15/2014 2:05:00 AM | -1300

  • Time stamp from dynamic data

    I trying to write dynamic data to a file using Express VI (Write LabView Measurement file). The dynamic data comes straight from a simulated Signal Express VI. The signal part of the dynamic data is written correctly but the time stamp is what appears to be float counting the seconds since the Write LabView Measurement file Express VI was started.
    I have configured the Simulate Signal VI Time stamp to absolute data and time option.
    This should be dead simple but it just do not work!
    Any suggestion to what I might do wrong?
    I do expect that the time stamp would be written as two columns one for date and one for time.
    Thanks,
    Soren T. Jensen

    The timestamp is written in the header of the file. The time and date entered there is the time and date that you are looking for. The timestamp written next to each piece of data is indead a relative value. It is the delta from the timestamp in the header to the time that datum was collected (created). The reason for this is that timestamps are quite large in bytes, especially if you break out the time and date in strings. Just stamping the header and providing the offsets is much more efficient.
    If you choose to not provide a header, I think that the timestamp will be lost entirely. I think that this is probably wrong, but I am uunsure what should be done to correct it.
    Hope that this helps,
    Bob
    Bob Young - Test Engineer - Lapsed Certified LabVIEW Developer
    DISTek Integration, Inc. - NI Alliance Member
    mailto:[email protected]

  • In my TDS Certificate Report takes more time in fetching the data from bseg

    only i am checking mblnr and company code.

    I think you can do this, but not the way you are doing it now. You have to use most of the key when going agains BSEG. I'll look around a bit and get back to you.
    Yes - you can get the purchase order and sales order line items for the material. Then go to the history tables to get the material document numbers. Finally use AWTYPE and AWKEY to get the document numbers from BKPF.
    Rob
    Message was edited by:
            Rob Burbank

  • Time difference report using date range

    Hi,
    I would like to know a clue as below in the same thread as it is more relavant to this, if you do not mind.
    I have one more query using the same table and set of data for one of the report.
    Here the the column call_date is timestamp.
    Calls by n min interval
    Parameters should be startDate and endDate.
    This is actually 2 queries. The simplest one, should return a list of games with the start and end time, similar to previous report.
    The second, should return number of calls every n minutes interval. So, if n is 1, should return something like this:
    Period     Calls
    starting (Nos.)
    21:00     34
    21:01     42
    21:02     55
    22:58     88
    22:59     63
    Ideally, the number of minutes in an interval should be dynamic, (can be passed as a parameter).
    Many thanks in advance.
    Jayesh
    Please find the attached script for generating table and populating data.
    create table calls
    2 as
    3 select 441132394629 cli, to_date('02102006 17:30','ddmmyyyy HH24:MI') call_date from dual union all
    4 select 441132394629, to_date('05102006 17:00','ddmmyyyy HH24:MI ') from dual union all
    5 select 441132533793, to_date('04102006 14:30','ddmmyyyy HH24:MI ') from dual union all
    6 select 441132533793, to_date('05102006 12:20','ddmmyyyy HH24:MI ') from dual union all
    7 select 441142373223, to_date('04102006 10:30','ddmmyyyy HH24:MI ') from dual union all
    8 select 441142373223, to_date('05102006 13:50','ddmmyyyy HH24:MI ') from dual union all
    9 select 441227763301, to_date('02102006 16:30','ddmmyyyy HH24:MI ') from dual union all
    10 select 441227763301, to_date('04102006 11:20','ddmmyyyy HH24:MI ') from dual union all
    11 select 441227763301, to_date('05102006 17:20','ddmmyyyy HH24:MI ') from dual union all
    12 select 441227763301, to_date('08102006 17:30','ddmmyyyy HH24:MI ') from dual
    13 /

    Have you see my answer in Re: Total call Date  report using increment date ?<br>
    <br>
    Nicolas.

  • How to set the time difference between each data when sweeping voltage using keithley 2400

    Hello friends,
    I am using the sweep vi from Keithley in the SWEEP and Acquire measurement vi.I want to measure the voltage for every step and insert a delay in between every two data, so I need some delay between each I step.
    I am a starter to use Labview, thanks so much for your answers.
    Perry
    Solved!
    Go to Solution.
    Attachments:
    Keithley 24XX Sweep and Acquire Measurements.vi ‏26 KB

    As Dennis said, if you're using the built-in sweep function, you'll have to check the manual. See Section 10-16 (That's section 10 page 16, not sections 10 though 16) of the Keithley 2400 User Manual.
    The Keithley 24xx series has a measurement speed in units called PLC (Power Line Cycles). The default speed is 1PLC, meaning a measurement is taken every 1 power line cycle, or 1/60th of a second (16.67ms). 24XX's can go from 0.01 PLC (every 0.16ms) to 10 PLC (every 166.6ms). The faster you measure, the lower precision you get.
    To set this value programmatically, the command is
    ENSe:CURRent:NPLCycles <n>
    ENSe:VOLTage:NPLCycles <n>
    depending on what you're sensing and where <n> is the number of PLCs from 0.01 to 10.
    Another factor that will determine the time between data points is the SDM cycle. These are more complicated, look at your Keithley user manual for more information. Look at Section 6 and Section 11 for more info.
    Note:
    PLC times are based on a US cycle of 60Hz.

  • SQL Query find month/year and then calculate difference from start date

    Hi All,
    Assume I have a table with a column Start_Date. I like to know how we can build a query to so we can find the end of the month date based on the start_ date and then calculate the difference
    For example lets say we have a date 12/06/2014 and now based on this we should get the end of the month date which is 30/06/2014. Now we can get the difference which is 18 days.
    Thanks

    Hi Jaggy99,
    According to your description, you need to get the date difference between a given date and the last day of that month, right?
    In this case, please try the query below.
    SELECT GETDATE() AS [CURRENTDAY], DATEADD(DAY,-1,DATEADD(MONTH, DATEDIFF(MONTH, 0, GETDATE()) + 1, 0)) AS [LASTDAY],
    DATEDIFF(DAY, GETDATE (), DATEADD(DAY,-1,DATEADD(MONTH, DATEDIFF(MONTH, 0, GETDATE()) + 1, 0))) AS [DIFFERENCE]
    Regards,
    Charlie Liao
    TechNet Community Support

Maybe you are looking for

  • Need Query to do a Sum functionality

    Hi, I have a table named Employee. The columns are Name varhcar2(10) and Salary Number(10,0) The Entries in the field are Name Salary Bob 25000 Alen 30000 Rose 15000 Ann 20000 I want to find the salary of Alen and Sum of Salary of other members in a

  • My appleTV does not remember podcast playback position

    Is anyone else finding that video podcasts are not remembering their playback position despite standard movies remembering theirs?  Thanks in advance.

  • Token for File Open

    Hi All, I am trying to open a .eml / MIME file using File Open command. But I do not know which token to use. All I have is a valid MIME file. I tried using Retrieve token, but if there is an already open message view, the new file content (MIME) get

  • Board not detected from MAX

    The machine is equipped with NT4.0 sp5, and was using an old PC-TIO-10 with NIDAQ6.1. We decided to sobstitute the board with a PCI-6023E, as we needed some analog signal inputs. We installed NIDAQ6.8.1 (without first uninstalling 6.1 version), put a

  • Importing folders into albums (PE7) & keeping structure

    hi, Is there any way to import folders (w/pix) into photoshop elements 7 albums while keeping the folder structure in albums? For example: Folders 2009 +-->  Jan +-->  Feb     +---->  Kids     +---->  animals to the same but in Albums? thanks Jason