Web applications for coding database

This is somewhat confusing on my part to explain here. When I try to learn a new language, I will continue some of these steps:

1) simple world programs hello, mathematical programs, counter programs

2) interaction between pages, receiving data (RSS / Atom) from other websites using their API.

3) saving or manipulating data (mysql / postgresql you can say as a database).

Now the third part of data storage and processing is a bit confusing for me. and it looks like I can't figure out the coding. perhaps the developers are blocking. but I want to know how I can visualize this structural way, so that database programming applications look easy, and I can go forward without fear of communication with the code and the database. I mean, regardless of the language used, the steps to create a database web application are quite typical (drivers / table data retrieval / save, etc.), but I cannot visualize it.

For example, how can I create an application that stores some information, such as an address book, using JSP / Servlet or PHP. What steps should be taken before creating web applications? Hope my question is clear.

+3
source share
3 answers

I always found the data access material quite tedious, so I try to make a good abstract level of data access that does most of the work for me. A typical database call looks like this (and I think it works for most web-oriented platforms):

  • create and open a database connection
  • create database command object
  • tell the object what you want to do (for example, give it an SQL command or the name of an executable stored procedure)
  • provide the object with the necessary parameters for the task (i.e. first name, last name, address, city, state, etc.).
  • run the command
  • do something with the results
  • at some point, perform a cleanup (delete objects, complete a database transaction, close the connection, etc.).

, . , , "ExecuteStoreProc" "ExecuteSqlStatement". , , .

+3

, , . , SQL, , (, PHP, ) , SQL- ( , SQL ).

- , , ( SQL).

+1

- "Framework", "Language". , -. - Model-View-Controller (. ). , .

Ruby on Rails Django, . , . , -, . Rails RailsCasts.

+1
source

Source: https://habr.com/ru/post/1713525/


All Articles