omnibill 0 Posted April 20, 2023 I am using CBuilder 11.3 Professional. Is there any way I can make a mobile phone program to allow multiple phones to read a table on a server database. Is the only way to do this is to upgrade to Enterprise version. I have a VCL windows program that I have uploaded data to a MySQL database but I could use some other type of database. Bill Share this post Link to post
programmerdelphi2k 237 Posted April 20, 2023 (edited) yes, you need use some type of strategy like: 3 layers (read about this) 1 server database (for example, Interbase, Firebird, MSSql, Oracle, etc.. any one other, in any PC (Windows/Linux/macOS) using TCPIP communication 1 app in Delphi or not (App2 VCL or FMX since that it stay on PC for example, +TCPIP communication), (in the middle of the way) app between server and app client, to access your database server 1 app client delphi (FMX to mobiles, using TCP/IP) or not to access, to access App2 so, all request will be done that way: App client -> App2 -> Server DB or using DataSnap, RAD Server, Mormot, Horse, or any other framework to JSON requests DataSnap and RAD Server cames with Delphi, DataSnap is free, RAD Server needs license and Interbase license! I think that no, needs contact Embarcadero and buy a new subscript to CBuilder Enterprise or RAD Studio Enterprise (+6000$) you target Database can be any one, since you can export old database to new database and fix your VCL app to use it! at general, changes to another system, it's complex and need many works, but it's possible for sure! Edited April 20, 2023 by programmerdelphi2k Share this post Link to post
Sriram 4 Posted April 20, 2023 51 minutes ago, omnibill said: I am using CBuilder 11.3 Professional. Is there any way I can make a mobile phone program to allow multiple phones to read a table on a server database. Is the only way to do this is to upgrade to Enterprise version. I have a VCL windows program that I have uploaded data to a MySQL database but I could use some other type of database. Bill Bill, RAD Studio 11.3 comes with excellent connectivity for database applications using InterBase. IBLite (an embedded database, freely deployable) license is included in "Professional" edition as well. If you have a licensed InterBase Server Edition running on a remote server, you can build Mobile database applications to run on iOS and Android, and also other desktop applications running on Windows, macOS and Linux with either FireDAC or IBX to work with InterBase. Simply include the IBLite license and (Embedded ToGo library) to build your application. This library comes with a "client" portion that is capable of connecting to remote InterBase servers running on the network using the regular TCP/IP based database URL, <remote_hostname/IP>:<database_filepath> This will allow your need to have multiple phones read a table on a server database just fine. No intermediate layer of software required. The InterBase client API is the same for Server and ToGo Editions, and is thus compatible for your purpose as well. Share this post Link to post
tgbs 14 Posted April 20, 2023 I wouldn't open up a database to the entire internet Share this post Link to post
Sriram 4 Posted April 20, 2023 4 minutes ago, tgbs said: I wouldn't open up a database to the entire internet That's a fair assessment. You'll need to take any and all precautions before making opening your database for global access. In the original question from Bill, I did not see "public" internet apps usage mentioned. There are also many use cases for Enterprise or within the firewall (VPN) use of mobile applications (running on phone/tablets etc.) accessing an internal server database. In addition to the aforementioned RAD Server and other technologies for the middle-tier, which InterBase nicely fits in the backend as well, here is another InterBase specific solution. Use IBToGo (Embedded) library, same as IBLite but with license requirement for deployment for RAD Studio Professional customers. https://www.embarcadero.com/products/rad-studio/product-editions With IBToGo, you get a few additional features and other limitations from IBLite removed. One such feature is encrypted C/S communication via SSL. So, you can also use a SSL based connection from your IBToGo application running on the Mobile devices, connecting to a secure port on your database server on a remote machine with InterBase. Share this post Link to post
Vandrovnik 214 Posted April 20, 2023 IBX components allow you to connect to Interbase server, with some effort to Firebird server, too. Share this post Link to post
omnibill 0 Posted April 20, 2023 Thankyou, I will try to figure out how to set up a Interbase server. Share this post Link to post
Fr0sT.Brutal 900 Posted April 21, 2023 (edited) 16 hours ago, omnibill said: Is the only way to do this is to upgrade to Enterprise version. What is the concrete limitation of the version? +1 against direct DB access, DB servers are not intended to be publicly open. There's plenty of ways to shut them down even with anonymous access. Moreover, mobile => unreliable data channel => you'll get enough pain of lost connections with data access components. Edited April 21, 2023 by Fr0sT.Brutal 1 Share this post Link to post
marsupilami79 8 Posted April 25, 2023 (edited) On 4/20/2023 at 5:43 PM, omnibill said: Is there any way I can make a mobile phone program to allow multiple phones to read a table on a server database. Is the only way to do this is to upgrade to Enterprise version. Additionally to attaching Firebird to the internet you could try the Zeos Webservice based Proxy driver included in Zeos 8.0: https://sourceforge.net/p/zeoslib/wiki/WebServiceProxyDriver/ It allows you to access any Zeos supported database from mobile devices. To increase security it allows adding 2FA to your regular database logins. Also it uses http and session ids so sessions can survive intermittent connection losses. It doesn't support SSL directly (yet), so for exposing it on the internet you would have to use Apache or some other server as a proxy. Edited April 25, 2023 by marsupilami79 Testing to make an URL work... Share this post Link to post
omnibill 0 Posted April 26, 2023 You cannot do much with the Professional version of the software. I think Interbase too much for my application. I am looking into using TCP server and client to connect to a program that connects to the database. People will need to be in the same building as the database to use it. The information in the database is not very important. It only contains date and time data and some room numbers of a building. Share this post Link to post
programmerdelphi2k 237 Posted April 26, 2023 (edited) Firebird is "almost" than Interbase Firebird came from Interbase 6 when open-sourced Firebird is reliable, and multi-user server (there is limit on database, basically your system) Firebird is supported in many platforms and languages: http://firebirdsql.org/en/features/ https://firebirdsql.org/en/sql-conformance/ Firebird supports a number of hardware and software platforms: Windows, Linux, MacOS, HP-UX, AIX, Solaris and more. (now in Android embedded it's possible too) It runs on at x386, x64 and PowerPC, Sparc and other hardware platforms, and supports an easy migration mechanism between these platforms. Firebird is included into the following Linux repositories: Fedora, OpenSuse, CentOS, Mandriva, Ubuntu. Firebird is supported by numerous database connectivity options: Firebird.NET JayBird (Java) Delphi/C++ Builder drivers (Embarcadero Delphi/C++ Builder IDEs include dbExpress drivers to work with Firebird.) // FireDAC FB and ODBC ! FreePascal & Lazarus PHP for Firebird FireRuby and more! Firebird is really free for usage (commercial or not) Firebird is powerfull and open-source: for more details http://firebirdsql.org/ Firebird it's really easy to use and learn! you dont need a big server, ok, run it in a 386 and TCP/IP network! Edited April 26, 2023 by programmerdelphi2k Share this post Link to post
marsupilami79 8 Posted April 27, 2023 16 hours ago, omnibill said: You cannot do much with the Professional version of the software. I think Interbase too much for my application. I am looking into using TCP server and client to connect to a program that connects to the database. People will need to be in the same building as the database to use it. The information in the database is not very important. It only contains date and time data and some room numbers of a building. Hello Omnibill, I use the Professional version of Delphi to do exactly what you want to do - I can enter some numbers into a database from mobile devices. Using Zeos I can decide wether the Zeos Proxy Server is a better choice or Firebird. I think that doing your own server will leave you in the worst of all places: You have to do all the maintenance yourself. By choosing Firebird or Zeos Proxy you can rely on work that is tested by others and you can concentrate on what is your core job - getting the mobile application to work. Zeos Proxy will allow you to attach directly to your MySQL database but will not give you connection encryption out of the box. For this you would have to add a Apache or IIS as a reverse proxy. Using a recent version of Firebird will give you an encrypted connection out of the box and you can continue to use FireDAC. Best regards, Jan Share this post Link to post
Lars Fosdal 1792 Posted April 27, 2023 @omnibill Don't access a DB directly over the internet. It exposes the DB and eventual vulnerabilities It binds your UI to the current DB model, instead of a general data model, making it harder to make changes to the DB without breaking the UI Use a REST server to hide the underlying database and communicate with API structures (JSON, BSON, XML, etc) adapted to your general data model It hides the actual structure of the DB - such as unique integers used for relationships, but which has no information content It prevents SQL injection attacks Using proper authentication models (OAUTH2), you avoid exposing DB internal users It allows server side sanity checks of incoming content It makes outgoing content access control more flexible You can allow third party to access your APIs You can change the DB on the backside of the API You can scale the DBs on the backside of the APIs 1 Share this post Link to post
AlanScottAgain 1 Posted April 29, 2023 Why not use FireBase an the the great FB4D 🙂 Share this post Link to post