+ 3

How to connect sql database in JavaScript?

makeing connection and send and recive data

1st Jul 2018, 12:45 PM
Gajarajan K
Gajarajan K - avatar
3 ответов
1st Jul 2018, 8:29 PM
\__(° = °)__/
+ 4
Hello, Gajarajan K ! There is no good solution on web browser side which will allow you to work with all browsers. There are many disadvantages to work with database on browser site. First of all, you show your database structure and it is very dangerous. Imagine, how easier is to make SQL-injection while you know tables and fields? You have to establish connection in some way using password which will be shown to third party users. Or you have to set password-less connection, which is also dangerous. When you establish connection with database, somebody can easly execute own query what is trivial, because you are showing your structure. I strongly recommended you to not do it on browser side. https://stackoverflow.com/questions/16481810/how-to-connect-to-database-in-javascript https://stackoverflow.com/questions/857670/how-to-connect-to-sql-server-database-from-javascript-in-the-browser
1st Jul 2018, 1:05 PM
Alexander Sokolov
Alexander Sokolov - avatar
+ 2
thank you for your kind explanation
1st Jul 2018, 1:15 PM
Gajarajan K
Gajarajan K - avatar