Download data to Excel- very urgent pls help

Hi  Experts
Following is my coding. i need to download and save the it_material table as Excel file.
pls help me out
REPORT zvio1001 LINE-SIZE 190
           LINE-COUNT 55
           MESSAGE-ID zz
           NO STANDARD PAGE HEADING.
TABLES: mara,marce,makt,marc,mvke,zmpkg,t005t,cdhdr.
DATA : BEGIN OF it_mara OCCURS 0,
         mandt LIKE mara-mandt,          "Client
         matnr LIKE mara-matnr,
         meins LIKE mara-meins,
         laeda LIKE mara-laeda,
         aenam LIKE mara-aenam,
       END OF it_mara.
DATA : BEGIN OF it_marc OCCURS 0,
       matnr LIKE marc-matnr,
       werks LIKE marc-werks,
       END OF it_marc.
DATA : BEGIN OF it_makt OCCURS 0,
       matnr LIKE makt-matnr,
       maktx LIKE makt-maktx,
       END OF it_makt.
DATA : BEGIN OF it_zmpkg OCCURS 0,
       matnr LIKE makt-matnr,
       zppqt LIKE zmpkg-zppqt,
       zspqt LIKE zmpkg-zspqt,
       zpmqt_3 LIKE zmpkg-zpmqt_3,
       END OF it_zmpkg .
DATA : BEGIN OF it_material OCCURS 0,
         mandt LIKE mara-mandt,          "Client
         werks LIKE marc-werks,
         matnr LIKE marc-matnr,
         maktx LIKE makt-maktx,
         meins LIKE mara-meins,
         zppqt LIKE zmpkg-zppqt,
         zspqt LIKE zmpkg-zspqt,
         zpmqt_3 LIKE zmpkg-zpmqt_3,
         laeda LIKE mara-laeda,
         aenam LIKE mara-aenam,
         date LIKE sy-datum,
         time LIKE sy-uzeit,
         user    LIKE sy-uname,
       END OF it_material.
P a r a m e t e r s                                                 *
Start of tabbed screens
SELECTION-SCREEN BEGIN OF TABBED BLOCK list FOR 20 LINES.
SELECTION-SCREEN TAB (30) gc_gen USER-COMMAND gen_tab
                                    DEFAULT SCREEN 1001.
SELECTION-SCREEN TAB (30) gc_view  USER-COMMAND view_tab
                                    DEFAULT SCREEN 1002.
SELECTION-SCREEN TAB (30) gc_outp  USER-COMMAND outp_tab
                                    DEFAULT SCREEN 1003.
SELECTION-SCREEN END OF BLOCK list.
SELECTION-SCREEN BEGIN OF SCREEN 1001 AS SUBSCREEN.
SELECTION-SCREEN BEGIN OF BLOCK box01 WITH FRAME TITLE text-401.
PARAMETERS : p_werks LIKE marc-werks OBLIGATORY.
PARAMETERS : p_vkorg LIKE mvke-vkorg OBLIGATORY.
SELECT-OPTIONS : s_matnr FOR mara-matnr.
SELECT-OPTIONS : s_mtart FOR mara-mtart.
SELECT-OPTIONS : s_mmsta FOR marc-mmsta.                           "A01
SELECT-OPTIONS : s_dispo FOR marc-dispo.
SELECT-OPTIONS : s_beskz FOR marc-beskz.
SELECT-OPTIONS : s_lgpro FOR marc-lgpro.
SELECT-OPTIONS : s_lgfsb FOR marc-lgfsb.
SELECTION-SCREEN SKIP.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(31) text-014.
PARAMETERS : p_repall RADIOBUTTON GROUP sel2 DEFAULT 'X'.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(31) text-011.
PARAMETERS : p_change  RADIOBUTTON GROUP sel2.
SELECTION-SCREEN COMMENT 36(1) text-013.
PARAMETERS : p_chgdat LIKE sy-datum DEFAULT sy-datum.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN SKIP.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(31) text-010.
PARAMETERS : p_excdel AS CHECKBOX DEFAULT 'X'.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END   OF BLOCK box01.
SELECTION-SCREEN END OF SCREEN 1001.
View Selection Screen
SELECTION-SCREEN BEGIN OF SCREEN 1002 AS SUBSCREEN.
SELECTION-SCREEN BEGIN OF BLOCK box05 WITH FRAME TITLE text-403.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(77) text-109.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(31) text-021.
PARAMETERS: p_sales AS CHECKBOX DEFAULT 'X'.
SELECTION-SCREEN COMMENT 38(20) text-022.
PARAMETERS: p_mrp  AS CHECKBOX DEFAULT 'X'.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(31) text-023.
PARAMETERS: p_store AS CHECKBOX DEFAULT 'X'.
SELECTION-SCREEN COMMENT 38(20) text-024.
PARAMETERS: p_accnt AS CHECKBOX DEFAULT 'X'.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(31) text-025.
PARAMETERS: p_cost  AS CHECKBOX DEFAULT 'X'.
SELECTION-SCREEN COMMENT 38(20) text-026.
PARAMETERS: p_purch AS CHECKBOX DEFAULT 'X'.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END   OF BLOCK box05.
SELECTION-SCREEN END OF SCREEN 1002.
SELECTION-SCREEN BEGIN OF SCREEN 1003 AS SUBSCREEN.
extract format selection
SELECTION-SCREEN BEGIN OF BLOCK box04 WITH FRAME TITLE text-402.
PARAMETERS : p_vari LIKE ltdxt-variant OBLIGATORY.
SELECTION-SCREEN SKIP.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(31) text-009.
PARAMETERS: p_report RADIOBUTTON GROUP sel1 DEFAULT 'X'.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(31) text-016.
PARAMETERS : p_repcoo RADIOBUTTON GROUP sel1.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(31) text-017.
PARAMETERS : p_reppak RADIOBUTTON GROUP sel1.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN SKIP.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(31) text-008.
PARAMETERS: p_extun RADIOBUTTON GROUP sel1.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN SKIP.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(31) text-007.
PARAMETERS: p_extpc RADIOBUTTON GROUP sel1.
SELECTION-SCREEN END OF LINE.
PARAMETERS: p_pcfile LIKE rlgrap-filename
           DEFAULT 'c:\#ups\CLIENTIDCCYYMMDDHHMMSS.ITM'.
            DEFAULT 'd:\P0121205MMM_YYYYMMDD HHMMSS.XLS'.
