Windows phone 8.1 app connect with a database - mysql

I'm totally new to the windows phone 8.1 app development.
I'm trying to develop a simple app with a database using visual studio 2013. It is not a silverlight app.
my app just have a text field and a button.And i have a MySQL database in a local server(WAMP).
I need to get a input from the text field and store it in the database.
First thing that I want to know is it possible to do?
If it is possible I would be very grateful if you could provide a step by step guide or a link where i can learn about this.
If it is not possible what are the other ways that I can try to store my input in a database?

Local storage
I'm guessing you're looking for a way to store structured data locally on the phone. AFAIK, MySQL is not supported on Windows Phone (MySQL is big, runs as a server, and it wouldn't be possible or practical to "install" it onto a phone). Instead what Microsoft endorses is to use SQLite. You'll first need to download the SQLite library as a Visual Studio extension. Then you'll need to install something like SQLitePCL (from NuGet) which essentially wraps the native SQLite library so that it is accessible from .NET languages. Make sure you add both references to your project. SQLite stores a database as a file that you can put in the local storage for your app.
Remote storage
I'm not sure if it's directly possible to connect to a remove MySQL server from a WP app. Usually you'd access a remote database through a webserver that exposes an API for you to use (e.g. a REST API). You can then send data to the webserver via a HTTP POST request, and then your webserver will store the data in the database. This is a big topic, and involves knowledge of server-side programming such as ASP.NET, Ruby on Rails, Django, PHP, etc. This topic is too broad for me to give you specifics on how to do this. See this answer.

Related

Building Intel XDK with SQLite

This might be a often repeated question. I am a newcomer to the world of mobile and programming in general. I am trying to build an app that uses the native database capabilities within android (sqlite) with Intel XDK (HTML5) as the rendering framework. I don't want it to a web based app, but a complete on the device app.
Can i code server side on XDK (server side code and database connections)
If not what should be my way of creating the server side component - build it seperately and somehow package it?
thanks in advance!
Yes, As per my knowledge Intel XDK is just your front end, to make a communication with your Master DB (MySQL, MsSQL, etc..) you need to have server side language. You can make use of PHP and it is a light weight server side scripting language, you can run it on XAMPP server.
Here is useful link.
To make connection with local (device) DB you don't need server side language and server also. Intel XDK itself providing feature to build the app for android (.apk) and IOS (.ipa) format.
So far I gone through and got, Intel XDK is providing list of four local database connectivity in client end. Which are
Local Storage
Web SQL Storage
Session Storage
Indexed DB
For more detail refer this link.
I'm not sure about Intel XDK with SQLite.
Yes,
You can work with SQLite in phone gap application.Please use the link to the Intel XDK third party plugin. Before that please download the project dependency jar file from GitHub and create the directory with cordova plugin SQLite name and place the file in it, include the jar file. Then try to add the plugin using URL.By this you can easily work with the SQLite in phone gap.
Also you can work with the server-side storage using Phone gap application. please see the link for sample.
Hope all helpful

Microsoft Access to web based format dynamically

I am sure there is a solution out there, but have not been able to locate anything that achieves the exact specifications I need.
I am looking for a web based script/application that can convert a MS Access database to text/csv any form of readable file.
The reason I need it to be web based is that our management currently uses an access database software package to create and track user data. They export a subset of the tables required for user registration (via a mdb type saved as a different extension). This is currently processed through the software providers website. The problem being that the software provider no longer provides developmental support for the registration forms.
We do not wish to change the entire foundation of the Access database and if at all possible I just want to provide a solution that opens and converts the uploaded file (mdb type) and converts it to a text schema, or anything really that will enable us to dynamically generate web based forms for the tables uploaded.
Well you certainly could cobble together something yourself.
However the hosted web site would for all practical purpose have to be running something like ASP.net and ALSO support the reading of mdb/accdDB files.
I mean most web sites that support the JET/ACE database engine in 99% of the same cases also support .net code.
If you're running your own web server and especially asp.net then this should be no problem.
However you don't mention if this is your own web server or a hosted one? And you don't mention what kind of hosting you have?
Remember your web site runs on a computer. That computer could be a Mac computer, a windows computer or Linux. And you simply install software + programs onto that computer like a desktop computer.
If that computer is Linux based then you not going to be able to install say your vb.net software on that web site. So what kind of computer and OS your web site is running on will DETERMINE what kind of software it will run.
If your site is currently an asp.net hosted site and they support reading of Access files (has support for JET/ACE) then I don't see why a bit of vb.net (or c#) application could not be written with little effort to have that file uploaded and then the contents read.
I think before go looking for some software to do such a conversion I would FIRST find out and figure out what computer platform your web site is running on now. You THEN need to find out if that computer hosting the web site has support for JET (now called ACE) data engine.
It is a walk in the walk in the park to have some code open + read the mdb or accDB file and send that data to the web sites SQL server. However you can ONLY do this if your site in question has support for the JET/ACE database engine. (or you have your own server and you are ALLOWED to install the JET/ACE engine).
So a solution program (off the self) does exist then AGAIN 9 out of 10 times such a solution will REQUIRE that the JET/ACE engine be installed on your hosted web site.
So just keep in mind that like windows or Mac computer or even a tablet computer – the web server is EXACTLY the SAME in regards to WHAT software will run on that web site.
So without knowing what kind of web hosting you have then it becomes rather hard to suggest a working solution that will be able to run + be installed on your web site since we don't even know what kind of software can be installed on your web site now?
If you current web hosting does not allow the JET/ACE data engine to be installed it is VERY unlikely that EVEN if you found some software that does a conversion for you then such software will NOT install on your existing web site.
Any competent asp.net developer should with quite ease allow one to select a local mdb file, upload to server and then have web code open up the mdb file and pull out table data to sql server.
The only real thing stopping this process is as noted what kind of web server you have and what kind of software it will run.
Keep in mind the issue is OFTEN what kind of software you can install on the web server.
Just about every web provider allows managed code (c# or vb.net) code to be up-loaded on the server to be run. However installing NON managed code like the JET/ACE database engine is a VERY VERY different matter.
Starting point:
You need a web provider that supports the JET/ACE database engine or you need to be running your own web server that allows you to install the JET/ACE database engine.
Furthermore how would the software you install know the table names in Access and also know the table names in SQL server and also where to send the data?
At the end of the day all of the software bits and parts rather common exist if you have your own ISS server with asp.net. And if your provider is using asp.net AND ALSO supports JET/ACE then AGAIN you have all the software required.
As such then your code can use ftp or even HTTP to upload that file. All of these features are built into the .net framework assuming your web hosting provider allows asp.net + JET/ACE.

Windows App with mySQL Backend

I am trying to design a database application for my small business. I've created a number of form driven MS Access databases for use before but would like to create a permanent solution in something more advanced & common.
I was thinking of using mySQL for the database and would then program a C# or VB application to be used in Windows. I do not want or need a web based version at this time but the migration to VB.net in the far future may be something I'll look into.
I know I can use a MS Access backend for my windows application without having to install MS Office on any or all the computers the program will be run for.
But here is my question. Is it necessary to install mySQL Server on the PC hosting the database, on all the PCs accessing the database or can I just use the database file as the backend and Visual Studio will have all the necessary tools I need to access it?
If I have to install the server I may just stick with the MS Access database as the needs for an excessive amount of database storage won't ever be an issue.
You'd need to install MySQL server on the Server hosting the database. The clients would then connect via the network. You will however need a driver to access the MySQL-Server with VB.NET on the client machines. A simple DLL-File might be enough, though.
If you are looking for a file-based database solution have a look at SQLite. But you will have to watch out for concurrency issues here.

Flash Application with local database (not sqlite, not air)

I would like to have a Flash Application (not air) to connect to a local database.
Air is not only getting unsupported by Adobe in LINUX but besides, it has serious problems and miss implementation with SQLite.
So we want to connect to a local MySQL database.
This application should be simple, so we do not want to also have an unnecessary web server (also local) to make a middle communication between the flash app and the MySQL server.
There is this driver that allow to communicate Flash with MySQL
http://code.google.com/p/assql/
Question is:
Is this the best approach?
Would it be any problem using this approach when installing the whole application to each client? (because we also in the installation should install a MySQL server).
A MySQL SERVER is called a SERVER for a reason: It is meant to be installed on servers, not on clients. So the answer to your question is:
1) No, this is not the best approach. Not even close. You would be better off using a SQLite database (however shitty you may think it is)
2) Yes. Nobody would like installing a MySQL server on their computers just for the sake of running your application. Think of casual (non-expert) users who would need to install and configure the server just for running your app. That is the very REASON why they developed SQLite and so many languages support it.
You should check out http://code.google.com/p/air-sqlite/ for sqlite access in AIR (I don't know if this is the same as the inbuilt code or not, so just check that out)

Bundling MySQL with an application

There are alot of applications like MAMP, WAMP, etc. That come with a version of mysql that needs no installation and can be turned on and off easily. I am trying to create a web based application that will use a mysql database, where do you get mysql to bundle and how is it done so the user doesn't have to install it?
you can get it mysql
http://dev.mysql.com/downloads/
you can used php, ruby (rubyonrails) or java for developed application. in the case php install xampp.
MAMP, WAMP, etc. all have a bunch of configuration that is already set up for them. Essentially they've installed MySQL and everything else included under a single directory that doesn't rely on anything outside that directory and then zipped it up together. I'm not sure exactly what you're trying to do, but that really seems like overkill. May I suggest checking out sqlite? It's designed for bundling and embedding and will be quite a bit easier to deal with.
Are you truly creating a Web Based app or are you wanting to create a desktop application using web scripting languages?
If you are creating a web app, you shouldn't need to bundle MySQL since when you deploy to your hosting environment it should already be in place. If you truly need to package everything you'd be best off offering your software as a virtual machine appliance with the appropriate services already configured and running.
If you are creating a desktop app, that's a whole other issue.