How to convert an output retrieved from database to an excel sheet?

Hello friends,
I am preparing an online JSP based project for our training and placement department.
In this context, I am showing an output into a JTable format to the user for the shortlisted candidates by retrieving this information from my database (MySQL).
Now I need to convert this output into the Excel Sheet so that I can perform various operations over there.
So, what are the things required to perform from my side for implementing the same.

The easiest thing for you to do would be to save it as CSV (Comma Separated Values). In general, your fields would be separated by commas, and any fields that are not numbers would be surrounded with double quotes:
1,"text",...
Dates and times are semi-tricky, but excel is pretty good about accepting "YYYY/MM/DD" and "HH:MI AM" format.
Other than that, you'll be learning the internal structures of Excel or perhaps there is a third-party library that can do this for you...

Similar Messages

  • How to convert the customized report sales price list into excel sheet

    hi friends,
    i am faceing the probulem in VK13 report is not conveting into excel sheet, then i developed the one customized report,
    in this report i am using the tables are a506, konp,and makt, result is coming and it converted into excel sheet in my systam. when i was clik on the excel sheet icon it comming  excel format it working fine and save it. But in menubar list>export> localfile and select redio button spredsheet this navigation only it print the three colums not coming the total colums,
    same program test in another system it not converted into excel sheet, when i am click on excel sheet icon  it's given the message is 'VIEW CAN NOT BE SWITCHED, PRODUCT NOT INSTALLED OR INTEGRATION NOT ACTIVE'. but i giving the print privew it giving the three colums only,.
    In program i am using regular using reuse_alv_grid_display FM only.
    sorry this qusition is repeted becuse before that one mising some text.
    any one plz help me.
    thanks
    raj

    nice answer

  • Tell me how to format a date retrieved from a MS SQL Server 2000 database?

    Tell me how to format a date retrieved from an MS SQL Server 2000 database for various uses in my JSP page?

    Or if you want to use JSTL instead of a scriptlet see:
    http://forum.java.sun.com/thread.jspa?threadID=676754&tstart=0

  • Does anyone know how to convert the output from the standard report to xml?

    Does anyone know how to convert the output from the standard SAP report to xml?

    since it a standard report which you cannot modify you can only do the following.
    submit report exporting list to memory
    then
    list from memory and then
    use the returned itab along with CALL TRNSFORMATION key word to convert to xml.
    but this only going to place the whole list content (including data and formating lines,etc) into a xml element and not the actual data alone in the list .

  • How to convert Sequence file documentation from TXT or HTML to MS Word ?

    Hello, I would like to modify a DocSupport.prj which in default generate only TXT or HTML to support MS Wors *.DOC. I have already change the dialog (add *.doc filter..), that was simple. But the major problem is how to convert the output from doc.c to some *.doc file. I found somewhere here Word9 ActiveX  Instrument  for CVI, but I don't understand, how  the CVI gets informations about the steps etc.  from *.seq file for another use. The original code in doc.c is quite hard to understand it quickly. Thanks for help.

    Hi Pet007,
    You should be able to just change the file it saves to's extension to .doc. You'll notice there is a define for txt, you could either change this to doc or if you still want to be able to use txt, create a new define and use this. If you do this you'll need to also add a define above (as you see it defines an integer for each different format type and uses those throughout the program as well). That should give you a good starting point for modifying this code. Unfortunately it is quite extensive to actually accomplish this, or else I could give a step by step guide, but it is rather long. But you should be able to get it working from this. The reason this should work is because Microsoft Word (.doc) files understand plain text just like .txt files. However, if you want to add formatting (fonts, bold text, etc) you would need to use the ActiveX Instrument for CVI which just access the ActiveX server from Microsoft. For more information about ActiveX in CVI visit the following link.
    Using LabWindows/CVI as an ActiveX Automation Controller to Control Automation ServersAlso, this link gives an example of using Excel with CVI through ActiveX, which may give you some useful information about doing this type of thing.
    Embed Excel ActiveX Documents on a CVI PanelFor more information on using Word's ActiveX Server, check out the following Microsoft Portal.
    Word Developer Portal
    Brandon Vasquez | Software Engineer | Integration Services | National Instruments

  • Re: [Re: Keys retrieval from database]

    Hi Joseph,
    Thank you for your reply.I am using ODBC to connect Forte application with the database.And I went through the document, and tried all the possible ways, I could't succed in retrieval of whole data.I tried the sql execute procedure also.I will the error message
    after sometime.How does it related with escript?please clarify.
    Thank you,
    J.Babu
    [email protected] wrote:
    Hello Jendran,
    take a look at your 'Online-Help'. Search for 'DBDataType' (DBColumnDesc) and
    'GetDatabaseDesc' and look if your question is answered.
    See the 'Accessing Database Guide' Page 236 for a complete description of the
    call ('sql execute procedure' not 'sql execute Immediate procedure').
    Look wether you connect via ODBC or Direct to the database in your
    DBResourceMgr (Perhaps you have to look how this is specified in your
    environment in 'econsole'). If you have any more problems please copy
    the error-message in your email, to see what forte says to this error.
    Hope this helps
    Joseph Mirwald
    At 04:30 18.06.98, you wrote:
    Hi guys,
    Have any one used the method GetDatabaseDesc() of DbSession classto retrieve columns, primary keys and Foreign keys of a database? I
    couldn't retrieve any information except columns of MsSql server
    database.If possible give some information.
    I couldn't execute stored procedure from Forte, what could be theproblem? we tried with sql execute Immediate procedure.
    Thank you in advance,
    J.Babu
    Get free e-mail and a permanent address at http://www.netaddress.com/?N=1
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>

    Babu,
    Note that though you will be able to get column information on
    most of the
    databases, some databases do not maintain or provide access to
    key
    information. For these databases, specifying DB_IN_KEYINFO and
    DB_IN_FOREIGNKEYINFO has no effect. Oracle, Ingres, and Informix
    do support key information. Check vendor documentation for
    other databases
    on specific platforms.
    As rightly mentioned by Joseph Mirwald, you might want to email
    a copy
    of the error message that you get.
    Good luck!
    Ajith Kallambella M.
    Forte Systems Engineer,
    Internationational Business Corporation.
    From: [email protected][SMTP:[email protected]]
    Reply To: [email protected]
    Sent: Thursday, June 18, 1998 12:30 AM
    To: [email protected]
    Cc: [email protected]; [email protected]
    Subject: Keys retrieval from database
    Hi guys,
    Have any one used the method GetDatabaseDesc() of DbSession
    class to retrieve columns, primary keys and Foreign keys of a
    database? I couldn't retrieve any information except columns of MsSql
    server database.If possible give some information.
    I couldn't execute stored procedure from Forte, what could be
    the problem? we tried with sql execute Immediate procedure.
    Thank you in advance,
    J.Babu
    Get free e-mail and a permanent address at
    http://www.netaddress.com/?N=1
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive
    <URL:http://pinehurst.sageit.com/listarchive/>
    To unsubscribe, email '[email protected]' with
    'unsubscribe forte-users' as the body of the message.
    Searchable thread archive <URL:http://pinehurst.sageit.com/listarchive/>

  • How can I send a message from database to a J2EE application?

    How can I send a message from database to a J2EE application?
    If I have a codetable in database that has new or modified values I have to refresh the codetable in my J2EE application.
    Most effective way would be send a message to initiate a table reload from J2EE app, but I don't know how to do this.
    Now I have a background thread that regular reads the table and looks for changes.

    http://www.oracle.com/technology/products/integration/bam/10.1.3/TechNotes/TechNote_BAM_AQ_Configuration.pdf
    This document details how to create triggers on a table that send out JMS messages.
    In this example, the messages are going to Oracle BAM.. your message could go to your J2EE application listening to its own topic/queue.
    an alternative idea.
    you could also just cache your lookup table with something like Oracle Coherence and than try to ensure that all changes to the lookup go through Coherence, so that you won't need to do notification from the db up to the application. the application and the lookup data management tool would be using the data grid for management of the lookup table data, and the data grid (coherence) would persist the lookup data changes back to the db.

  • Data Could not be retrieved from database...

    Hi All,
    I have a problem on Excel 2007 while refreshing (for pivot table) data from SQL Server view:
    "Data could not be retrieved from database. Check the database server or contact your database administrator. Make sure that external database is availiable, and then try the operation again"
    Excel file is distributed on about 20 workstations in network with the same Excel version, and problem occurs only on one station. I have checked credentials and connection between workstation and server and it seems to be ok.
    Any ideas?

    it is problem, because sql server is not member of domain... so I'm using sql aunthentication.
    strange thing is that from any other workstations (aldo in domain) it works fine when providing SQL user. I'm supposing that it is problem with some excel settings

  • How many method can pass data from Database to front-end(aspx)?

    How many method can pass data from Database to front-end(aspx)?
    By using ajax, I want show some data to aspx or html
    Here is one of these method,
    HTTP Handler(ashx):
    we can json data, use HTTP Handler pass data to front-end
    And can we do this by other method? Web API? or some fancy way?
    Thanks for any reply

    Hello TaiwanWei,
    Try forums.asp.net.
    Thanks for your understanding.
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • How can we export the data from OAF Page to Excel instead of .csv or .txt

    Hello,
    How can we export the data from OAF Page to Excel instead of .csv or .txt
    When i click on the export button it is exporting to txt file, But i need to export the data into Excel by default
    Please help me
    Thanks in advance
    Thanks,
    Raju
    We have changed the below profile option to get the data in excel by default
    Profile Name Export MIME type
    Profile Code FND_EXPORT_MIME_TYPE+
    Existing Value: text/tab-separated-values+
    Change as: Excel
    Thank you,
    Raju
    Edited by: 1006649 on May 21, 2013 10:55 AM

    We have changed the below profile option to get the data in excel by default
    Profile Name Export MIME type
    Profile Code FND_EXPORT_MIME_TYPE+
    Existing Value: text/tab-separated-values+
    Change as: Excel
    Thank you,
    Raju

  • How can I prevent all workbooks from opening automatically when Excel starts?

    I am using Office 2011 (14.2.1) service pack 2 on Mac os X 10.7.3. Whenever I open Excel, all my workbooks open.  How can I prevent all workbooks from opening automatically when Excel starts?
    Please Help, Thanks

    You can look at: Stop Autoplay: https://addons.mozilla.org/firefox/addon/1765

  • How to download data from abap-ouput to excel sheet with logo

    how to download data from abap-ouput to excel sheet with standard logo
    Edited by: Harish Kasyap on Nov 18, 2008 8:19 AM
    Edited by: Harish Kasyap on Nov 18, 2008 8:20 AM

    For saving the report you can goto System -> List -> Save -> Local File -> Location where you want to save in your presentation server.
    You can also give a option in your selection screen to save the file to Presentation server using FM GUI_DOWNLOAD.
    Hope it helps.
    Thanks,
    Jayant.

  • How do i export my contacts from address book to excel?

    how do i export my contacts from address book to excel? and to file maker? is there an easy way?
    thx

    I have not tried it, but this is available:
    https://itunes.apple.com/ca/app/export-address-book/id402323447?mt=12

  • Can we generate output of a report in an Excel Sheet?

    Hi All,
      Can anyone tell me how to generate output of a report in an Excel Sheet format?
    Thanks in advance,
    Jasmine.

    hi,
    try this sample...
    data: begin of itab occurs 0,
          vbeln like vbak-vbeln,
          posnr like vbap-posnr,
          end of itab.
    select vbeln
           posnr
           from vbap
           up to 20 rows
           into table itab.
    * EXCEL sheet using OLE automation.
    INCLUDE OLE2INCL.
    * handles for OLE objects
    DATA: H_EXCEL TYPE OLE2_OBJECT,        " Excel object
          H_WORK  TYPE OLE2_OBJECT,
          H_SHEET TYPE OLE2_OBJECT,
          H_CELL  TYPE OLE2_OBJECT,
          V_COL   LIKE SY-TABIX.     " column number of the cell
    DATA:
      V_STEP(30),
      V_FILE LIKE RLGRAP-FILENAME.
    * tell user what is going on
      CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
         EXPORTING
    *           PERCENTAGE = 0
               TEXT       = 'Creating Excel...'
           EXCEPTIONS
                OTHERS     = 1.
    * start Excel
      V_STEP = 'Starting Excel'.
      CREATE OBJECT H_EXCEL 'EXCEL.APPLICATION'.
      PERFORM ERR_HDL.
      SET PROPERTY OF H_EXCEL  'Visible' = 1.
      CALL METHOD OF H_EXCEL 'APPEND'
        EXPORTING  #1 = 'D:SappdfABAP Trainingsheettr.xls'.
    *  PERFORM ERR_HDL.
    * tell user what is going on
      CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
         EXPORTING
    *           PERCENTAGE = 0
               TEXT       = 'Adding Data to Excel...'
           EXCEPTIONS
                OTHERS     = 1.
    * Get the list of workbooks
      V_STEP = 'Preaparing Excel'.
      CALL METHOD OF H_EXCEL 'WORKBOOKS' = H_WORK.
      PERFORM ERR_HDL.
    ** Add new workbook (create a file)
      CALL METHOD OF H_WORK 'ADD'.
      PERFORM ERR_HDL.
    * Get the created worksheet
    ************************Sheet Number
      CALL METHOD OF H_EXCEL 'WORKSHEETS' = H_SHEET EXPORTING #1 = 3.
    ************************Sheet Number
      PERFORM ERR_HDL.
    * Activate (select) the first sheet
      CALL METHOD OF H_SHEET 'ACTIVATE'.
      PERFORM ERR_HDL.
    * tell user what is going on
      CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR'
         EXPORTING
    *           PERCENTAGE = 0
               TEXT       = 'Adding Data to Excel...'
           EXCEPTIONS
                OTHERS     = 1.
    * output column headings to active Excel sheet
      V_STEP = 'Adding data to Excel'.
      LOOP AT ITAB.
        V_COL = SY-TABIX.
        PERFORM FILL_CELL USING 1 V_COL ITAB-vbeln.
        PERFORM FILL_CELL USING 2 V_COL ITAB-posnr.
      ENDLOOP.
      V_STEP = 'Releasing Excel'.
      FREE OBJECT H_EXCEL.
      PERFORM ERR_HDL.
      H_EXCEL-HANDLE = -1.
    *&      Form  ERR_HDL
    *       text
    *  -->  p1        text
    FORM ERR_HDL.
      IF SY-SUBRC <> 0.
        WRITE: / 'Error in processing Excel File:', V_STEP.
        STOP.
      ENDIF.
    ENDFORM.                    " ERR_HDL
    *&      Form  FILL_CELL
    *       text
    *      -->P_1      text
    *      -->P_1      text
    *      -->P_1      text
    FORM FILL_CELL USING  ROW COL VAL.
      CALL METHOD OF H_EXCEL 'Cells' = H_CELL
                     EXPORTING #1 = ROW #2 = COL.
      PERFORM ERR_HDL.
      SET PROPERTY OF H_CELL 'Value' = VAL .
      PERFORM ERR_HDL.
    ENDFORM.                    " FILL_CELL
    regards
    satesh

  • Problem when exporting Query from Web template to Excel Sheet.

    Hello,
    Im encoutering a problem when im trying to export query output from web template to excel sheet.
    A popup windown appears when excel sheet opens which reads.."problem cameup in the following areas during  load : Cell Value".The report layout appears to be fine but the totals shows unwanted values starting with * followed by number.
    Any valuable inputs, what could be the problem. where can i rectify the same.
    Regards
    Ellora

    Hello A K,
    Thanks for ur time and response but the option u mentioned did not serve my purpose.
    The problem seems to be only with pirticular cells.As mentioned earlier the layout appears properly..all the values are seen..but the end result..totals are disturbed.
    eg: If the report shows in template the total value :20,668,554...when exported the values is shown as **668553.88000000600000.
    So what could be the problem ? any template setting ? global setting to look at ?
    Regards
    Ellora

