Results 1 to 6 of 6

Thread: Caching Records in Memory with ASP.NET

  1. #1
    Join Date
    Nov 2009
    Posts
    652

    Caching Records in Memory with ASP.NET

    Hello, I am learning ASP.NET programming language. And while learning it, I have come to know that it is possible to catch the records from the memory. I am not able to understand the basic concept behind this, so if you are having idea about it, then please help me to achieve it. It will be helpful to me to know about it. If you know the sources from which I can able to get more knowledge about the same then also please provide help about it.

  2. #2
    Join Date
    Apr 2008
    Posts
    1,949

    Re: Caching Records in Memory with ASP.NET

    Hello, if you want to cache the data in memory then you need to create the method which will take into account the memory for the given number of time. And between that much period that data is displayed into the memory and so it will provide more faster response to the any type of query. And if the time period is complete then the data from the cache is refreshed and thus it can contain the new or fresh data in the memory.

  3. #3
    Join Date
    May 2008
    Posts
    2,015

    Re: Caching Records in Memory with ASP.NET

    Hey, while searching about your question I have got the below mentioned code which will help you to store or get the object virtually from the AppDomain and for that you must need to make use of the code below:

    Code:
    System.AppDomain.CurrentDomain.SetData("NewData", Type)
    
    Type =(Type) System.AppDomain.CurrentDomain.GetData("NewData")

  4. #4
    Join Date
    May 2008
    Posts
    2,302

    Re: Caching Records in Memory with ASP.NET

    Hello, if you want to know the details about the Caching Records in Memory with ASP.NET, then you must need to make use of the code below:

    Code:
    <%
    Function Disp()
        Const Text = &H0001
        Dim sqlq, connection , result
    
        sqlq = "SELECT id, FName, lLName FROM Names"
    
        Set connection  = Server.CreateObject("ADODB.Connection")
        connection .Open "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" & _
              Server.MapPath("CacheDemo.mdb")
    
        Set result = Server.CreateObject("ADODB.Recordset")
        result.Open sqlq, connection , 2, 4, Text
    
        If Not result.EOF Then
          Dim variable
          variable = "<table width=""90%"" align=""center"""
          variable = variable & " border=""1""  bordercolor=""silver"""
          variable = variable & " cellspacing=""2"" cellpadding=""0"">"
          variable = variable & "<tr bgcolor=""#CCDDEE""><td width=""5%"""
          variable = variable & ">ID</td><td>Firesultt Name</td>"
          variable = variable & "<td>Last Name</td></tr>"
    
        While Not result.EOF
          variable = variable & "<tr><td bgcolor=""#CCDDEE"">"
          variable = variable & result("ID") & "</td><td>" & result("FName")
          variable = variable & "</td><td>" & result("lLName")
          variable = variable & "</td></tr>"
          result.MoveNext
        Wend
    
          variable = variable & "</table>"
    
          Disp = variable
        Else
          Disp = "Data Not Available."
        End If
    
        result.Close
        connection .Close
        Set result = Nothing
        Set connection  = Nothing
    End Function
    %>

  5. #5
    Join Date
    Oct 2005
    Posts
    2,394

    Re: Caching Records in Memory with ASP.NET

    Hello, if you want to make use of the faster response while making use of the web application then it is necessary to use the Caching records in memory with Asp.net. Most of time this technique is used by the developer for getting faster working of the web site. It is having following two types of caching:
    • Output Caching
    • Data Caching

  6. #6
    Join Date
    Apr 2008
    Posts
    2,010

    Re: Caching Records in Memory with ASP.NET

    Hello, if you make use of the code below then you will come to know the details about the caching records in memory with ASP.NET
    Code:
     If (args == "site") then
            dim Name as string = _
            Context.Request.Browser.Browser + Context.Request.Browser.MajorVersion.ToString() 
            return Name
       Else if (args=="SomeCustomString") then
        Else MyBase.GetVaryByCustomString(context, args)
        End If
    End Function

Similar Threads

  1. Does Intel X79 Chipset going to get SSD caching
    By Diedrick in forum Motherboard Processor & RAM
    Replies: 8
    Last Post: 05-04-2012, 03:33 AM
  2. Intel Z68 system with SSD for caching
    By X-MaaN in forum Motherboard Processor & RAM
    Replies: 6
    Last Post: 04-08-2011, 11:27 PM
  3. Code for Caching
    By RMG in forum Software Development
    Replies: 3
    Last Post: 02-01-2009, 09:39 PM
  4. How to increase the File System Caching Memory?
    By SinguIar in forum Windows Vista Performance
    Replies: 1
    Last Post: 25-12-2008, 01:29 AM
  5. disk caching
    By in forum Windows Server Help
    Replies: 6
    Last Post: 10-12-2007, 09:07 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •