1

I know about Displaying Text or other raw data display, But My Query is about SQLite table.

Query: Display SQLite data to application from Google Drive.

I have Uploaded a SQLite Database to GoogleDrive which has 5 tables including one "Mobile Number".

I want to display "Mobile Number" to My app directly from GoogleDrive. What Options do I have to doing so ?

  • SQLite requires direct access to the file. AFAIK, you need to make a copy of the content from Google Drive to a regular file before you can use it with SQLite. – CommonsWare Mar 07 '17 at 12:53
  • What exactly is the problem? Do you know how to download a file from Google Drive? Do you know how to open it after you download it? – Code-Apprentice Mar 07 '17 at 12:54
  • @CommonsWare Are you mentioning Drive file while you are saying regular file ? –  Mar 07 '17 at 12:57
  • @Code-Apprentice Looks like you didnt understood my question. Leave it. –  Mar 07 '17 at 12:58
  • @GameOfThronesSuperFan that is exactly why I ask for classification. – Code-Apprentice Mar 07 '17 at 12:59
  • @Code-Apprentice Okay, Yes, I can download and display simple text or other files. –  Mar 07 '17 at 13:01
  • @GameOfThronesSuperFan how is a database file any different? – Code-Apprentice Mar 07 '17 at 13:02
  • @Code-Apprentice Actually, I have a table of "Mobile Number" which I need to display contents users in list view. –  Mar 07 '17 at 13:02
  • @Code-Apprentice I need the data inside table to be displayed. if that is possible that's gonna solve my issue. –  Mar 07 '17 at 13:04
  • @GameOfThronesSuperFan so what difficult do you have? – Code-Apprentice Mar 07 '17 at 13:04
  • Just download the database file and open it. – Code-Apprentice Mar 07 '17 at 13:05
  • @Code-Apprentice Thx, I will keep that in mind if I dont get other solution. Looks like your idea is gonna work or else I have to try with JSON. –  Mar 07 '17 at 13:07
  • you should do what @Code-Apprentic suggested. Because it will be only one time hit to internet otherwise you have to continuously sync up with google drive. other issue will also come on the same page. – Jitesh Mohite Mar 07 '17 at 13:16
  • Yes, @jiteshmohite sounds good for me. Thanks for huge response. –  Mar 07 '17 at 13:21

2 Answers2

1

To display "mobile number" table to your app you have to:

First> download that table using Google Drive Sync or manual Download using Button click.

Second> Get table data by accessing the table locally.

Third> Display the data to your View. Check bellow link for getting example regarding this.

to display data you can check Google Drive Demo examples here "Click here" Hope this will help you.

JSON may help but as you mentioned your database already growing, you should follow this "Download and Display" procedure I mentioned above.

Crime_Master_GoGo
  • 1,641
  • 1
  • 20
  • 30
0

instead of uploading sqlite database file on google drive, upload json file with your all data. and parse json on your app.

Learn Pain Less
  • 2,274
  • 1
  • 17
  • 24
  • Yes, I can do that. But Already I have a huge database of users in Drive. So, Its going to be tough for me to start JSON. So, Seeking for a solution here. Thx. –  Mar 07 '17 at 13:00