From  date column I want to pick the hours only......

Dear All
I am facing the following problem.
I having following date format in database of date column
4/7/2006 10:26 AM
4/7/2006 07:18 PM
from this date column I want to pick the hours only , For ex. 10, 07 resp.from the above record.
I tried it to solve using SUBSTR and LTRIM-TRIM function, but this functions will truncate the time format and so unable to pick the Hours.
Is there any other solution for this.
Also the date column I have is in 12 Hours(AM/PM) format I want to convert it into 24 Hours . Like 07 PM . I want it to 19.
Thanks
Vishal.

TEST@db102 SQL> select * from test;
C1
4/7/2006 10:26 AM
4/7/2006 07:18 PM
TEST@db102 SQL> select to_char(to_date(c1,'dd/mm/yyyy hh:mi PM'),'hh24') from test;
TO
10
19
TEST@db102 SQL>                                               

Similar Messages

  • I have a Numbers spreadsheet filled with data. I want to swop the columns

    I have a Numbers spreadsheet filled with data. I want to swop the columns to be rows & rows to be the columns, i.e make the columns the rows & make the rows the columns. Is there any way to do this? Thanks

    Here is a link to a previous discussion:
    https://discussions.apple.com/message/25571095#25571095
    SGIII provides and applescript

  • I have a numbers spreadsheet for tracking company data.  I want to copy the format of the spreadsheet (rows, columns,and formulas) but have all of the data fields be blank for the new year.  How do I do that?

    I have a numbers spreadsheet for tracking company data.  I want to copy the format of the spreadsheet (rows, columns,and formulas) but have all of the data fields be blank for the new year.  How do I do that?

    click and hold on one cell, then drag to select the range, then release, then type the delete key.  Only inlude cells in the range you do not want to keey the contents of the cell.  You can remove one-off cells by holding the command key and clicking cells to add or remove as needed.
    You can download the Numbers users guide here:
    http://support.apple.com/manuals/#productivitysoftware

  • I did a backup from my 3G and want to get the backup now on my iPhone 4, but the backup from the old 3G is not shown as an option to configurate. How do I get the information on my new phone?

    I did a backup from my 3G and want to get the backup now on my iPhone 4, but the backup from the old 3G is not shown as an option to configurate. How do I get the information on my new phone?

    First, back up your old iphone manually:
    Disable autosync in iTunes, connect your phone to your new computer and right click on it in the device list and choose backup. iTunes will backup your phone without syncing.
    Transfer your purchases the same way, choosing "transfer purchases" this time.
    When you connect your old phone for the first time, all media content will be erased. But you can restore your settings and app data from your manual backup afterwards.
    Don't forget to set up at least one contact and event on your new computer to be able to merge calendars and contacts when you sync the phone for the first time.
    About backups and what's saved: http://support.apple.com/kb/HT1766
    How to back up and restore: http://support.apple.com/kb/HT1414
    How to download apps for free again:http://support.apple.com/kb/HT2519
    After that, connect your new phone and let iTunes set it up. iTunes will detect the old 3G backup and ask you, if you want to use it to restore the info on your new iphone. If you agree, all settings and data will be present after the process is finished.
    This is also explained in this article: http://support.apple.com/kb/HT4137

  • How to Calculate Duration from Date Columns

    Hello,
    I would like to calculate duration from date columns. Using the following query
    SELECT DISTINCT
    EVENT_ID,
    To_Char(RU.START_TIME, 'HH24:MI') START_TIME,
    To_Char(RU.END_TIME, 'HH24:MI') END_TIME
    FROM ROOM_USAGE RU
    What I need is to subtract START_TIME from END_TIME and result should be in minutes.
    Many Thanks,

    But, i think you need to calculate the number of days if the days are not same -
    satyaki>
    satyaki>
    satyaki>
    satyaki>with ru
    2 as
    3 (
    4 select '05-JAN-2007 15:10:20' start_time, '07-JAN-2007 19:20:20' end_time from dual
    5 union all
    6 select '08-JAN-2007 05:10:20' start_time, '07-JAN-2007 07:07:20' end_time from dual
    7 )
    8 select ru.start_time, ru.end_time, SUBSTR(numtodsinterval(to_date(RU.END_TIME,'DD-MON-YYYY HH24:MI:SS')-to_date(RU.START_TIME,'DD-MON-YYYY HH24:MI:SS'), 'DAY'), 12, 8) duration
    9 from ru;
    START_TIME END_TIME DURATION
    05-JAN-2007 15:10:20 07-JAN-2007 19:20:20 04:09:59
    08-JAN-2007 05:10:20 07-JAN-2007 07:07:20 22:03:00
    satyaki>
    Or, Am i missing anything?
    Regards.
    Satyaki De.
    is it possible to to add the duration? making the total hours to 26:12 (twentysix hours and twelve minutes)

  • I have a key figure in my master data table i want to display the key figur

    Hi All,
    I have a key figure in my master data table i want to display the keyfigure in my report how can i display it can somebody help me in this scenario 
    Regards
    Kiran Kumar

    Hi Kiran,
    Assume that Material master data table material has price as an attribute. To get this price as key fig in query, get material number in rows and in columns create new formula with replacement path to get material price as key figure.
    Note: Without taking material number into rows, we can't get the price into columns.
    Hope this helps u..
    Cheers......
    Sk babu

  • Hi! I`'m from Russia and i want to buy the new unlocked iPhone 4S in the U.S. in November, but i need to know, am i need this doc's?"What to Bring with You  Your old mobile phone, if you're replacing it. Social Security number of the account holder. etc"

    Hi! I'm from Russia and i want to buy the new unlocked iPhone 4S in the U.S. in November, but i need to know, am i need this doc's?
    What to Bring with You
    Your old mobile phone, if you’re replacing it.
    Social Security number of the account holder.
    Valid government-issued photo ID.
    Carrier account password, if you have one.
    Your Apple ID and password.

    http://www.apple.com/iphone/LTE/
    According to Apple's list (link above) you will probably want to pick up a Sprint or US Cellular model. HOWEVER, as I mentioned above I know that the Verizon iPhones come unlocked from the factory (assuming it will be the same for iPhone 6 and 6+). I DO NOT KNOW if the Sprint and US Cellular models come unlocked. But I am sure some quick internet research will lead you to the answer.
    I think your goal would be to get a Sprint or US Cellular version. Also I believe a law was just recently passed that allows someone to have a phone unlocked by the carrier no questions asked. So even if the Sprint and US Cellular iPhones are locked you can have them unlocked.
    Update:
    http://www.cbsnews.com/news/obama-signs-bill-unlocking-cellphones/

  • I have a generation 2 ipod which I inherited from my granddaughter, I want to copy the playlist from it to my PC, what do I do ?

    I have generation 2 ipod I have inherited from my granddaughter, I want to copy the playlist onto my PC, how do I do that ?

    After you have downloaded the 1.2.1 firmware, plug your iPod in and select it from under the Devices section in the left hand of iTunes.  Hold down the Alt key and press the Restore button. It should bring up a file browser/Windows Explorer window allowing to select an IPSW file. Browse out to where the file is stored on your PC and select it.  Then let the restore process complete.
    B-rock

  • HT5622 How I cancel anyone open my AppleID or stop them from using it I want to have my ID only in this phone

    How I cancel anyone open my AppleID or stop them from using it I want to have my ID only in this phone

    Change your password. Change your primary email address. Don't tell anyone your Apple ID information.

  • I want to Pick the Single file from The source Directory

    Hi,
       My Scenario is File to RFC .. I'm getting the files in the source Directory.. File names  are  SENDER_(TIMESTAP).XML .. but the problem is... When ever  Files  are available in the Source Directory  Immediately  XI was picking  all the files at a time.. But I want to   to Pick a single file at a time..
    for Making  this what we have to do..   After Processing the first file then only my Sender adapter should pick the next file...  (even though Multiple files are available in my Source Directory)
    Regards
    Jain

    Hi,
    the other option was use Adapter specific attributes in the Sender Communication channel..
    or
    while droping the files ask them to drop using time stamp in another directory  and an external validation is required .. and after validation push single file to Source directory using batch file..
    i.e use a batch file using run time operating system or make that batch file to run at OS level ..
    where the batch files needs to validate the time interval of the file and needs to push a single file to the source directory.. where from there we can directly pick a single file and process..
    regards,
    Kishore

  • Creating Time Dimension from date columns in fact tables.

    I remember watching a demo from a BI Tool a couple years ago, wich I swear was OBIEE, and the presentator stated it was possible to create a Time Dimension in the admin tool, based on a date column in other table.
    Can you guys tell me if there's such functionality in OBIEE?
    If so, how could I achieve that?!
    Thanks in advance!
    Marcos

    hi,
    You are trying to make Fact table as Dim table ???
    Fact table has some dim columns??
    We can do this by making a fact table as dim table ,create a dim hierarchy on that table
    Year level :Extract(year from fact_date_column)
    Month and year  level:CAST (Extract(month from fact_date_column) As CHAR(5) ) || CAST (Extract(yearfrom fact_date_column) As CHAR(5) )
    Like this
    But,be careful while doing this make sure that all joins and content levels are good
    As per my knowledge this is not a good way,Experts can add some words lets see!!!!!! :-)
    thanks,
    saichand.v

  • I want to pick the Exp.GL A/c of GRN with the help of IR Doc.(INv.Verifica)

    Dear All,
            CAn i know how can i pick the GL Account of GRN Doc.No.with the help of Invoice Doc.No.(Inv.Verification).From which table i can take these information.
    Please answer me immediately so that i can also reward point & the requirement is urgent.
    Best Regards,
    R.Rajakumaran

    Hi,
    Invoice you will have the Purchase Order no. Display the purchase order through ME23N and at the item details you can find the GRN No. Or double click on the purchasing doc no. system will display the PO.
    Thanks
    VK

  • How to retrieve latest date column comparing with rest of the date columns ??

    Hi Friends,
    I have 6 Date columns (some of col has Null data)  I need to compare all 6 columns date, how can I produce recent date to
    new Column! can you please help me Tsql Code or Function.
    Thanks for advance.

    Hej 
    create table datetest(id int,date1 datetime,date2 datetime,date3 datetime,date4 datetime)
    insert into datetest values(1,GETDATE(),GETDATE()-1,GETDATE()-2,GETDATE()-3)
    go
    SELECT  MAX(date_columns) AS max_dateFROM    ( (SELECT   date1 AS date_columns FROM     datetest         )          UNION          ( SELECT  date2 AS date_columns            FROM    datetest          )          UNION          ( SELECT  date3 AS date_columns            FROM    datetest          )  UNION          ( SELECT  date4 AS date_columns            FROM    datetest          )        ) AS date_query

  • I bought an iPhone 5 from a friend and want to keep the music that is on the phone. Anyway to do this without losing the music when i sync to my Macbook?

    I Bought an iPhone 5 from a friend and want to keep his music. If i sync it to my Mac i will lose it. Any way i can keep the music?

    Your friend does get to keep.  .Purchases are locked forever to the Apple id used to purchase them
    They just download again using the same Apple id

  • Apple TV3 and the New iPad - I  WANT to stream the sound only

    Hey guys!
    I've got the new iPad and apple tv 3 which is great together!
    I have a receiver (which is located in the living room)  with Zone2 option and also have outdoor speakers which are connected to that Zone2.
    When I sit outside i want to use my great speaker system and use the outdoor speakers using AirPlay and ATV and stream the content to my ATV but the thing is that when i do that I lose my video on the device and the tv shows my video feed.
    That of course is a problem coz I enjoy my great speakers but can't watch the video (like YouTube video or something else)...
    Is there a way to stream the sound only to the ATV?
    I found discussions of people who don't manage to stream their video to the ATV and only managed to stream their sound but that was an error and things like firmware update solved their problem...
    Found no discussions of people who TRY to stream only the sound, like I want to...
    Does anyone have an idea that can solve my problem?
    Thanks a lot in advance!!!
    Golan

    It's actually very easy and doesn't even require splitting the video stream and extracting the audio track from it (which is pretty easy if you have a desktop computer).
    If you don't want to play back protected content (non-music videos purchased from iTunes Store), all you need to do is getting GoodPlayer, letting it play audio in background (Settings > Background Audio) and connect to your ATV in non-AirPlay mirroring mode. It'll happily play back the audio track of the video while you can do anything in the foreground. (Note that, in addition to GoodPlayer, other background audio-playback players may also work - it's just that I've tested GoodPlayer in this regard between my ATV3 and iPad 3. Let me know if you need more - for example, a list - info on them.)

Maybe you are looking for

  • No audio for clips in my event library since upgrading to iLife '09

    After upgrading to iLife '09, I noticed something odd in the new iMovie. All of my clips (recorded with a Sanyo Xacti HD1A and imported into the previous version of iPhoto DO show up in the event library, but DO NOT play any sound in the event librar

  • How to Create Executable file for a project for Crio Platform

    hi, i am using CRIO 9014  platform  for my application development. i am controlling (   Reset  &  then Run )  FPGA   from RT application . Through TCP/IP  communication the  Acquired data  (   from FPGA  then followed by some Computation Logic in RT

  • Drag and Drop Attachment from Outlook to LABVIEW

    Hi, I try to write a very simple program, which manages files. With the path control of LABVIEW we fortunately can Drag and Drop files from e.g. explorer, whose path I can use after dropping. The problem is, that I would like to do this directly with

  • VOIP Dial out issues with SRP547W

    Hi All, this is my first post so I appologise if I have posted it in the wrong place up front. I have recently purchased an SRP 547w replacing an 877w and linksys pap2t voip box. I have 1 major issue at present - no matter which number I dial, I cann

  • Mouthpiece and earpiece dont work in 9810

    Hi All, I have a very undusual problem with my new Torch 9810. Suddenly the mouthpiece and earpiuece stop working as I am unable to listen to incoming calls and the reciever of my call is unable to listen to me. The phone rings fine but there is no v