1. Are you ready for the Galaxy S20? Here is everything we know so far!

Advice on how to handle external datasource

Discussion in 'Android Development' started by energyshawn, Dec 31, 2011.

  1. energyshawn

    energyshawn Lurker
    Thread Starter

    I am working on an app that needs to pull some data that is stored on a MS SQL 2008 Server. Basically a front end PC application submits data to this database and I want to share this data through my mobile application.

    I created a few stored procedures on the server that returns the data that I would like to reference in my app. Please note that I am only recieving data to the app and not trying to modify the database tables in anyway. The data I need to send to the app requires NO CONDITIONS so it is a simple call without passing any parameters to the DB Server. I also created a WCF REST service to handle that has a class that returns basically the data from the stored procs I want to use.

    Here is my question, what is the best way to retrieve this data from the database? I believe there are a few different ways to handle this such as;

    1. Copying the records into a SQLite DB and then transfering it to the device;
    2. Interacting with the REST service through the application;
    3. Creating a class that connects directly to the database;

    I've been trying method #2 but haven't had much luck in getting the application to consume the service. If this is the best way to handle it maybe you can point me to a tutorial on the subject that would be useful as every tutorial I've looked at so far hasn't really helped. I would think there would be some pretty simple methods on handling a datasource from an external database.
     



    1. Download the Forums for Android™ app!


      Download

       
Loading...

Share This Page

Loading...