Will it involve me having to write a web service to handle the transactions?
Yes, if the database is not on the device, you will have to access it with network requests, which will have to handled by something.
what would that involve?
That depends on a lot of things. You can write a web service in pretty much any language you want as long as the server hosting it supports it. You could you Python, Ruby, PHP, Perl, Java, or .NET (if you have the framework) to name a few. Handling the actual database requests would have to be done on the server, which would return data back to your app - probably as JSON.