• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Updating local DB from web

 
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a website that includes a database that is made up of all the members and pertinent information for my organization. It gets updated throughout the day based upon people registering their dogs and clubs with our organization.

I am developing a offline application that is dependant on this information. I need to be able to pull the information from the website database and populate a local running MySQL database. (If it matters the website is running MySQL as well)

I envisioned running a SELECT for all the information that I need, doing a DROP and the current tables, and then INPUT all of the information from SELECT to the local database. My concern is that there will be a LOT of records to deal with. Something in the neighborhood of 2,000 records to start, and as time goes on it could get into the 10's of thousands of records.

Is there a more efficient way to go about doing this type of an operation?
 
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Have you looked into database replication? It is supported by MySQL.
See http://dev.mysql.com/doc/mysql/en/replication-howto.html
 
Brett Williams
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is this more effecient than just pulling out specific portions of the database that I need?
 
author & internet detective
Posts: 41860
908
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Brett Williams:
Is this more effecient than just pulling out specific portions of the database that I need?


Yes. You can usually configure the replicator to only copy certain tables or schemas. And the replicator is built to do this, so it does a faster job of it.
 
Wait for it ... wait .... wait .... NOW! Pafiffle! A perfect tiny ad!
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic