Date Format in CSV & Excel

Hi,
I have a search result which has some date columns and have a button to export these results to CSV file.
The database column is of datatype VARCHAR but date is stored in it and displayed, so while fetching data from there we are converting it to date in format DD-MON-YYYY.
while displaying the search results, its working perfectly fine.
When downloaded to CSV file, and Opened with Any Text Editor other than Excel, the date format is proper as in screen ie. DD-MON-YYYY
But, once we open the CSV in excel update few columns and save the file, the date gets saved in the DD-MON-YY format.
Since this file will be uploaded back to the application, we can either design our recieving application to expect date in DD-MON-YY format. But is there anything that we can do to have it maintained in DD-MON-YYYY format itself ?

Can any one please help me out. Iam in need of a labview code which has a excel sheet consists of 
3 columns
1) DATE  
2) TIME
3) TEMPERATURE value.
If a string is entered as a input and that string should be compared with the Names under DATE AND TIME column in the excel sheet and if the string entered matches with any of the string under the DATE AND TIME column then it should pass one output
1) The value of that string 
For example if Iam entering the i/p as 10/7/2012  03:55:05 PM then it should search the strings under DATE AND TIME tab and if row 8 as the 10/7/2012  03:55:05 PM string with a value of  461.106 then it should return two o/p's one as 461.106  
If the entered string is not matched  with any of the strings under DATE AND TIME coulmn it should return an output as zero.
i am attaching a excel sheet screen shot which is in csv format
Thank You
Attachments:
excel in csv.docx ‏190 KB