SELECTION-SCREEN BEGIN OF LINE.
SELECTION-SCREEN COMMENT 1(40) text-015.
SELECTION-SCREEN END OF LINE.
SELECTION-SCREEN END   OF BLOCK box04.
SELECTION-SCREEN END OF SCREEN 1003.
F i e l d   S y m b o l s                                           *
FIELD-SYMBOLS: <f>.
D a t a                                                             *
common include for file layouts
INCLUDE zvin1010.
AT SELECTION-SCREEN OUTPUT.
  LOOP AT SCREEN.
    IF screen-name = 'P_PCFILE'.
      screen-input = 0.
      MODIFY SCREEN.
    ENDIF.
  ENDLOOP.
                 I N I T I A L I Z A T I O N                         *
INITIALIZATION.
  gc_gen   = text-401.
  gc_outp  = text-402.
  gc_view  = text-403.
SET up the file directory depending on the system id.
  GET PARAMETER ID 'WRK' FIELD p_werks.
  GET PARAMETER ID 'VKO' FIELD p_vkorg.
  CLEAR s_mtart.
  s_mtart-sign   = 'E'.
  s_mtart-option = 'EQ'.
  s_mtart-low    = 'ROH'.
  s_mtart-high   =  ''.
  APPEND s_mtart.
  CLEAR s_mtart.
  s_mtart-sign   = 'E'.
  s_mtart-option = 'EQ'.
  s_mtart-low    = 'MFPK'.
  s_mtart-high   =  ''.
  APPEND s_mtart.
  CLEAR s_mtart.
  s_mtart-sign   = 'E'.
  s_mtart-option = 'EQ'.
  s_mtart-low    = 'VERP'.
  s_mtart-high   =  ''.
  APPEND s_mtart.
START-OF-SELECTION.
check that the download is active
PERFORM get_data.
*&      Form  GET_DATA
      text
-->  p1        text
<--  p2        text
FORM get_data .
SELECT   mandt matnr meins laeda aenam
FROM mara
INTO TABLE it_mara
WHERE matnr IN s_matnr.
IF NOT it_mara[] IS INITIAL.
SELECT matnr werks
FROM marc
INTO TABLE it_marc
FOR ALL ENTRIES IN it_mara
WHERE matnr = it_mara-matnr
AND werks = p_werks.
SELECT matnr maktx
FROM makt
INTO TABLE it_makt
FOR ALL ENTRIES IN it_marc
WHERE matnr = it_marc-matnr
AND spras = 'E'.
SELECT matnr zppqt  zspqt zpmqt_3
   INTO TABLE    it_zmpkg
   FROM zmpkg
   FOR ALL ENTRIES IN it_marc
