O
O
OmgOmg052020-01-08 22:56:27
Database
OmgOmg05, 2020-01-08 22:56:27

How do applications eventually communicate with the database server, pass the query text to it, and get the result?

That is, what is under the hood api that are provided for different languages. If possible, a link to an article or book where this can be described. Tried to find in documentations of different relational DBMS, but did not find
Perhaps there is some protocol?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
K
Konstantin Tsvetkov, 2020-01-08
@tsklab

ADO for example.

B
BasiC2k, 2020-01-08
@BasiC2k

The direct connection of the application to the database that you are advised above is possible, but not secure. An attacker can extract connection data from the application and execute arbitrary queries in the database.
The normal practice is to use the API. For example, hosting has a database. Scripts are also placed on the hosting to interact with the database (in php or js, it doesn’t matter). These scripts receive information from the outside and execute certain queries to the database. Those. they should return strongly typed information for strongly typed queries. This is called the API.
The application sends a request to such a script. The request usually contains a token that confirms the legitimacy of the user. The script determines what actions need to be performed, and after receiving data from the database, it sends a response to the application (for example, in json format). Further, the application already uses this data according to internal logic.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question