Similar Messages

  • Saving chosen date format in csv-file

    I format all cells in one column to a dateformat dd-mmm-yy
    i.e. 01-jan-06, works fine I have all the dates in the year by clicking on first cell.
    BUT I can not SAVE the file as csv keeping the format - it is saved as 01-01-2006, which I can not use.
    I do this in Excel all the time - do I have to do something special in Staroffice Calc 8.0 ?

    A similar issue faced here trying to save a worksheet (Staroffice Version 8) in .csv format. The worksheet had one column for date of birth formatted as "dd/mm/yyyy" and another one for age using formula "=TODAY()-B6", formatted as "yy". In the corresponding .csv file the age column showed up as "dd/mm/yyyy" as against the required "yy" format . On saving the data in text file with the space delimited option, the date of birth column showed up in the "mm/dd/yyy" format - the age column however was in the desired "yy" format.
    Here is a workaround though;
    On your existing staroffice worksheet format all the data just as would like it appear in the .csv file. The trick is to transfer the data into an intermediate application that does not understand the underlying formatting or formula, which in our case will be notepad. Copy the entire range of data from your staroffice worksheet into notepad. Minimise notepad after the data has been pasted. Save and exit the existing staroffice workbook. Open a new workbook, select the entire range that is going to hold the data and then format the cells as "text". Now, maximise notepad, select all the data using the edit menu and copy it into the new worksheet. The data should appear just as it was in the original worksheet, but without any formatting or formula. You can now proceed to save the data in a .csv file without having to worry about changed date formats.
    However, if you have come across some other method through which this issue has been resolved, please post here or drop me a a mail
    anandkumarvj [at] rediffmail.com

  • Date format in CSV file not coming as required

    Hi,
    I have a problem in date format after it is downloaded as a CSV file. In CSV file it is coming as 2/6/2009
    but the format i required is 2009/02/06. Im using GUI_UPLOAD FM for file download. In the internal table im having the date in this format YYYY/MM/DD only.
    How can i bring the date in CSV file in required format?
    Thanks in advance,
    Srilakshmi.

    Hi Srilashmi,
    You question really made me wear thinking cap.
    When you populate date in SAP system, it's taken in internal format i.e YYYYMMDD, though you declare date field as DATE, D or SY-DATUM, the issue comes into light, when you got to display it.
    1. Import date in internal format i.e. YYYYMMDD,
    DATA:
      w_date type d.
    2. Declare another variable w_date1(10) like C.
    3. Goto System-> User Profile -> Own Data -> Defaults -> Date Format. Now, whatever date you have set, it's gonna take the same format.
    4. WRITE W_DATE TO W_DATE1, transport imported date to char type w_date1, this makes date appear in format you want it to .
    And regarding, saving in CSV format, not always GUI_UPLOAD or GUI_DOWNLOAD works,
    TEXT _ CONVERT _ XLS_TO_SAP   -> From program to excel sheet
    ALSM_EXCEL_TO_INTERNAL_TABLE  -> Excel sheet to Program
    Hope this helps you.
    Thanks: Zahack

  • Date format issue in Excel

    Hi,
    I have a date in XML file which is in the format of YYYY-MM-DD. When i output to excel, the date needs to come as MM/DD/YYYY. I am able to format the dates as MM/DD/YYYY, but if there is a 0 in the Month or Date, it is coming as M and D instead of MM or DD.
    Eg: 2008-11-01 comes as 11/1/2008 in the excel, want it to come as 11/01/2008
    Any solution for this? I tried using subst-ringing the parts and lpad-ing with 0s, but the zeroes get stripped when you come to excel. I am not able to lpad with space, since the field is inexplicably, automatically changing to number type and gives "Cannot convert to number" error.

    Hi ,
    Its a strange requirement but still lookig for answers..
    1) Tried the User Profile and it the file is being generated in the format the use has.  However
         if we open the excel file ( Right click and say format Cells---->In this case it shows GENERAL).....The user wants the cell
         always in the date format so that can have sort and other macros...
    To Reiterate................
    1) We have to generate the Files in the date format that the user profiel has and also the excel file should show the date cells in date format but not general....

  • Date format error in excel sheet

    When i try to download ALV grid display report into excel sheet using the following procedure
    Menu - List - Export - SpreadSheet - Radiobutton Table - Radiobutton Microsoft Excel- Then an excel sheet is downloaded but the date format is of some random number like 40182 but actual date is (01/04/2010 format MM/DD/YYYY) .
    But when i try to download using the procedure Application Menu bar - Local File - Radiobutton Spread Sheet - Giving the path of the file. When i see the date is in (01/04/2010 format MM/DD/YYYY)  which is correct.
    I want to know what are the settings that needs to be done for downloading the excel sheet with the first procedure which i mentioned above.
    Regards
    Venk@

    Hi Gautham,
    I took standard types..
    TYPES: BEGIN OF ty_bkpf,
               gjahr TYPE bkpf-gjahr,          "Fiscal Year
               bldat TYPE bkpf-bldat,          "Doc Date
               usnam TYPE bkpf-usnam,          "User Name
               waers TYPE bkpf-waers,          "Currency
               END OF ty_bkpf.
    No data declarations of Date down separately . You can see Doc date i have decalred as BKPF-BLDAT. Anything more you wanna add.
    Regards
    VEnk@

  • Date format problem in excel format

    Hi,
    I am uploading the date field  from excel to program.
    My problem is in date format.
    I am gettting the date format in ddmmyyyy if it is 01012006 then my excel sheet contains the date as 1012006 i.e '0' initial zero is truncated in the excel sheet .
    Now how can i use this date in my program i.e i have to convert into date as per program requirements like dd.mm.yyyy  .How can i convert.
    Thanks and regards,
    shyla

    Hi Shyla,
    if the provided excel sheet contains date in format "20122006" the field is considered as a number format.
    In this case you can do the following select the whole column and go to format/cells. Choose the "custom" category on the Number tab and
    enter zeros in eight digits, i.e. 00000000 under "Type:".
    This should solve your problem before uploading the data into SAP.

  • Date format in CSV file

    Hello,
    I am working on loading program which downloads the application server CSV file to internal table.
    In the CSV file there is a field date in the format (22/05/2008). When I move this to my internal table field date, it is truncating to '22/05/20'. How to solve this issue.
    Can I load into internal table with the same format?
    Please help me.
    Thanks,
    Shreekant

    Hi, Rangrej
    As all Suggested assign first this date to char type filed length 10 and using following way you can assign this to type date.
    Test Sample Code Bellow.
    TYPES: BEGIN OF ty_test,
      cdate(10),
      date LIKE sy-datum,
      END OF ty_test.
    DATA: it_test TYPE STANDARD TABLE OF ty_test WITH HEADER LINE.
    it_test-cdate = '22/05/2008'. APPEND it_test.
    it_test-cdate = '23/05/2008'. APPEND it_test.
    it_test-cdate = '24/05/2008'. APPEND it_test.
    it_test-cdate = '25/05/2008'. APPEND it_test.
    it_test-cdate = '26/05/2008'. APPEND it_test.
    LOOP AT it_test.
      it_test-date+0(4) = it_test-cdate+6(4).
      it_test-date+4(2) = it_test-cdate+3(2).
      it_test-date+6(2) = it_test-cdate+0(2).
      MODIFY it_test INDEX sy-tabix.
    ENDLOOP.
    Best Regards,
    Faisal

  • Changing date format in CSV import

    I'm importing banking statements in csv (comma separated values) to Numbers but dates of transactions are not being properly formatted. My Apple-->System Pref-->International-->Format is set to Canada so that 5th of January 2008 can be shown as 5-Jan-08 or 05/01/08 which is my preference. However, the dates in data from bank will interpret this as 01-May-08 (the bank is Canadian). Is there a simple way I can reformat the data correctly?
    thanks, hopefully I'm clear enough.

    Before importing these datas, set your system to USA
    Given that, the dates would be correctly imported.
    Then, reset the setting to Canada.
    Numbers will then display the dates using you preferred setting.
    You said "imperialism" ? You didn't but it resemble
    Yvan KOENIG (from FRANCE mercredi 17 septembre 2008 10:54:52)

  • Change date format in ms excel 2013 form MM-DD-YYYY to DD-MM-YYYY

    Dear sir
    I have got a database from my client where the entire dates are in MM-DD-YYYY format. However my system runs in DD-MM-YYYY format(based on my company lines).
    So i need to convert  this MM-DD-YYYY to DD-MM-YYYY format
    Please help
    Thank you

    If you want to change the format in excel ,Click 'Home' Tab in the Ribbon-> In 'number 'Group->Choose 'more number format'-> 'custom'->change the 'type' as "DD-MM-YYYY".
    Or use the formula =TEXT(A1,"DD-MM-YYYY")
    If you want to change the format when export it from SQL Server Database to excel.
    Use
    select Convert(VARCHAR(10),column name,105) as date from
    database name

  • DATS format in MS excel

    I have to extract many date datasets from excel to InfoObjects in SAP BW. InfoObjectsand DataSource  fields have datatype DATS.
    I use the external representation of dates (e.g. 18.09.2009) in excel.
    Some dates are empty on purpose. I want them to be empty in SAP as well.
    What is the right excel content of such cells ?!
    I already right:  ' ' (empty), '  ' (empty string), '00.00.000', null, '-'
    but nothing of these contents works...Any ideas ?
    Thanks in advance!
    Edited by: jkastl on Aug 19, 2009 2:34 PM

    Have you tried with SAP format YYYYMMDD in your Excel dates ?
    If you can load that format into PSA, then there is a SAP conversion for this format into SAP's internal one.
    Hope it helps,
    SJR

  • Output report data to excel file format or csv format

    Is there any way to save softcopy of report output to excel file format or csv format.

    Hi,
    Regarding csv file format, i have no issues. The file is generating without any issues in using oracle reports without using any PL/SQL code.
    My requirement is to design oracle reports to generate excel (.xls) file with multiple worksheets. Each sheets are having many data and graphs(chart).
    Using oracle reports alone, how to achieve this.
    In oracle reports 10g 1.2.0 version, I tried by creating .rdf file but, it is generating single worksheet only.
    In oracle reports 10g 1.2.0 ver, I tried by creating .jsp file. For this first i am creating excel template about how my ouput column headings all that going to be with one sample hard coded data and save the excel file as web page.
    Eg employee.html.
    Next open the html file in oracle reports builder and double click the websource now, you will see the jsp tags, html and xml tags. Now include the contentType="application/vnd.ms-excel " and charset also.
    Next, include the <rw:foreach id="G_EMPNO_1" src="G_EMPNO">
    here insert the fieldl for each column by removing the hard coded values.
    close the tag
    </rw:foreach>
    Save the file as .jsp and deploy it in oc4 enabled folder (say, devsuite_home/reports/j2ee/reports_ids/web
    Start the oc4J server
    Run it in the browser http://server:port/reports/emp.jsp?useride=uid/pwd@db
    It is invoking the Microsoft excel with 3 sheets default and my emp table output in the first page.
    We can save this output file as .xls file by clicking file -> save as.
    1) The question is, it is working fine with Microsoft excel 97-2003 version. But for excel 2007, i am not able to create single html file like how 2003 save web page option.
    2) I found this in oracle getting started demo
    http://www.oracle.com/technology/products/reports/htdocs/getstart/demonstrations/index.html
    Which is more useful. This is what i am looking for.
    I done that in excel 2003 as per demo. But excel 2007 with reports 10g issues.
    Is there any demo for 10g with excel 2007
    3) For most of excel issues working fine with excel 2003 and 10g. But excel 2007 with 10g reports are issues.
    I want the excel output from oracle reports with multiple worksheet similar to the above demo.
    Thank you.

  • I need how to load data from MS Excel(csv format) to NW Excel

    Hi,
    I am doing Migration project from SAP MS to NW Manually.
    I need how to load data from MS excel (csv format) to NW excel .
    For example 2008 budget data.
    Could you please help me in this.
    Thanks and Regards
    Krishna

    Hi,
    You need to create a transformation file and a conversion file if required. First upload the excel (csv) file into BPC using Manage Data and Upload File option.
    Create the transformation file (refer to the sap help  on how to define a transformation file). You need to specify the mapping correctly and include all your application dimensions and map them to appropriate columns of the flat file.
    Before running the import package, do validate the data in the flat file you uploaded into BPC with the transformation file you created.
    Thanks,
    Sreeni

  • SSRS 2008 R2 - Missing Data when Exporting to Excel or CSV (Row Count is 500)

    Hey Folks,
    When exporting SSRS 2008 R2 report  to an csv or excel file not all the rows are being exported. Any suggestions on why this is occurring. The number of rows is less then 500 and it seems to be a pretty straight forward export. Any help is
    greatly appreciated.  Inherited this and not sure if this would be configuration issues or something else. It is happening on a number of reports.
    Thanks.

    Hi Humbly,
    According to your description, when you export report into CSV or Excel format, some rows are missing.
    In your scenario, since you are missing data “rows” in your exported file, we are guessing if you have any visibility setting like toggle which hide those records. It’s possible that you have set toggle or visibility in your report. After exporting
    Excel/CSV, some data might not appear properly. In SSRS 2008 R2, it has reported this kind of issue about data missing after exporting. However, those scenarios are not exactly same as your issue. It mostly turns out be conflict between data and “layout render”
    and related to DataElementOutput property. DataElementOutput property controls export behavior, it indicates which report item data should appear in Excel/CSV render. For more information, please refer to this article: Reporting Services:
    Why aren’t all my report columns exporting to CSV and/or XML?.
    As we tested in our environment(SSRS 2008 R2), no matter what we export into CSV or Excel, we get same results as in BIDS . So I would like to know your report design structure. If possible, please provide some screenshots about results in BIDS and Excel/CSV
    render extension results. It may help us find out the root cause of your issue. Thank you.
    Best regards,
    Qiuyun Yu

  • MS Excel automatically converts numeric fields to date format

    I have at least 2 different spreadsheets where this happens.  I maintain them for months, adding, changing, deleting data.  They contain lots of data elements (numeric, text, date, etc).   Some columns are all numeric, some all dates,
    etc.  Then suddenly when I open the spreadsheet, my numeric formatted data has been converted to date format.  I see lots of # signs in cells, which is an indication that this happened, and selecting an affected cell shows a date, generally in the
    early 1900s, depending on the original numeric value that was in the cell.  I convert the fields back to numeric, but sometime later the same problem occurs -- numeric fields are now date formatted.  I cannot identfy any specific change that I make
    that would cause this.  And I only recognize it as having occurred when I open the spreadsheet, not anytime during its maintenance.  I am using MS Excel 2007 SP2 in a Windows XP SP3 environment.  The machine is well maintained and updated /
    kept current by our corporate IT group.  I have done numerous Internet searches and cannot find anything like this in any other blog.  Thanks for your help.

    Hi,
    Were some of the these data imported from a .csv file? As far as I know, data formats cannot be saved in .csv file. If this is the situation, try this:
    Save a copy of your .csv file changing the extension of your file from .csv to .txt
    open excel.
    go to DATA --> Import external data --> Import data --> browse to find the .txt file you made earlier
    The text import wizard should open.
    Click on delimited, click next
    click comma, click next
    You should now see all columns appear with heading GENERAL --> highlight the columns with the values that are changing to date and click TEXT (top right) instead. The heading of these columns should now change to TEXT.
    click finish
    Excel will now treat the column as text when it imports the data and will not change them to dates
    If this is not the situation, this issue might be caused by some add-ins.
    Start Excel in safe mode:  Press and hold the
    CTRL key, and then click the Excel program to start. Then, click File > Open to open the Excel file.
    If the problem does not occur in the safe mode, this issue might be related to some third-party add-ins in the Office program, we can try to disable them.
    Best Regards,
    Sally Tang

  • Issues with data exported in CSV format

    Hi,
    I'm wondering if anyone else is having problems with exporting system data as a CSV? I can successfully run an export, however many of the CSV files contain superfluous line breaks resulting in the comma delimiting not working properly when viewing the records in Excel.
    Does this sound familiar to anyone else?
    Cheers,
    Cameron

    Are you talking about the case where you export some records and when you open using microsoft excel everything looks as if in a text file? If so,then yes. Infact yesterday I was exporting and having the issue. Donot remember having the issue before the upgrade. What I did is opened a blank microsoft excel sheet.Then File>Open and chose the csv file.Then modified in the text import wizard to get it in the right format.

Maybe you are looking for