WHERE matnr = it_marc-matnr
AND  werks = p_werks.
ENDIF.
LOOP AT it_mara.
READ TABLE it_marc WITH KEY matnr = it_mara-matnr.
IF sy-subrc EQ 0.
READ TABLE it_makt WITH KEY matnr = it_mara-matnr.
IF sy-subrc EQ 0.
READ TABLE it_zmpkg WITH KEY matnr = it_mara-matnr.
IF sy-subrc EQ 0.
it_material-mandt = it_mara-mandt.
it_material-matnr = it_mara-matnr.
it_material-maktx = it_makt-maktx.
it_material-meins = it_mara-meins.
it_material-laeda = it_mara-laeda.
it_material-aenam = it_mara-aenam.
it_material-werks = it_marc-werks.
it_material-zppqt = it_zmpkg-zppqt.
it_material-zspqt = it_zmpkg-zspqt.
it_material-zpmqt_3 = it_zmpkg-zpmqt_3.
it_material-date = sy-datum.
it_material-time = sy-uzeit.
it_material-user = sy-uname.
APPEND it_material.
ENDIF.
ENDIF.
ENDIF.
ENDLOOP.
ENDFORM.                    " GET_DATA

Hi Kumar,
     After building your it_material internal table, try using GUIO_DOWNLOAD to load the data into an excel sheet.
check this sample code.
  CALL FUNCTION 'GUI_DOWNLOAD'
    EXPORTING
      FILENAME                = SELECT_FILE   " Filename
      FILETYPE                = 'ASC'
      APPEND                  = ' '
    TABLES
      DATA_TAB                = ITAB_STR_1
    EXCEPTIONS
      FILE_WRITE_ERROR        = 1
      NO_BATCH                = 2
      GUI_REFUSE_FILETRANSFER = 3
      INVALID_TYPE            = 4
      NO_AUTHORITY            = 5
      UNKNOWN_ERROR           = 6
      HEADER_NOT_ALLOWED      = 7
      SEPARATOR_NOT_ALLOWED   = 8
      FILESIZE_NOT_ALLOWED    = 9
      HEADER_TOO_LONG         = 10
      DP_ERROR_CREATE         = 11
      DP_ERROR_SEND           = 12
      DP_ERROR_WRITE          = 13
      UNKNOWN_DP_ERROR        = 14
      ACCESS_DENIED           = 15
      DP_OUT_OF_MEMORY        = 16
      DISK_FULL               = 17
      DP_TIMEOUT              = 18
      FILE_NOT_FOUND          = 19
      DATAPROVIDER_EXCEPTION  = 20
      CONTROL_FLUSH_ERROR     = 21
      OTHERS                  = 22.
  IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    EXIT.
  ENDIF.
Hope this is helpful to you. If you need further information, revert back.
Reward all the helpful answers.
Regards
Nagaraj T

