Jump to content

Connect Android App to Database.

PampaZiya

I would like to connect my android app to an online database.

 

Thing i, I always use parse but I want an online database that can create tables through SQL queries, not graphically.

 

I already have my database created on SQL Developer. Is there a way to make it online ? 

 

If so, how can I access it from my app?

 

 

Thanks a lot

Link to comment
Share on other sites

Link to post
Share on other sites

I recently faced the same task..

After trying some I decided on FireBase.

Easy to connect, tight security and nosql db so I can store JSON objects.

I create these from within a backoffice app that queries a local mysql database.

 

Cheers

Mario

Link to comment
Share on other sites

Link to post
Share on other sites

Connecting an app straight to database seems very sketchy to me. IMO you should write a server-side API that does all the database work. You will then use json/xml protocols (whichever you want) to communicate with the API. This will also allow you to ensure backward compatibility between versions better.

Link to comment
Share on other sites

Link to post
Share on other sites

Agree, in a way that's how I do it, except I don't communicate directly with the server-side app but in this specific case use a firebase db to exchange data..

Link to comment
Share on other sites

Link to post
Share on other sites

3 hours ago, Mario Kreeft said:

I recently faced the same task..

After trying some I decided on FireBase.

Easy to connect, tight security and nosql db so I can store JSON objects.

I create these from within a backoffice app that queries a local mysql database.

 

Cheers

Mario

 

Could you explain how it queries to a local db ? The database I want to use is on my laptop. Can it actually use it through firebase?

Link to comment
Share on other sites

Link to post
Share on other sites

On 3/24/2016 at 11:40 PM, PampaZiya said:

 

Could you explain how it queries to a local db ? The database I want to use is on my laptop. Can it actually use it through firebase?

Create a REST API that runs on your laptop and manages the database.

Your android app then talks with the REST API which is much safer.

There are tons of frameworks to do this in almost any language.

Desktop: Intel i9-10850K (R9 3900X died 😢 )| MSI Z490 Tomahawk | RTX 2080 (borrowed from work) - MSI GTX 1080 | 64GB 3600MHz CL16 memory | Corsair H100i (NF-F12 fans) | Samsung 970 EVO 512GB | Intel 665p 2TB | Samsung 830 256GB| 3TB HDD | Corsair 450D | Corsair RM550x | MG279Q

Laptop: Surface Pro 7 (i5, 16GB RAM, 256GB SSD)

Console: PlayStation 4 Pro

Link to comment
Share on other sites

Link to post
Share on other sites

5 hours ago, mathijs727 said:

Create a REST API that runs on your laptop and manages the database.

Your android app then talks with the REST API which is much safer.

There are tons of frameworks to do this in almost any language.

Thanks mate. I worked it out myself. Created a mysql database on CPanel, hosted by godaddy and wrote php to connect/query the database and called them from my App, worked beautifully and fast ^^ Thank you all for the kind help!

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×