Maybe you are looking for

  • Quantity is not coming in output delivery docuemnt VL71

    Hi Gurus, We have created delivery docuemnt VL01n in that batch split exist indicator is there for the line item. When I print the delivery document quantity of the items shows 0 Kindly suggest why this quantity is not coming in VL71 docuemnt Thanks

  • [Solved] Conky - On Top

    Is it possible to set up conky to be on top of every other application that is running like this? I tried many scripts, but when I opened firefox, everything was covered with it's window. Thank's. Last edited by dudko (2010-11-04 09:14:48)

  • Where can I download 7.4.2 firmware for my Simultaneous Dual Band II AE

    After upgraded to the latest firmware, the time machine disconnect randomly, so does my NAS' file shareing. As other topic says, I want to downgrade my AE to 7.4.2. I remember days before upgrading firmware, everything's well. I can't find any downlo

  • IWork 09 Stabilizing feature

    hey i am looking at iWork 09 but have a question does the Stabilizing feature in iMovie remove the unwatchable sections of the movie or does it stabilize them, i know the name suggest it stabilizes it but i fear that it really means it gets rid of un

  • Wired Network and a Wireless Mac

    I currently have a PC and Mac Mini hooked up to a D-Link DI-604 wired network and am considering purchasing an iBook that I would like to go wireless with. Of course, right now my internet connection comes off my cable modem and into my router and I