Total Records in a Table

I am new to the Oracle environment and I am trying to find a quick way to get the total number of records loaded into a table. Is there any command you can use to verify this? I know a log file can be created when loading a file, but I do not see a record count displayed in this file. Thank you in advance for your help.

Hi Melissa,
The simplest way to do this is to issue a SELECT statement on the table you have loaded. This can be achieved by issuing the following command:
SELECT COUNT(*) FROM table_name;
where the table_name is the name of the table you have just loaded.
Secondly, you can obtain the number of records loaded by turning your FEEDBACK parameter on before prior to loading. At the end of a successful load, the number of records created will be displayed, assuming that your are loading from one table to another.
For more info, please refere to the SQL*PLUS reference manual.
Thanks,
John
null

Similar Messages

  • To display total records in a table through Go URL

    Hi All,
    Can anyone give me the solution how to display all the records of a table through Go URL. Actually according to the documentation provided by the oracle or the stuff in the blogs, We can write Go URL to display all the records in a table in two methods.
    1) To change the properties of a table and use the basic Go URL.
    2) Adding Action=Scroll&P5=-1&ViewID=go~Table to the Go URL.
    First one is not a solution in our case, According to our scenario we should not change table properties because If we change the properties and display the whole records in one page... it will impact the performance.
    Coming to the second, we tried to append this part in the report Go URL. But It gave Assertion Failure Error.
    Anybody please provide a solution how to write a Go URL to get all the records in the table.

    Hi All,
    Can anyone give me the solution how to display all the records of a table through Go URL. Actually according to the documentation provided by the oracle or the stuff in the blogs, We can write Go URL to display all the records in a table in two methods.
    1) To change the properties of a table and use the basic Go URL.
    2) Adding Action=Scroll&P5=-1&ViewID=go~Table to the Go URL.
    First one is not a solution in our case, According to our scenario we should not change table properties because If we change the properties and display the whole records in one page... it will impact the performance.
    Coming to the second, we tried to append this part in the report Go URL. But It gave Assertion Failure Error.
    Anybody please provide a solution how to write a Go URL to get all the records in the table.

  • Count total records in 2 tables

    Hello,
    I am using this query
    select count(*) from table1, table2) to get the total number of records in those 2 tables. Actually I have only 7 records in both the tables, but I get 15. What could be the problem?
    Also I need to find out another query where in I can find out which table is giving a particular record. e.g table1 has firstname,lastname and table2 has firstman,lastman. I need to know that firstname has come from tabl1 and firstman has come from table2.
    Please help.
    Thanks

    Well, if I'm not misstaken the difference between
    UNION and UNION ALL is that UNION ALL will include
    duplicates while UNION will ignore the duplicates.The UNION clause forces all rows returned by each
    portion of the UNION to be sorted and merged and
    duplicates to be filtered before the first row is
    returned. A UNION ALL simply returns all rows
    including duplicates and does not have to perform any
    sort, merge or filter. It is much more efficient.
    (Although the performance factor may be irrelevant in
    the OP's situation - the issue of duplicate rows
    isn't)And what did I say?
    Asuming the OP does not have duplicates within each
    table (when he/she would really violate relational
    database theory) Why do you assume that? Why would this violate
    relational database theory?If you don't have a primary key, it sure does. I don't have my C J Date book here, but this looks like an accurate transcript of C F Codd's twelve rules a relational database must obay: http://engr.smu.edu/~fmoore/notes/12rules.htm Look at number 2...
    there will not be any difference between the twoUNION "versions".
    That is correct. I just didn't want to change that
    part of the code ( String s1 = rs.getString(2)...)
    since the OP asked about the database query.i wasn't referring to the OP, hence the 'ps' and 'for
    anyone doing this sort of thing in Oracle' and 'if you
    tend to use the column name version of getString()'
    Yes, you are again correct. I just explained why I wrote what I wrote.

  • How to update records in a table based on user selection..

    Hi all,
    This time the above doubt is totally based on the logic of coding which I tried a lot but didn't get any solution. so atlast I come to sdn site.
    please help..
    The requirement is like that I have a table with 6 fields (1 primary key and other are nonkeys). If the user inputs some values in the fields on the screen, then a row will be added in the table. Upto this i have done well. but when the user want to change some value  in the existing row of the table my program unable to do so. Because I couldn't get any logic to do that as there are 5 nonkey fields, so if any one field is modified then the respective row should be selected first based on the user selection and then it should be updated.
    At this point I could not get any idea as it may take a lots of if conditions (I guess) to reach to that particular row.
    Please help..
    thanks ,
    sekhar

    Hi Sekhar,
    I am afraid, the whole design of your program is wrong, let me explain
    Let us say you have two rows(5 non key fields) that the user wants to update and the data in these five non key fields are identical and in your program you are getting a number(which is the key) using a number range object. So you will have two entries in the table for the same data.
    And on the update page when the user enters the non key fields, how will the program know(or for that matter any one of us) which record to pick, if you have two identical books and if asked for a book wouldn't you ask which one among these two do you want?
    Possible Solution: Identify a possible key maintaining the integrity of the data, that is a combination of the non key fields which will help you identify a unique row and make these fields as key fields in the table.
    A more costly solution(if you do not want to change the non key field keys to key fields) would be to, adding a check(using select statement) to see if the non key fields combination already exists in the Z table before inserting a record into the table.
    If yes, throw a message to the user and just update the values in the table, else insert the record.
    Another solution would be to, use the non key fields to generate a key(using some logic) and using this instead of the number range object.
    regards,
    Chen

  • Unable to sort the records of a table

    Hi Experts,
    I have populated one z table with records. The table coloumns are as below:
    Mandt
    Pernr
    Personnel Area
    Total Points
    Rank
    I have to sort the table records in descending order of Total Points. In many cases there will be same total points for many records. In such cases we have to arrange records in following fashion:
    If more than 1 person have same total points then person having more years of service will have higher rank
    If more than 1 person have same total points and same years of service then older people (date of birth) will have higher rank.
    I have written following program. It is not working. Please help me. If you have some ready made code, please share with me.
    Regards,
    Gary
    IF NOT itab_prio[] IS INITIAL.
          CLEAR v_index.
          v_index = 1.
          SORT itab_prio BY z_prio_pts DESCENDING .
          itab_rank[] = itab_prio[].
          LOOP AT itab_prio.
    *---Check eligibility.
            CALL FUNCTION 'zmy_prg_CHECK_ELIGIBILITY'
              EXPORTING
                pernr  = itab_prio-z_pernr
              IMPORTING
                return = return.
            IF return-type = 'E'.
              itab_prio-z_prio_pts = 0.
              itab_prio-z_prio = 0.
              MODIFY itab_prio TRANSPORTING z_prio_pts z_prio.
            ELSE.
              LOOP AT itab_rank WHERE z_prio_pts = itab_prio-z_prio_pts
                                AND   z_pernr    NE itab_prio-z_pernr.
    *---Get Hiring date for same rank.
                CALL FUNCTION 'zmy_prg_GET_EMP_HIRING_DATE'
                  EXPORTING
                    pernr       = itab_rank-z_pernr
                  IMPORTING
                    hiring_date = hire_new.
    *---Get Hiring date of update emp.
                CALL FUNCTION 'zmy_prg_GET_EMP_HIRING_DATE'
                  EXPORTING
                    pernr       = itab_prio-z_pernr
                  IMPORTING
                    hiring_date = hire_old.
                IF hire_old = hire_new.
    *---Check for Birth date of both employees.
                  READ TABLE it_date WITH KEY  pernr = itab_rank-z_pernr.
                  IF sy-subrc = 0.
                    hijri_new = it_date-zzhdob.
                  ENDIF.
                  READ TABLE it_date WITH KEY  pernr = itab_prio-z_pernr.
                  IF sy-subrc = 0.
                    hijri_old = it_date-zzhdob.
                  ENDIF.
                  IF hijri_old > hijri_new.
                    flag = 'X'.
                  ENDIF.
                ENDIF.
              ENDLOOP.
              IF flag NE 'X'.
                itab_prio-z_prio = v_index.
                v_index = v_index + 1.
                MODIFY itab_prio TRANSPORTING z_prio.
              ELSE.
                itab_prio-z_prio = v_index.
                v_index = v_index + 1.
                MODIFY itab_prio TRANSPORTING z_prio.
              ENDIF.
            ENDIF.
            CLEAR : flag , return.
          ENDLOOP.
          MODIFY zhop_priority_pt FROM TABLE itab_prio.
          COMMIT WORK.
          IF sy-subrc = 0.
            MESSAGE i000(zz) WITH 'sucessfully generated'.
          ENDIF.
        ENDIF.
      ENDIF.
    ENDFORM.
    Please use code tags to format your code
    Edited by: Rob Burbank on Sep 29, 2010 1:59 PM

    Gary,
    Firstly, to make things easier, I suggest you add service and age columns to your internal table.
    Mandt
    Pernr
    Personnel Area
    Total Points
    Service
    Age
    Rank
    Does your internal table itab_prio contain large number of rows? Is the code that determines service and age performance intensive? If the answer is 'NO', then I suggest you populate service and age for every row and sort. This will make the logic simple and easy to maintain.
    If you must query service and age only when there is a conflict, then following logic should help.
    - itab_prio_copy[] = itab_prio[].
    - Loop at itab_prio.
    -   l_next_row = sy-tabix + 1.
    -   read table itab_prio_copy index l_next_row.
    -   are points same?
    -     get service for both the employees.
    -     is the service same for both?
    -       get age for both.
    -    rank accordingly
    - endloop.
    I know I have skipped a lot of gotcha points. For example, how to handle the last row, how to update the rank to the next row, etc. I am sure you can figure that out.
    Good luck.

  • Inserting records from internal table to database table

    Hi all,
    i want to insert records from internal table to zDatabase table, can u plz guide me which statement is better in performance to insert the records.
    1) insert one by one record from internal table
    loop at itab.
    insert ztable from wa.
    endloop.
    2) insert total records at a time
    INSERT <dbtabname> CLIENT SPECIFIED FROM TABLE itab.
    or let me know if any other statement is there with high performance.
    i internal table contains nearly 40000 records.
    thanks.

    Hi,
    Insert the entire table at atime rather than a record so as to increase the performance.
    you can use INSERT <dbtabname> CLIENT SPECIFIED FROM TABLE itab.
    or
    MODIFY ZPRODUCT FROM TABLE GI_AFPO.
    Regards,
    Raj.

  • Total records in database equals -1?

    I have some code, accessing an Access database. As part of development I need to see how many total records there are, so I have the code I took off of bindings in CS 5:
              <p align="center">/<%=(Recordset1_first)%>/<%=(Recordset1_last)%>/<%=(Recordset1_total)%></p >
    Why would _total always equal -1? The code is otherwise functional but the -1 does not change regardless if I add a record or delete a record?
    Curiouser and curiouser…
    Ross

    I try changing the cursor type and it had no effect whatsoever I also tried looking for a simple "attach" for this posting and could not find one. I therefore attached the full ASP so you could see what kind of stuff I'm talking about. Could you forward this as appropriate?
    Thanks.
    Ross
    =============================code=========================
    <%@LANGUAGE="VBSCRIPT" CODEPAGE="65001"%>
    <!--#include virtual="/Connections/nextdns.asp" -->
    <%
      dim MM_nextdns_STRING
          MM_nextdns_STRING ="PROVIDER=MICROSOFT.JET.OLEDB.4.0;DATA SOURCE=" & Server.MapPath("Database\ids2.mdb")
    Dim MM_editAction
    MM_editAction = CStr(Request.ServerVariables("SCRIPT_NAME"))
    If (Request.QueryString <> "") Then
      MM_editAction = MM_editAction & "?" & Server.HTMLEncode(Request.QueryString)
    End I
    ' boolean to abort record edit
    Dim MM_abortEdit
    MM_abortEdit = false
    %>
    <%
    ' *** Redirect if username exists
    MM_flag = "MM_insert"
    If (CStr(Request(MM_flag)) <> "") Then
      Dim MM_rsKey
      Dim MM_rsKey_cmd
      MM_dupKeyRedirect = "/already.asp"
      MM_dupKeyUsernameValue = CStr(Request.Form("11"))
      Set MM_rsKey_cmd = Server.CreateObject ("ADODB.Command")
      MM_rsKey_cmd.ActiveConnection = MM_nextdns_STRING
      MM_rsKey_cmd.CommandText = "SELECT id2 FROM login2 WHERE id2 = ?"
      MM_rsKey_cmd.Prepared = true
      MM_rsKey_cmd.Parameters.Append MM_rsKey_cmd.CreateParameter("param1", 200, 1, 255, MM_dupKeyUsernameValue) ' adVarChar
      Set MM_rsKey = MM_rsKey_cmd.Execute
      If Not MM_rsKey.EOF Or Not MM_rsKey.BOF Then
        ' the username was found - can not add the requested username
        MM_qsChar = "?"
        If (InStr(1, MM_dupKeyRedirect, "?") >= 1) Then MM_qsChar = "&"
        MM_dupKeyRedirect = MM_dupKeyRedirect & MM_qsChar & "requsername=" & MM_dupKeyUsernameValue
        Response.Redirect(MM_dupKeyRedirect)
      End If
      MM_rsKey.Close
    End If
    %>
    <%
    ' IIf implementation
    Function MM_IIf(condition, ifTrue, ifFalse)
      If condition = "" Then
        MM_IIf = ifFalse
      Else
        MM_IIf = ifTrue
      End If
    End Function
    %>
    <%
    If (CStr(Request("MM_insert")) = "form3") Then
      If (Not MM_abortEdit) Then
        ' execute the insert
        Dim MM_editCmd
        Set MM_editCmd = Server.CreateObject ("ADODB.Command")
        MM_editCmd.ActiveConnection = MM_nextdns_STRING
        MM_editCmd.CommandText = "INSERT INTO login2 (id2, password2, AccessLev) VALUES (?, ?, ?)"
        MM_editCmd.Prepared = true
        MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param1", 202, 1, 255, Request.Form("11")) ' adVarWChar
        MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param2", 202, 1, 255, Request.Form("22")) ' adVarWChar
        MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param3", 5, 1, -1, MM_IIF(Request.Form("accesslev"), Request.Form("accesslev"), null)) ' adDouble
        MM_editCmd.Execute
        MM_editCmd.ActiveConnection.Close
      End If
    End If
    %>
    <%
    ' *** Delete Record: construct a sql delete statement and execute it
    If (CStr(Request("MM_delete")) = "form2" And CStr(Request("MM_recordId")) <> "") Then
      If (Not MM_abortEdit) Then
        ' execute the delete
    mm_nextdns_string = "PROVIDER=MICROSOFT.JET.OLEDB.4.0;DATA SOURCE=" & Server.MapPath("Database\ids2.mdb")
           Set MM_editCmd = Server.CreateObject ("ADODB.Command")
        MM_editCmd.ActiveConnection = MM_nextdns_STRING
        MM_editCmd.CommandText = "DELETE FROM login2 WHERE id2 = ?"
        MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param1", 200, 1, 255, Request.Form("MM_recordId")) ' adVarChar
        MM_editCmd.Execute
        MM_editCmd.ActiveConnection.Close
      End If
    End If
    %>
    <%
    If (CStr(Request("MM_insert")) = "form3") Then
      If (Not MM_abortEdit) Then
        ' execute the insert
        Set MM_editCmd = Server.CreateObject ("ADODB.Command")
       MM_nextdns_string = "PROVIDER=MICROSOFT.JET.OLEDB.4.0;DATA SOURCE=" & Server.MapPath("Database\ids2.mdb")
         MM_editCmd.ActiveConnection = MM_nextdns_STRING
        MM_editCmd.CommandText = "INSERT INTO login2 (id2, password2) VALUES (?, ?)"
        MM_editCmd.Prepared = true
        MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param1", 202, 1, 255, Request.Form("121212")) ' adVarWChar
        MM_editCmd.Parameters.Append MM_editCmd.CreateParameter("param2", 202, 1, 255, Request.Form("343434")) ' adVarWChar
        MM_editCmd.Execute
        MM_editCmd.ActiveConnection.Close
        ' append the query string to the redirect URL
        Dim MM_editRedirectUrl0
        MM_editRedirectUrl = "inserted.asp"
        If (Request.QueryString <> "") Then
          If (InStr(1, MM_editRedirectUrl, "?", vbTextCompare) = 0) Then
            MM_editRedirectUrl = MM_editRedirectUrl & "?" & Request.QueryString
          Else
            MM_editRedirectUrl = MM_editRedirectUrl & "&" & Request.QueryString
          End If
        End If
        Response.Redirect(MM_editRedirectUrl)
      End If
    End If
    %>
    <%
    '  *** Recordset Stats, Move To Record, and Go To Record: declare stats variables
    Dim delit_total
    Dim delit_first
    Dim delit_last
    ' set the record count
    ' set the number of rows displayed on this page
    If (delit_numRows < 0) Then
      delit_numRows = delit_total
    Elseif (delit_numRows = 0) Then
      delit_numRows = 1
    End If
    ' set the first and last displayed record
    delit_first = 1
    delit_last  = delit_first + delit_numRows - 1
    ' if we have the correct record count, check the other stats
    If (delit_total <> -1) Then
      If (delit_first > delit_total) Then
        delit_first = delit_total
      End If
      If (delit_last > delit_total) Then
        delit_last = delit_total
      End If
      If (delit_numRows > delit_total) Then
        delit_numRows = delit_total
      End If
    End If
    %>
    <%
    ' *** Recordset Stats: if we don't know the record count, manually count them
    response.write("precount")
    If (Recordset1_total = -1) Then
      ' count the total records by iterating through the recordset
      Recordset1_total=0
    response.write("incount")
       While (Not Recordset1.EOF)
        Recordset1_total = Recordset1_total + 1
        Recordset1.MoveNext
      Wend
      ' reset the cursor to the beginning
      If (Recordset1.CursorType > 0) Then
        Recordset1.MoveFirst
      Else
        Recordset1.Requery
      End If
      ' set the number of rows displayed on this page
      If (Recordset1_numRows < 0 Or Recordset1_numRows > Recordset1_total) Then
        Recordset1_numRows = Recordset1_total
      End If
      ' set the first and last displayed record
      Recordset1_first = 1
      Recordset1_last = Recordset1_first + Recordset1_numRows - 1
      If (Recordset1_first > Recordset1_total) Then
        Recordset1_first = Recordset1_total
      End If
      If (Recordset1_last > Recordset1_total) Then
        Recordset1_last = Recordset1_total
      End If
    End If
    %>
    <%
    ' *** Validate request to log in to this site.
    MM_LoginAction = Request.ServerVariables("URL")
    If Request.QueryString <> "" Then MM_LoginAction = MM_LoginAction + "?" + Server.HTMLEncode(Request.QueryString)
    MM_valUsername = CStr(Request.Form("idid2"))
    If MM_valUsername <> "" Then
      Dim MM_fldUserAuthorization
      Dim MM_redirectLoginSuccess
      Dim MM_redirectLoginFailed
      Dim MM_loginSQL
      Dim MM_rsUser
      Dim MM_rsUser_cmd
      MM_fldUserAuthorization = ""
      MM_redirectLoginSuccess = "file:///C|/Users/Admin/AppData/Local/Temp/{C0C804DA-3712-4265-839B-02EB4947FC25}/g.asp"
      MM_redirectLoginFailed = "file:///C|/Users/Admin/AppData/Local/Temp/{C0C804DA-3712-4265-839B-02EB4947FC25}/b.asp"
      MM_loginSQL = "SELECT id2, password2"
      If MM_fldUserAuthorization <> "" Then MM_loginSQL = MM_loginSQL & "," & MM_fldUserAuthorization
      MM_loginSQL = MM_loginSQL & " FROM login2 WHERE id2 = ? AND password2 = ?"
      Set MM_rsUser_cmd = Server.CreateObject ("ADODB.Command")
      MM_rsUser_cmd.ActiveConnection = MM_nextdns_STRING
      MM_rsUser_cmd.CommandText = MM_loginSQL
      MM_rsUser_cmd.Parameters.Append MM_rsUser_cmd.CreateParameter("param1", 200, 1, 255, MM_valUsername) ' adVarChar
      MM_rsUser_cmd.Parameters.Append MM_rsUser_cmd.CreateParameter("param2", 200, 1, 255, Request.Form("pwd2")) ' adVarChar
      MM_rsUser_cmd.Prepared = true
      Set MM_rsUser = MM_rsUser_cmd.Execute
      If Not MM_rsUser.EOF Or Not MM_rsUser.BOF Then
        ' username and password match - this is a valid user
        Session("MM_Username") = MM_valUsername
        If (MM_fldUserAuthorization <> "") Then
          Session("MM_UserAuthorization") = CStr(MM_rsUser.Fields.Item(MM_fldUserAuthorization).Value)
        Else
          Session("MM_UserAuthorization") = ""
        End If
        if CStr(Request.QueryString("accessdenied")) <> "" And false Then
          MM_redirectLoginSuccess = Request.QueryString("accessdenied")
        End If
        MM_rsUser.Close
        Response.Redirect(MM_redirectLoginSuccess)
      End If
      MM_rsUser.Close
      Response.Redirect(MM_redirectLoginFailed)
    End If
    %>
    <%
    ' *** Validate request to log in to this site.
    MM_LoginAction = Request.ServerVariables("URL")
    If Request.QueryString <> "" Then MM_LoginAction = MM_LoginAction + "?" + Server.HTMLEncode(Request.QueryString)
    MM_valUsername = CStr(Request.Form("asd1"))
    If MM_valUsername <> "" Then
      MM_fldUserAuthorization = ""
      MM_redirectLoginSuccess = "file:///C|/Users/Admin/AppData/Local/Temp/{C0C804DA-3712-4265-839B-02EB4947FC25}/g.asp"
      MM_redirectLoginFailed = "file:///C|/Users/Admin/AppData/Local/Temp/{C0C804DA-3712-4265-839B-02EB4947FC25}/b.asp"
      MM_loginSQL = "SELECT id2, password2"
      If MM_fldUserAuthorization <> "" Then MM_loginSQL = MM_loginSQL & "," & MM_fldUserAuthorization
      MM_loginSQL = MM_loginSQL & " FROM login2 WHERE id2 = ? AND password2 = ?"
      Set MM_rsUser_cmd = Server.CreateObject ("ADODB.Command")
      MM_rsUser_cmd.ActiveConnection = MM_nextdns_STRING
      MM_rsUser_cmd.CommandText = MM_loginSQL
      MM_rsUser_cmd.Parameters.Append MM_rsUser_cmd.CreateParameter("param1", 200, 1, 255, MM_valUsername) ' adVarChar
      MM_rsUser_cmd.Parameters.Append MM_rsUser_cmd.CreateParameter("param2", 200, 1, 255, Request.Form("asd2")) ' adVarChar
      MM_rsUser_cmd.Prepared = true
      Set MM_rsUser = MM_rsUser_cmd.Execute
      If Not MM_rsUser.EOF Or Not MM_rsUser.BOF Then
        ' username and password match - this is a valid user
        Session("MM_Username") = MM_valUsername
        If (MM_fldUserAuthorization <> "") Then
          Session("MM_UserAuthorization") = CStr(MM_rsUser.Fields.Item(MM_fldUserAuthorization).Value)
        Else
          Session("MM_UserAuthorization") = ""
        End If
        if CStr(Request.QueryString("accessdenied")) <> "" And false Then
          MM_redirectLoginSuccess = Request.QueryString("accessdenied")
        End If
        MM_rsUser.Close
        Response.Redirect(MM_redirectLoginSuccess)
      End If
      MM_rsUser.Close
      Response.Redirect(MM_redirectLoginFailed)
    End If
    %>
    <%
    Dim Recordset1
    Dim Recordset1_cmd
    Dim Recordset1_numRows
    Set Recordset1_cmd = Server.CreateObject ("ADODB.Command")
    Recordset1_cmd.ActiveConnection = MM_nextdns_STRING
    Recordset1_cmd.CommandText = "SELECT * FROM login2"
    Recordset1_cmd.Prepared = true
    Set Recordset1 = Recordset1_cmd.Execute
    Recordset1_numRows = 0
    %>
    <!--#include virtual="/includes/adovbs.inc" -->
    <%
    Repeat1__numRows = 20
    Repeat1__index = 0
    Recordset1_numRows = Recordset1_numRows + Repeat1__numRows
    %>
    <%
    '  *** Recordset Stats, Move To Record, and Go To Record: declare stats variables
    Dim Recordset1_total
    Dim Recordset1_first
    Dim Recordset1_last
    ' set the record count
    Recordset1_total = Recordset1.RecordCount
    ' set the number of rows displayed on this page
    If (Recordset1_numRows < 0) Then
      Recordset1_numRows = Recordset1_total
    Elseif (Recordset1_numRows = 0) Then
      Recordset1_numRows = 1
    End If
    ' set the first and last displayed record
    Recordset1_first = 1
    Recordset1_last  = Recordset1_first + Recordset1_numRows - 1
    ' if we have the correct record count, check the other stats
    If (Recordset1_total <> -1) Then
      If (Recordset1_first > Recordset1_total) Then
        Recordset1_first = Recordset1_total
      End If
      If (Recordset1_last > Recordset1_total) Then
        Recordset1_last = Recordset1_total
      End If
      If (Recordset1_numRows > Recordset1_total) Then
        Recordset1_numRows = Recordset1_total
      End If
    End If
    %>
    <%
    ' *** Validate request to log in to this site.
    MM_LoginAction = Request.ServerVariables("URL")
    If Request.QueryString<>"" Then MM_LoginAction = MM_LoginAction + "?" + Request.QueryString
    MM_valUsername=CStr(Request.Form("idid2"))
    If MM_valUsername <> "" Then
      MM_fldDynamicRedirect=""
      MM_fldUserAuthorization="AccessLev"
      MM_redirectLoginSuccessDynamic="file:///C|/Users/Admin/AppData/Local/Temp/{C0C804DA-3712- 4265-839B-02EB4947FC25}/g.asp"
      MM_redirectLoginFailed="file:///C|/Users/Admin/AppData/Local/Temp/{C0C804DA-3712-4265-839 B-02EB4947FC25}/b.asp"
      MM_flag="ADODB.Recordset"
      set MM_rsUser = Server.CreateObject(MM_flag)
      MM_rsUser.ActiveConnection = MM_nextdns_STRING
      MM_rsUser.Source = "SELECT id2, password2"
      If MM_fldDynamicRedirect <> "" Then MM_rsUser.Source = MM_rsUser.Source & "," & MM_fldDynamicRedirect
      If MM_fldUserAuthorization <> "" Then MM_rsUser.Source = MM_rsUser.Source & "," & MM_fldUserAuthorization
      MM_rsUser.Source = MM_rsUser.Source & " FROM login2 WHERE id2='" & Replace(MM_valUsername,"'","''") &"' AND password2='" & Replace(Request.Form("pwd2"),"'","''") & "'"
      MM_rsUser.CursorType = 0
      MM_rsUser.CursorLocation = 2
      MM_rsUser.LockType = 3
      MM_rsUser.Open
      If Not MM_rsUser.EOF Or Not MM_rsUser.BOF Then
        ' username and password match - this is a valid user
        Session("MM_Username") = MM_valUsername
        If (MM_fldUserAuthorization <> "") Then
          Session("MM_UserAuthorization") = CStr(MM_rsUser.Fields.Item(MM_fldUserAuthorization).Value)
        ElseIf (MM_fldDynamicRedirect <> "") Then
          MM_redirectLoginSuccessDynamic = CStr(MM_rsUser.Fields.Item(MM_fldDynamicRedirect).Value)
        Else
          Session("MM_UserAuthorization") = ""
        End If
        if CStr(Request.QueryString("accessdenied")) <> "" And false Then
          MM_redirectLoginSuccessDynamic = Request.QueryString("accessdenied")
        End If
        MM_rsUser.Close
        Response.Redirect(MM_redirectLoginSuccessDynamic)
      End If
      MM_rsUser.Close
      Response.Redirect(MM_redirectLoginFailed)
    End If
    %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Untitled Document</title>
    <style type="text/css">
    body {
        background-image: url(/graphics/spackle.gif);
    .ctable {
        border-top-style: solid;
        border-right-style: solid;
        border-bottom-style: solid;
        border-left-style: solid;
    </style>
    <script src="/SpryAssets/SpryValidationTextField.js" type="text/javascript"></script>
    <link href="/SpryAssets/SpryValidationTextField.css" rel="stylesheet" type="text/css" />
    </head>
    <body>
    <table width="160" border="1">
      <tr>
        <td width="106"><p><img src="/graphics/coed1.jpg" width="42" height="53" alt="coed1" /></p>
          <form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post">
            <input type="hidden" name="cmd" value="_cart" />
            <input type="hidden" name="add" value="1" />
            <input type="hidden" name="bn" value="webassist.dreamweaver.4_5_0" />
            <input type="hidden" name="business" value="[email protected]" />
            <input type="hidden" name="item_name" value="aaaa" />
            <input type="hidden" name="item_number" value="aaaa" />
            <input type="hidden" name="amount" value=".12" />
            <input type="hidden" name="currency_code" value="USD" />
            <input type="hidden" name="cancel_return" value="http://heritage.site88.net/badorder.asp" />
            <input type="hidden" name="receiver_email" value="[email protected]" />
            <input type="hidden" name="mrb" value="R-3WH47588B4505740X" />
            <input type="hidden" name="pal" value="ANNSXSLJLYR2A" />
            <input type="hidden" name="no_shipping" value="0" />
            <input type="hidden" name="no_note" value="0" />
            <input type="image" name="submit" src="http://images.paypal.com/images/sc-but-03.gif" border="0" alt="Make payments with PayPal - it's fast, free and secure!" />
        </form></td>
        <td width="16"> </td>
        <td width="16"> </td>
      </tr>
      <tr>
        <td> </td>
        <td><img src="/graphics/coed1.jpg" width="14" height="18" alt="coed1" /></td>
        <td> </td>
      </tr>
      <tr>
        <td> </td>
        <td> </td>
        <td><img src="/graphics/coed1.jpg" width="20" height="31" alt="coed1" /></td>
      </tr>
    </table>
    <form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post">
      <div align="center">
        <input type="hidden" name="cmd" value="_cart" />
        <input type="hidden" name="display" value="1" />
        <input type="hidden" name="bn" value="webassist.dreamweaver.4_5_0" />
        <input type="hidden" name="business" value="[email protected]" />
        <input type="hidden" name="receiver_email" value="[email protected]" />
        <input type="hidden" name="mrb" value="R-3WH47588B4505740X" />
        <input type="hidden" name="pal" value="ANNSXSLJLYR2A" />
        <input type="image" name="submit" src="http://images.paypal.com/images/view_cart_02.gif" border="0" alt="Make payments with PayPal - it's fast, free and secure!" />
     </div>
    </form>
    <p> </p>
    <table width="492" border="1" cellspacing="0" cellpadding="0">
      <tr>
        <td width="63"><label for="recnum6">Recnum</label></td>
        <td width="101"> ID</td>
        <td width="154">Password </td>
        <td width="164">AccessLev</td>
      </tr>
    </table>
    <%
    While ((Repeat1__numRows <> 0) AND (NOT Recordset1.EOF))
    %>
    <td><input name="recnum" type="text" id="recnum" value="<%=(Recordset1.Fields.Item("recnum").Value)%>" size="10" /></td>
    <td><input name="idid" type="text" id="idid" value="<%=(Recordset1.Fields.Item("id2").Value)%>" size="10" /></td>
    <td><input name="pwd" type="text" id="pwd" value="<%=(Recordset1.Fields.Item("password2").Value)%>" /></td>
    <td><input name="accesslev" type="text" id="accesslev" value="<%=(Recordset1.Fields.Item("AccessLev").Value)%>" /></td>
    <label for="accesslev"></label>
    <%
      Repeat1__index=Repeat1__index+1
      Repeat1__numRows=Repeat1__numRows-1
      Recordset1.MoveNext()
      response.write("<br>")
    Wend
    %>
    <p align="center">/<%=(Recordset1_first)%>/<%=(Recordset1_last)%>/<%=(Recordset1_total)%>/</ p>
    <p align="center"> </p>
    <form id="form4" name="form4" method="post" action="file:///C|/Users/Admin/AppData/Local/Temp/{C0C804DA-3712-4265-839B-02EB4947FC25}/ inscust.asp">
      <div align="center">
        <input type="submit" name="register" id="register" value="Register as New User" />
      </div>
    </form>
    <p align="center">-or- </p>
    <form id="form1" name="form1" method="POST" action="<%=MM_LoginAction%>">
      <label for="idid2">                                                                      ID:</label>
      <input type="text" name="idid2" id="idid2" />
      <label for="pwd2">Pwd:</label>
      <input type="password" name="pwd2" id="pwd2" />
      <input type="submit" name="login" id="login" value="Login" />
      <a href="file:///C|/Users/Admin/AppData/Local/Temp/{C0C804DA-3712-4265-839B-02EB4947FC25}/re gister.asp">
      </a>
    </form>
    <form action="<%=MM_editAction%>" method="POST" id="form3" name="form3">
        <label for="11">IdId:</label>
        <input type="text" name="11" id="11" />
        <label for="22">Password2:</label>
        <input type="password" name="22" id="22" />
      <label for="accesslev">AL:</label>
      <input name="accesslev" type="text" id="accesslev" value="2" size="1" maxlength="1" />
      <input type="submit" name="insins" id="insins" value="Insert" />
        <input type="hidden" name="MM_insert" value="form3" />
      </p>
    </form>
    <p></p>
    <p></p>
    <form ACTION="file:///C|/Users/Admin/AppData/Local/Temp/{C0C804DA-3712-4265-839B-02EB4947FC25}/ dodel.asp" METHOD="POST" id="form2" name="form2">
      <label for="delrec">Recnum:</label>
      <input type="text" name="delrec" id="delrec" />
      <input type="submit" name="deleir" id="deleir" value="Delete" />
    </form>
    <p></p>
    <p>
      <script type="text/javascript">
    function zappaypalcookies()
        alert("called");
        alert(document.cookie.length);
        alert(document.cookie);
        document.cookie="fred=sam";
            alert(document.cookie);
      </script></p>
    </body>
    </html>
    <%
    Recordset1.Close()
    Set Recordset1 = Nothing
    %>

  • Records in setup table

    Hi Gurus,
    I had a query regarding the total no. of records in setup table of a particular datasource say for 2LIS_13_VDKON
    If i want to know the number of entries in the setup table for this datasource how can i do that ? RSA3 extractor can do this but i just want number of entires only.
    Is there any database table to store the data of setuptable for it ?
    Sonal...

    Hi Sonal,
    U can try in SE16 --> MC13*KONSETUP which is a structure name (F4).. and then select ur structure name and then enter. And check for the number of entries.
    Or u can use RSA3 to findout the same where u need to provide the proper celll info to get the total count.
    Or u can check NPRT T-code to get the total count for that application from the previous setups.
    thanks
    Hope this helps

  • Total records in IT0000 company code wise - SE16N

    Hello All,
    I need to check the total number of records in IT0000 for employees belonging to a particular company codes or personnel area. But there shouldn't be any duplicate entry for a personnel number in the total records.
    In SE16N I am able to get an entire list but not company code wise. Is there any way I can generate the  total no records in each infotype, on the basis of company code or personnel areas?
    Regards,
    Ally

    1 - If you have activated Complementary Measures, you should look at table PA0302 instead of table PA0000.
    2 - As mentioned by Pedro, se16n will not allow you to get what you require in a single step.  An Ad Hoc Query could probably allow you to create the report you want.
    3 - Should you be able to get lists of employee numbers "on the basis of company code or personnel areas" (possibly using se16n to look at table PA0001), then you could use those lists to explore the different infotypes (tables PA0000, PA0002, PA0006, etc...) using se16n, but unless you restrict the output to the records with End Date = 31.12.9999 , you will end up with many records for each employee.

  • To delete duplicate records from internal table

    hi friends,
    i have to delete records from internal table based on following criterion.
    total fields are 7.
    out of which  if 4 fields are same and 5th field is different,then both records must be deleted.
    in case all five fields are same,the program should do nothing.
    for example.
    if there are 3 records as follows
    a1 b1 c1 d1 e1 f g
    a1 b1 c1 d1 e2 w r
    a1 b1 c1 d1 e1 j l
    then first two records should be deleted as four fields are same but fifth(e) field differs.
    but third record should remain as it is evenif first five fields are same for first and third record.
    values of last two fields need not to be consider for deleting the records.

    LOOP AT ITAB.
      V_FILED5 = ITAB-F5. "to compare later
      V_TABIX = SY-TABIX. "used to delete if condition not matches
      READ TABLE ITAB WITH KEY F1 = ITAB-F1
                               F2 = ITAB-F2
                               F3 = ITAB-F3
                               F4 = ITAB-F4.
      IF SY-SUBRC = 0.
        IF ITAB-F5 <> V_FIELD5.
    *--both the records to be deleted,as Field5 is different.
          DELETE ITAB INDEX SY-TABIX. "deletes that record
          DELETE ITAB INDEX V_TABIX. "deletes the current record
        ENDIF.
      ENDIF.
    ENDLOOP.
    Message was edited by: Srikanth Kidambi
    added comments
    Message was edited by: Srikanth Kidambi

  • How to speed up the deletion of 11million records from the table

    Hi,
    How to speed up the deletion of 11million records from the table.
    I need expiditious reply. Please do the needfull in advising
    Regards

    Please try to understand the question.Well it would help if you would answer some of the questions you have been asked as your question is not complete and clear and no matter how hard we try, we really need you to try and ask the question properly.
    So as previously asked
    Which simply supports the idea that we need:
    1) better definition of the business purpose (why)
    2) oracle version
    3) operating system
    4) hardware configuration
    to give a moderately accurate answer.
    I would like to add
    5) How many rows in total in the table to begin with.
    6) What is your delete statement
    7) Is this a one time operation or will it happen regularly
    8) Can you use partitioning.

  • How to find out which user has locked a particular record of a table

    Hi
    Is it possible to know - which user has locked a particular record (I know the primary key of the record) of a table
    Regards

    select     OS_USER_NAME os_user,
         PROCESS os_pid,
         ORACLE_USERNAME oracle_user,
         l.SID oracle_id,
         decode(TYPE,
              'MR', 'Media Recovery',
              'RT', 'Redo Thread',
              'UN', 'User Name',
              'TX', 'Transaction',
              'TM', 'DML',
              'UL', 'PL/SQL User Lock',
              'DX', 'Distributed Xaction',
              'CF', 'Control File',
              'IS', 'Instance State',
              'FS', 'File Set',
              'IR', 'Instance Recovery',
              'ST', 'Disk Space Transaction',
              'TS', 'Temp Segment',
              'IV', 'Library Cache Invalidation',
              'LS', 'Log Start or Switch',
              'RW', 'Row Wait',
              'SQ', 'Sequence Number',
              'TE', 'Extend Table',
              'TT', 'Temp Table', type) lock_type,
         decode(LMODE,
              0, 'None',
              1, 'Null',
              2, 'Row-S (SS)',
              3, 'Row-X (SX)',
              4, 'Share',
              5, 'S/Row-X (SSX)',
              6, 'Exclusive', lmode) lock_held,
         decode(REQUEST,
              0, 'None',
              1, 'Null',
              2, 'Row-S (SS)',
              3, 'Row-X (SX)',
              4, 'Share',
              5, 'S/Row-X (SSX)',
              6, 'Exclusive', request) lock_requested,
         decode(BLOCK,
              0, 'Not Blocking',
              1, 'Blocking',
              2, 'Global', block) status,
         OWNER,
         OBJECT_NAME
    from     v$locked_object lo,
         dba_objects do,
         v$lock l
    where      lo.OBJECT_ID = do.OBJECT_ID
    AND l.SID = lo.SESSION_ID
    hope this helps
    Zekeriya

  • Calculating the size of each record in a table?

    Hi to all,
    I trying to create histograms based on the unique record sizes in a particular table. However , in order to do that I need to calculate the size of each record in the table (in kilobytes preferably) and to get a list of unique record sizes.
    Is there a function or easy way to calculate the size in Kbytes of a record in a table?
    Thank you in advance!
    Tony

    Hi,
    You can use the sum of the average of the vsizes of the fields in the table. For example:TEST.SQL>CREATE TABLE TEST
      2  (
      3  A VARCHAR2(50 CHAR),
      4  B NUMBER
      5  ) TABLESPACE TOOLS;
    Table created.
    TEST.SQL>INSERT INTO TEST VALUES('&1',&2);
    Enter value for 1: A
    Enter value for 2: 10
    old   1: INSERT INTO TEST VALUES('&1',&2)
    new   1: INSERT INTO TEST VALUES('A',10)
    1 row created.
    TEST.SQL>/
    Enter value for 1: ABCDEFGHIJKLMNOPQRSTUVWXYZ
    Enter value for 2: 100000
    old   1: INSERT INTO TEST VALUES('&1',&2)
    new   1: INSERT INTO TEST VALUES('ABCDEFGHIJKLMNOPQRSTUVWXYZ',100000)
    1 row created.
    TEST.SQL>COMMIT;
    Commit complete.
    TEST.SQL>SELECT AVG(VSIZE(A)) + AVG(vSIZE(B)) FROM TEST;
    AVG(VSIZE(A))+AVG(VSIZE(B))
                           15.5                                  The average line size - from the data in the table NOW - is 15.5 bytes.
    HTH,
    Yoann.

  • Incomplete Data on report (report does not show all records from the table)

    Hello,
    I have problem with CR XI, I'm running the same report on the same data with simple select all records from the table (no sorting, no grouping, no filters)
    Sometimes report shows me all records sometimes not. Mostly not all records on the report. When report incomplete sometimes it shows different number of records.
    I'm using CR XI runtime on Windows Server 2003
    Any help appreciated
    Thanks!

    Sorry Alexander. I missed the last line where you clearly say it is runtime.
    A few more questions:
    - Which CR SDK are you using? The Report Designer Component or the CR assemblies for .NET?
    - What is the exact version of CR you are using (from help | about)
    - What CR Service Pack are you on?
    And a troubleshooting suggestion:
    Since this works on some machines, it will be a good idea to compare all the runtime (both CR and non CR) being loaded on a working and non working machines.
    Download the modules utility from here:
    https://smpdl.sap-ag.de/~sapidp/012002523100006252802008E/modules.zip
    and follow the steps as described in this thread:
    https://forums.sdn.sap.com/click.jspa?searchID=18424085&messageID=6186767
    The download also includes instructions on how to use modules.
    Ludek

  • How to get large no of records from adf table

    Hi All,
    I'm working on adf.I'm using jdeveloper 11.1.1.5 version.In my adf application i have 1000 records in my adf table.I want to get the 500 selected records from that table at a time.But im not able to get huge number of records.How can i get the records from adf table.Please give me ur valuable suggestions.
    Thanks!

    Hi.
    for large record check the oficial doc.
    http://docs.oracle.com/cd/E24382_01/web.1112/e16182/bcadvvo.htm#CEGDBJEJ
    PAGE_RANGING is the best option for large tables.
    and these maybe will help you
    Re: Performance scrolling large ADF tables
    Re: Expert opinion needed: Best practices to handle huge rowsets on UI

Maybe you are looking for

  • Bug in Mail when using Google Apps Gmail and sync

    I found a bug in the sync process between the Mac and the phone. If you have Mail (on the computer) set to use Google Apps for Your Domain, the sync on the phone changes the user for the mail account. I assume this is because it sees "smtp.gmail.com"

  • Default settings for mail attachements

    I am using entourage as my primary mail account-how do I set Word, Excel, and Power Point as the as the default applications for their respective file attachments in mail?

  • Scratchy distorted sound from SB L

    Everything was working fine with Sb Li've until a few days ago when the sound turned wretched for everything from the Windows Log On Music to .wav files. I have checked everything including the speakers. I have looked for hardware and software confli

  • How do I delete the contact list

    I recently got my husbands Iphone when he upgraded. How do I delete his 1000 contacts.

  • Re-installing TCS2.5 and CS5.5 - process?

    So... I mentioned in a posting over in Acrobat yesterday that things had gone awry on my notebook. Well, they went from bad to worse :-) The notebook is currently being nuked and paved, and I'll have to load my TCS2.5 and CS5.5. I vaguely recall that