any one who try to connect postgresql with xcode for ios application? What should i try? what do you suggest?
any one who try to connect postgresql with xcode for ios application? What should
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The usual approach is to avoid making a direct connection but to route everything through an HTTP based API.
The iOS application then only needs to perform HTTP requests and parse the responses (which you can format using JSON).
You can write the HTTP API in the server side language of your choice.
It is possible to connect directly to the database, but you would have to write or otherwise acquire a Postgresql client library for iOS (which appears to exist, thanks Craig) and expose the database on the network (if the iOS application is going to connect over the Internet that means exposing the database directly to the Internet, which is generally considered to be a Bad Idea).