How to: Update Records

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • werks
    New Member
    • Dec 2007
    • 218

    How to: Update Records

    Hi experts this is an urgent question. how do you import and export database online?

    I have 2 equal database. I uploaded my FrontEnd(OPAC) and Database online. I have also a same database in my BackEnd(VB6) located in my computer. My problem is how do i update both database in every transaction done.

    E.g. I added a record in my backend, the system will automatically update the database record online.

    how can i accomplish this? is it possible? Tnx.

    BTW im using VB6, ASP and Access

    --
    Kenneth
    "Better Than Yesterday"
  • debasisdas
    Recognized Expert Expert
    • Dec 2006
    • 8119

    #2
    You go for file copy .
    You need to copy the live database and maintain a copy in another location for backup.

    Comment

    • werks
      New Member
      • Dec 2007
      • 218

      #3
      Originally posted by debasisdas
      You go for file copy .
      You need to copy the live database and maintain a copy in another location for backup.
      Hi debasisdastnx for the reply, I found a Free WebHosting company in the net that cater my needs to go online with my OPAC since i don't have a domain (can't afford actually) the problem is that it requres to upload the OPAC and the Database. I have a reservation in my OPAC now when a user reserve a certain book it will automatically update the record in the database(online ) now my BIG problem is that how can i update my database(locall y) every time the user reserve a book.

      --
      Kenneth
      "Better Than Yesterday"

      Comment

      • VBWheaties
        New Member
        • Feb 2008
        • 145

        #4
        Originally posted by werks
        Hi debasisdastnx for the reply, I found a Free WebHosting company in the net that cater my needs to go online with my OPAC since i don't have a domain (can't afford actually) the problem is that it requres to upload the OPAC and the Database. I have a reservation in my OPAC now when a user reserve a certain book it will automatically update the record in the database(online ) now my BIG problem is that how can i update my database(locall y) every time the user reserve a book.

        --
        Kenneth
        "Better Than Yesterday"
        I'd create an XML page only you can access. Then download locally and connect to it with ADO and in another connection, load the data in your DB. This would not be too difficult to automate.

        Comment

        • werks
          New Member
          • Dec 2007
          • 218

          #5
          Originally posted by VBWheaties
          I'd create an XML page only you can access. Then download locally and connect to it with ADO and in another connection, load the data in your DB. This would not be too difficult to automate.
          How can i do that? please guide me through..

          Comment

          • VBWheaties
            New Member
            • Feb 2008
            • 145

            #6
            Originally posted by werks
            How can i do that? please guide me through..
            You probably know more about ASP than I, but I can give you general approach and you can work it from there.

            ADODB.Recordset s have a Save method, the Save method takes 2 parameters: location and persistformat.

            Create the recordset as you would for the data you require.
            Then, for the Save method, you want to set persistformat to adPersistXML.

            Code:
               rs.Save "\\WebServer\MyXML.xml", adPersistXML
            Keep in mind that this XML needs to be saved on the server where you can access it like: "http://www.mywebserver .com/myxml.xml"
            but that detail is where you will have to fill in. (I know ASP allows you to write Server based code and Client based code. but that is all I know)

            Now, once you've managed to do that, you simply connect to XML through one of the various methods available: winsock or Internet transfer control.
            and save the XML locally.

            When xml has been saved local, all you need to do to connect to it:

            Code:
            Dim rs as ADODB.Recordset
            rs.Open "C:\myxml.xml"
            So now basically, you now have a local version of your data, now you need only to write it to your MDB as usual which I assume you can do on your own.

            Comment

            Working...