Similar Messages

  • Very urgent --pls help Report Painter Problem,

    Hi to all,
    I have created  5 operating expenses report by cost centres through report painter. some for full period , some for actual and sone for budget.
    Under one set of that cost centre reports I have many subsets under which there are cost centre groups and then the cost centres.
    I want to add one more set to existing set. I have added the set and set contains one cost centre group and their are also cost centres under it.
    The table  which i am using for cost centre grous is GLT1 and field is RCNTR and for cost centres it is CCSS and KOSTL respectively.
    In the above procedure I have two queries.
    1)even after adding the set and when i try to execute the report from T- code SERP it doesnot show my created set in variation.
    2)Also even if it was showing the set earlier but report was showing zero values. When i clicked on zero amount a pop up arises for plan and actual values and when i clicked on plan values it had value of Rs 255000(for cost centres). then outside why this amount doesnot appears.
    PLS THIS IS VERY VERY URGENT
    Regards
    TANUJA

    I've just read this thread three times and I have absolutely no idea what you are doing, in what version, and what you are asking for help with.
    Do you want to change the message type? If you do you MUST drop the queue and start over again from the beginning.
    Do you want to enqueue messages?
    Post your DDL and other relevant information or you are on your own. We can not guess at your issue.

  • Problem on loading applet netscape4.73 in macos9 very urgent pls help me

    Hello,
    Problems on loading applet in Netscape4.73(jre1.1.5) AppleMac OS-9.
    when i try to load applet of size ~ 200kb in Netscape 4.73 AppleMac os9, then browser abruptly closing with the AppleMac os error message :- the Applicarion " Netscape Communicator " has unexpectedly quit because an error of type 2 occured. And then asking for system restart.
    Since i am new to the AppleMac environment i cant adjust the settings please help me to overcome the problem. Its Very urgent and i am in great hurry pls.
    thanks in advance.
    Rao. V.N.

    Hi Rao,
    I'm not a mac-os specialist (even I had some business with mac !!), and it is very difficult speaking in blind, but I have severals questions that may help you.
    - Did you try you applet in other AppleMac plateform ?
    - Does your applet work fine in other browser/plateform ?
    - Does a small applet work fine on this plateform with this browser ?
    - Does you applet contains instructions like System.exit, System.* or try to access (read or write) to local files ?
    Otherelse it is possible you have problem with your jre config, try to configure your plugin with command like : -Xmx64m -Xms16m
    (These commands tell the plugin to use at least 16 Mo memory and 64 Mo for the maximum see : http://java.sun.com/docs/hotspot/gc/)
    Hope that will help you

  • Very  Urgent Pls  help :  Change of  payload type to  user-defined types

    Hello Experts
    I was using sys.xml_type as payload type in my queue table creation.
    consider xml message
    <order>
    <id>1</id>
    <load rerer="mq" erere='gg" > </load>
    </order>
    This i inserted into queue table using enqueue process.
    this is done.
    BUT NOW My manager wants to change the payload type.
    he created a type
    create or replace type systype as object (msg varchar2(4000));
    Now payload type of queue table is changed to
    PayloadType==>aq.systype.
    Pls help me how can i insert xml messages into this queue table.
    This is very urgent. Pls help me
    S

    I've just read this thread three times and I have absolutely no idea what you are doing, in what version, and what you are asking for help with.
    Do you want to change the message type? If you do you MUST drop the queue and start over again from the beginning.
    Do you want to enqueue messages?
    Post your DDL and other relevant information or you are on your own. We can not guess at your issue.

  • Hi guys (very urgent pls help me out)

    i have an doubt that iam using JBoss AS, my scienraio is
    inital when start my Application Server it will connects to mysql DB datasource, i will retrieve some values those are DB Names like oracle,sql server,db2 etc in my JSP page iam placed at combo box upto this i am very much successful but now my problem is after gettinh those values in html select box.
    if user selects Oracle and in the same screen user can enter connection config details and after submitting the request. At runtime App Server want to connect for that particular Database.
    for ex Oracle and its connection parameters then it want to connect that particular Database without restarting the server.
    so mysql is internal DB and Oracle is external db. how to manage this scienraio
    please anyone knows solution, pls help me out......
    regards
    Yadav

    hi
    the message is very clear that the sold to party ur refering is not from the same sales area. if u have the customer already then extend the same to the said sales area, by common division and distribution channel
    <b>reward points</b>
    Regards

  • Select statement- very urgent pls help

    hi
    i want to extract following fields into one internal table.
    anyone pls help me to do this?
      mara-mandt, mara-matnr, mara-meins, mara-laeda, mara-aenam, marc-werks, makt-maktx, sy-datum, sy-uzeit, sy-uname
    Thanks
    Kumar

    Hi Kumar K,
    TABLES: MARA, MARC, MAKT.
    SELECT-OPTIONS: S_MATNR FOR MARA-MATNR.
    PARAMETERS : P_WERKS LIKE MARC-WERKS  OBLIGATORY.
    DATA :      BEGIN OF WA_FINAL,
         MANDT LIKE MARA-MANDT,
         MATNR LIKE MARA-MATNR,
         MEINS LIKE MARA-MEINS,
         LAEDA LIKE MARA-LAEDA,
         AENAM LIKE MARA-AENAM,
         WERKS LIKE MARC-WERKS,
         MAKTX LIKE MAKT-MAKTX,
    DATE TYPE SY-DATUM,
    TIME TYPE SY-UZEIT,
    UNAME TYPE SY-UNAME,
         END OF WA_FINAL,
         BEGIN OF WA_MARA,
         MANDT LIKE MARA-MANDT,
         MATNR LIKE MARA-MATNR,
         MEINS LIKE MARA-MEINS,
         LAEDA LIKE MARA-LAEDA,
         AENAM LIKE MARA-AENAM,
         END OF WA_MARA,
         BEGIN OF WA_MAKT,
         MATNR LIKE MAKT-MATNR,
         MAKTX LIKE MAKT-MAKTX,
         END OF WA_MAKT,
         BEGIN OF WA_MARC,
         MATNR LIKE MARC-MATNR,
         WERKS LIKE MARC-WERKS,
         END OF WA_MARC.
    DATA : IT_MARA LIKE STANDARD TABLE OF WA_MARA WITH HEADER LINE,
    IT_FINAL LIKE STANDARD TABLE OF WA_FINAL WITH HEADER LINE,
    IT_MAKT LIKE STANDARD TABLE OF WA_MAKT WITH HEADER LINE,
    IT_MARC LIKE STANDARD TABLE OF WA_MARC WITH HEADER LINE.
    SELECT   MANDT
         MATNR
         MEINS
         LAEDA
         AENAM
    FROM MARA
    INTO TABLE IT_MARA
    WHERE MATNR IN S_MATNR.
    IF IT_MARA[] IS NOT INITIAL.
    SELECT MATNR
    WERKS
    FROM MARC
    INTO TABLE IT_MARC
    FOR ALL ENTRIES IN IT_MARA
    WHERE MATNR = IT_MARA-MATNR
    AND WERKS = P_WERKS.
    ENDIF.
    IF IT_MARA[] IS NOT INITIAL.
    SELECT MATNR
                 MAKTX
    FROM MAKT
    INTO TABLE IT_MAKT
    FOR ALL ENTRIES IN IT_MARA
    WHERE MATNR = IT_MARA-MATNR.
    ENDIF.
    LOOP AT IT_MARA.
    IT_FINAL-MANDT = IT_MARA-MANDT.
    IT_FINAL-MATNR = IT_MARA-MATNR.
    IT_FINAL-MEINS = IT_MARA-MEINS.
    IT_FINAL-LAEDA = IT_MARA-LAEDA.
    IT_FINAL-AENAM = IT_MARA-AENAM.
    READ TABLE IT_MARC WITH KEY MATNR = IT_MARA-MATNR.
    IF SY-SUBRC = 0.
    IT_FINAL-WERKS = IT_MARC-WERKS.
    ENDIF.
    READ TABLE IT_MAKT WITH KEY MATNR = IT_MARA-MATNR.
    IF SY-SUBRC = 0.
    IT_FINAL-MAKTX = IT_MAKT-MAKTX.
    ENDIF.
    IT_FINAL-DATE = SY-DATUM.
    IT_FINAL-TIME = SY-UZEIT.
    IT_FINAL-UNAME = SY-UNAME.
    APPEND IT_FINAL.
    CLEAR : IT_FINAL, IT_MARA , IT_MAKT, IT_MARC.
    ENDLOOP.
    now IT_FINAL table contains the final data which you want...
    Hope it will solve your problem
    Reward points if useful...
    Thanks & Regards
    ilesh 24x7

  • Read textfile in JSP (Very urgent� Pls Help)

    Hi to all,
    I have a very urgent problem. I need a JSP to read a textfile (c:\abc.txt).and display in it to a space <in a body tag> in a HTML page. Does anyone have any idea? Thanks in advance.
    This is my HTML page.
    <html>
    <head>
    <meta http-equiv="Content-Language" content="en-us">
    <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
    <meta name="GENERATOR" content="Microsoft FrontPage 4.0">
    <meta name="ProgId" content="FrontPage.Editor.Document">
    <title>Display</title>
    </head>
    <body>
    <p>Text to display:</p>
    </body>
    </html>

    Usually, I would prefer to put the jsp code scriplets at the beginning if its purpose is to generate a string....
    <%@ page contentType="text/html"
    import="java.io.*, java.util.*" %>
    <%
      String fileName = "c:\\abc.txt" ;
      BufferedReader br = new BufferedReader(new FileReader(fileName));
      String line = br.readLine() ;
      while ( line != null )
          out.write(line + "<br>");
          line = br.readLine() ;
      br.close();
    %>
    <html>
    <head><title>JSP Page</title></head>
    <body>
    <p>
    <%= line%>
    </p>
    </body>
    </html>

  • Very URGENT: PLS HELP:canno resolve symbol session.setAttrribute

    hi everbody,
    i'm new at this and have got a presentation after 1 day!....pls help
    when i compile the servlet i get :
    cannot resolve symbol
    metod: setAttribute (java.lang.String,java.lang.String)
    location: interface(javax.servlet.http.HttpSession)
    the servlet that gets te error when comiled is:
    * Authenticate.java
    // this places all user variables in session
    //to access use session.getAttribute
    //dispatcher stuff
    import javax.servlet.*;
    import javax.servlet.http.*;
    import javax.servlet.http.HttpSession;
    import javax.servlet.http.HttpServlet;
    import javax.servlet.ServletConfig;
    import javax.servlet.ServletContext;
    import javax.servlet.ServletException;
    import java.sql.*;
    import java.io.*;
    import java.util.*;
    * @author Gudiya
    * @version
    public class Authenticate extends HttpServlet {
    public void doPost(HttpServletRequest request, HttpServletResponse response)
    throws ServletException, java.io.IOException {
    HttpSession session = request.getSession(true);
    Connection con=null;
    String sessionid;
    String deptcode;
    String desig;
    String add1;
    String add2;
    String contname;
    PrintWriter out = response.getWriter();
    try
    response.setContentType("text/html");
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    con=DriverManager.getConnection("jdbc:odbc:SACFA","","");
    System.out.println("connection established");
    catch(ClassNotFoundException e){
    System.out.println("database driver not found");
    System.out.println(e.toString());
    catch(Exception e){System.out.println(e.toString());
    // ServletContext context=getServletContext();
    String username=request.getParameter("username");
    String password=request.getParameter("password");
    try{
    PreparedStatement stmt=con.prepareStatement("SELECT * FROM AUTHENTICATION,mb_add where AUTHENTICATION.NAME=? AND AUTHENTICATION.PASSWORD=? AND mb_add.DEPT_NAME=?");
    stmt.setString(1,username);
    stmt.setString(2,password);
    stmt.setString(3,username);
    ResultSet rs=stmt.executeQuery();
    boolean rowfound=false;
    rowfound=rs.next();
    if (rowfound==true)
    sessionid=session.getId();
    System.out.println(sessionid);
    //context.setAttribute("userid",sessionid);
    // session.setAttribute("user",username);
    rs.beforeFirst();
    while (rs.next())
    deptcode=rs.getString("DEPT_CODE");
    desig=rs.getString("DESIGNATION");
    add1=rs.getString("ADDRESS1");
    add2=rs.getString("ADDRESS2");
    contname=rs.getString("NAME");
    session.setAttribute("dept_code",deptcode);
    session.setAttribute("designation",desig);
    session.setAttribute("address1",add1);
    session.setAttribute("address2",add2);
    session.setAttribute("cont_name",contname);
    //context.getRequestDispatcher(request.getParameter("dispatcho")).forward(request,response);
    }          out.println("<html>");
              out.println("<head>");
              out.println("<title>Successful Login Screen</title>");
              out.println("</head>");
              out.println("<body bgcolor='ORANGE'>");
    out.println("<script language='Javascript'>");
    out.println("<!--function send_onclick(mydispatcho) {var dispatcho;if(mydispatcho=='Noc'){ dispatcho='/Noc1';}if(mydispatcho=='Ce'){ dispatcho='/Ce1';} if(mydispatcho=='Bye'){ dispatcho='/Bye1';}}-->");
    out.println("</script>");
    out.println("WELCOME MEMBERS FROM "+ username);
    //print decorative html statements here
              out.println(" SELECT NY ONE ACTION:-");
    out.println("<form Action="+"\"servlet/noc\""+" method =post>");//call for your noc servlet
    //print decorative html statements here
    out.println("<INPUT TYPE=submit VALUE='GENERATE NOC' NAME='NOC' language='javascript'>");
    out.println("</form>");
    //print decorative html statements here
    out.println("<form Action="+"\"servlet/comments\""+" method =post>");//call for your comment servlet
    out.println("<INPUT TYPE=submit VALUE='ENTER/ MODIFY COMMENTS' NAME='COMMENTS' language='javascript' >");
    out.println("</form>");
    //print decorative html statements here
    out.println("<form Action="+"\"servlet/bye\""+" method = post>");
    out.println("<INPUT TYPE=submit VALUE=EXIT NAME=EXIT language='javascript' >"); //place javascript fucction for exiting window
    out.println("</form>");
              out.println("</body>");
              out.println("</html>");
    con.close();
    } catch( SQLException e){ }
    out.close();}
    NOTE: I'M USING JDK1.3 and jsdk2.0
    pls help me....
    Thank u all,
    ashna

    HTTP Status 404 - /mywork/servlet/Authenticate
    hi dheeraj,
    thank u so much the servlet comiled!!!
    now i have a new problem....the Tomcat server cannot find its class file. i have placed the class file in C:\Program Files\Apache Group\Tomcat 4.1\webapps\mywork\WEB-INF\classes.
    the error it shows is as follows:
    type Status report
    message /mywork/servlet/Authenticate
    description The requested resource (/mywork/servlet/Authenticate) is not available.
    Apache Tomcat/4.1.18-LE-jdk14
    PLEASE HELP!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!11

  • Concatenating multiple rows in a table - Very urgent - pls help

    Can someone please help me out in writing the Sql to concatenate the Text_desc
    for each code for all the seq_nos in the ascending order of seq_no and load into the target table(T1). Please see the sample data below in the Source(S1) and the expected result in the target(T1). There are about 2,30,000 records in S1 and the seq_no can be anything.
    Source table : S1
    Code Seq_no Text_desc
    1579 0 BCN5, CO20, ER75
    1579 1 FP5, WC6, MATW, OPRH
    1579 2 T
    1600 0 TW, FP5, AS5, MHSA15, DME20
    1600 1 ER100, UR40
    Target table: T1
    Text_desc (concatenate all the strings for each code in ascending order of seq_no)
    code Text_desc
    1579 BCN5, CO20, ER75FP5, WC6, MATW, OPRHT
    1600 TW, FP5, AS5, MHSA15, DME20ER100, UR40
    Thanks in advance,
    Maddy

    untested
    rem ==============================================
    create or replace
    function f_text (p_code number) return varchar2 is
       l_text varchar2(2000) ;
    begin
       for i_rec in 'select text_desc from S1 where code = p_code order by code'
       loop
           l_text := l_text || i_rec.text_desc || ',' ;
       end loop ;
       l_text := rtrim(l_text,',') ;
       return l_text;
    end ;
    rem ==============================================
    insert into T1
       select CODE, f_text (CODE) TEXT
         from
             (select distinct CODE from S1)
    rem ==============================================
    Message was edited by:
            ruhr0001                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Very Urgent pls help me

    Hi
    in sap script in data fiels is
    &komvd-kbetr(T10.2)&/M  my output for this field is 2500.00 /M
    I need to remove the space b/w 2500.00 and /M. I tried all the methods using (C). it is not working.
    i just changed the decimal place to &komvd-kbetr(T7.2)&/M it is working fine. But this is wrong. Anybody give me the sollution.
    Useful points will be reward soon
    Thanks
    Kumar

    Hi Kumar
    You can use condense as
    DATA: BEGIN OF sentence,
            word1(30) TYPE c VALUE 'She',
            word2(30) TYPE c VALUE 'feeds',
            word3(30) TYPE c VALUE 'you',
            word4(30) TYPE c VALUE 'tea',
            word5(30) TYPE c VALUE 'and',
            word6(30) TYPE c VALUE 'oranges',
          END OF sentence,
          text TYPE string.
    text = sentence.
    CONDENSE text.
    Reward points if helpful
    Hitesh

  • Cfgrid error -very urgent, pls help

    Hi all,
           I am working on a cfgrid to populate records and also there is a search button used for searching too. But when I enter a keyword and click search,
    grid will show correct records needed. But if I clicked 3 or 4 times search button after entering keyword, an error comes as follows "CFGRID: Response is empty [Enable debugging by adding 'cfdebug' to your URL parameters to see more information]" .From application.log, I got this error mesage - The row number 0 is out of bounds. The specific sequence of files included or processed is:
    What is the problem actually ?
    When search button clicked, I am using Coldfusion.Grid.refresh to bind the grid.. and also I am fetching records from a text file, which contains about 3000 records.
    And also when I tested this with 15 records in a text file, this error is not coming...
    Atleast can you provide any mechanism to hide the error..
    I have tried try catch method, but failed to catch the error...
    Please help...

    I've just read this thread three times and I have absolutely no idea what you are doing, in what version, and what you are asking for help with.
    Do you want to change the message type? If you do you MUST drop the queue and start over again from the beginning.
    Do you want to enqueue messages?
    Post your DDL and other relevant information or you are on your own. We can not guess at your issue.

  • Textfile Problem (Very Urgent, Pls Help...)

    hi to all,
    I have a servlet that executes a program and then write the results to a textfile.
    Question 1: How do I know that the textfile is not empty?
    Question 2: If the textfile contains somethings, how can I append a sentence(That's all) all the last line of the textfile?
    Thanx in advance!!!!

    Question 1: How do I know that the textfile is not
    empty?try the java.io.File.length() method.
    Question 2: If the textfile contains somethings, how
    can I append a sentence(That's all) all the last line
    of the textfile?use a java.io.FileWriter, it supports appending data to a file.
    Jasper.

  • Very very urgent pls help me!!!

    I have installed oracle 10g client in my computer running windows xp professional.
    i am really having problem with username,password and hoststring.
    Please help me out with this details
    regards
    madhu.

    The idea is always: what is the mechanism to get from here to the 'database server computer', to ask the listener on that computer for a connection to a specific database.
    Oracle mainly uses Oracle Networking or JDBC URL to connect.
    Oracle Networking has several connection 'styles', largely as configured using the SQLNET.ORA file or it's defaults.
    - host
    If there is only one database on the host, then the connection string can be the DNS-resolvable host name. No port or database information is required as the port is assumed to be 1521 and the database is 'the only one there'
    - service
    This is the name of the service to be extracted from the TNSNAMES.ORA file, LDAP server using Oracle's LDAP (or Oracle Names server). The service name is simply an alias used to look up the correct host name, port, database (or other) service and options.
    - EZ Connect URL
    This is a URL form available with 10g client. Read the EZ Connect docco for that
    JDBC has 2 main styles:
    host:port:sid ... this is used in Raptor (localhost:1521:XE is what you would use)
    service ... this is the one you are familiar with

  • Problem in System object - Very urgent - Pls help

    Hi ,
    I have installed Portal version SP9 on windows with MS SQL server as database . I am experencing some
    issues during the system object creation for R3 . Below I will specify all the configuration I have done for
    system object creation ,
    1. I have selected the option Dedicated application server for R/3 system .
    2. Under th eproperty category , I have selected Connector and put the following values .
    Application Host  - 128.1.7.2
    Remote Host Type - Select -3
    SAP Client  - 120
    SAP System ID (SID)- DV1
    SAP System Number - 00
    System Type - SAP_R3
    Trace Mode - Select -01
    3 . Then Under the property category , Web Application server ( WAS ) I have selected
    the following properties .
    WAS hostname - 128.1.7.2
    Was Protocol - http
    4 . Next step I have selected the User Management and put the below details
    Logon Method - UIDPW
    usermapping type - admin ,user
    4. I have also created an alias and made it default
    6. Then I have gone to usermapping under the user administration and created the
    user mapping for the user .
    But when I have tested the system object , I am getting the following error .
    SAP Web AS Connection - Jan 1, 1970 8:17:25 AM
      Test Details:
    The test consists of the following steps:
    1. Check that the system object defines an SAP system
    2. Validate the following parameters: wap.WAS.protocol; wap.WAS.hostname
    3. Check the HTTP/S connection to the defined backend application
      Results
    1. The system object represents an SAP system.
    2. The following parameters are valid: wap.WAS.protocol (http) ; wap.WAS.hostname (128.1.7.2)
    3. HTTP/S connection failed. Make sure the protocol, host name, and user mapping are correctly defined.
    ITS Connection - Jan 1, 1970 8:17:25 AM
      Test Details:
    The test consists of the following steps:
    1. Check that the system object defines an SAP system
    2. Validate the following parameters: wap.ITS.path; wap.ITS.protocol; wap.ITS.hostname
    3. Check the HTTP/S connection to the defined backend application
      Results
    1. The system object represents an SAP system.
    2. The following parameters are not valid: wap.ITS.path () ; wap.ITS.protocol () ; wap.ITS.hostname ()
    I really dont know what is foing wrong . Do I need to omit the WAS details which I have mentioned in the step number 3 . What is the
    real use of this step ? Could any body guide me as this is quite urgent
    Thanks
    Aneez

    Hi,
      We have similar setup and having same userids in both R/3 (webas 6.40 based) as well as
    in EP 6.0, so we are not doing any user mapping as recommended. I hope i gave all necessary
    parameters under system object of categories user management with SAPLOGON, connector
    properties and also WAS properties with hostname and type as http. When i try to do test
    connection it is giving following error message:
    SAP Web AS Connection - 
      Test Details:
    The test consists of the following steps:
    1. Check that the system object defines an SAP system
    2. Validate the following parameters: wap.WAS.protocol; wap.WAS.hostname
    3. Check the HTTP/S connection to the defined backend application
      Results
    1. The system object represents an SAP system.
    2. The following parameters are valid: wap.WAS.protocol (http) ; wap.WAS.hostname (xxxxxxxx)
    3. HTTP/S connection failed. Make sure the protocol, host name, and user mapping are
    correctly defined.
    Test Connection with Connector - Jan 1, 1970 6:40:19 PM
      Test Details:
    The test consists of the following steps:
    1. Retrieve the default alias of the system
    2. Check the connection to the backend application using the connector defined in this
    system object
      Results
    Retrieval of default alias successful
    Connection successful
    Also when i try to do the testing of transaction from :
    System Adm.>Support.>SAP Application>SAP transaction>
    Select the system and Tcode and most important SAP GUI type = SAP GUI for Windows
    i am getting connection broken error.
    Let me know is there anything in specific which is missing.
    Thanks

  • Very Urgent-Pls help*Process chain triggered automatically when transported

    Hi All,
    We have got some issue.
    We have a Process chain, started set to immediate becuase its used in meta chain.
    When ever we transport the Chain, its getting triggerred in the Target Client automatically.
    We can prevent this, by keeping the process chain starter as "Event Based". But, as its a local process chain, it must be set to Immediate.
    Please help.
    Cheers,
    Nisha

    Hi Siggi,
    Thanks for this reply.
    Scheduling the Local chain to run in future and then changing it after import, i think, is a work around.
    Iam sure, there must be some thing to stop this trigger.
    And, We have tried Changing the Chains to run Via Meta chain, but, the problem is after the Transport, the local chain can't be triggered on its own using "immediatly". If we try to change it, it'll prompt for a Transport.
    Please help.
    Cheers,
    Nisha

Maybe you are looking for

  • Is suggest zero lines Check box available in MIGO

    Hi, In Schedule Agreement one line item and 3 Schedule lines In Schedule line 1 : del date 17/05/09   qty : 50 is open qty In Schedule line 2 : del date 19/05/09   qty : 30 is open qty In Schedule line 3 : del date 24/05/09   qty : 20 is open qty whe

  • How to give the Submit along with Variant

    Dear Freinds,            Iam using the Submit program with variant  in my custom program . When iam exucting my custom program it is directly opening the program with the variant . ie. just like we execute a program and select varaint. it is not happ

  • Can 2 separate Planning Servers be running on the same machine?

    Dear All, We are trying to setup Hyperion DEV and SIT environments into the same AIX server. We have Shared Services Essbase EAS APS Financial Reporting Planning Oracle Application Server 10g Oracle 10g DB We use 2 separate user accounts and differen

  • Voice command , how to generate the coefficien​ts and output as matrix

    Hello. I am trying to do a program that can tell"1.2.3.4"   I found a template on the internet,Firstly it generate the coefficients and output it to a Real Matrix  just like the following picture. However,I don't know how can I record my own coeffici

  • Expertmode not showing while extending EO based VO

    Hi, I am trying to extend the View Oject PoRequisitionLinesVO in R12, While extending the VO, Expert Mode check box is greyed out and I can't change the SQL query. Can you please help me how can i enable the Expert Mode check box. Thanks in Advance,