Learn Courses My Dashboard

Looking for Current options for Swift and SQL

I am very new to iOS development…I have a SQL Database that I have built over years and currently have a web front-end. I would like to offer a App in addition to the website. When searching on to use SQL with Swift, most of the information I am finding is dated. Is PHP API still the best way to do this? Are there other ways to accomplish this?

Do you not already have an API that fetches data from the database?

You can use Vapor (a server sided swift framework) to create an API to fetch from a SQL database

My current site is developed in Visual Studio and calls directly to the database. Based on your suggestion, I started looking at Vapor…it seems to support PostgreSql, MySql, and Sqlite, but not MSSQL. Is that true, or have I missed something in their documentation?

You mean MSSQL as in Microsoft SQL Server?

If so, you’re correct, at the moment that isn’t supported, you could create an issue, because Vapor is open-source, to suggest that it is added

Otherwise I’d suggest creating a WebAPI project with C#, which is just an API that your iOS app can communicate with