SQL, Node, Express, and React JS 1/2 | ~How to Connect it all together
Вставка
- Опубліковано 11 вер 2024
- #coding #sql #reactjs
We're going to build a nice piece for your portfolio. Connecting SQL Server to a NodeJS / Express JS backend of a React JS app! Great for Computer Science degrees who focus on Data.
Venmo Me a cup of coffee:
@CodingWithKevin
My Equipment
🎥My Camera: amzn.to/3fS1hqY
📟My Computer: amzn.to/3uUEsHA
💻My Monitor: amzn.to/3poLB1w
🎤My Mic: amzn.to/3ilZOuW
⌨️My Keyboard: amzn.to/3x0zSZG
Webull for Stocks / Crypto
📈 Deposit $100, get 2 free stocks! act.webull.com...
For Crypto
🤑 Deposit $400 and get $50 in BTC! app.celsius.ne...
Referral Code: 184801bff
Health:
💪 Protein supplement www.gainful.co...
helped me, thanks. jic someone got the same problem as me: I got an "ELOGIN" error at first, even though I was pretty sure I was inputting my User Login Name and password correctly. What fixed it for me was checking the Event Viewer for a more informative error message, then I found out that SQL Server authentication wasn't enabled for my database; after fixing this setting on SSMS I had to restart SQL Server via the SQL Server Configuration Manager then everything went smoothly from there.
You should give your database server authentication permission.
Step 1) right click your server name ( window10\SQLEXPRESS)
step 2) select properties
step 3) Select Security
step 4) Under Server Authentication select SQL Server and Window Authentication Mode
@@danielgalbraith1457 Thank you so much this solved this issue for me. Been trying to figure it out for 2 days.
Extremely helpful thank you for explaining things so well.
It would have been nice if you provided a link to the video explaining making frontend and backend
Really helped me man! Exactly the things i want. 😄
Really good tutorial appreciated ,
Constructed feedback: Please increase the font size of your text editor 😃
... and we gonna do Pam...
love the tutorial!
thank you very much, it helps a lot!
It really helped me. Thank you very much Mr.Kevin!
You're very welcome! Thank you so much for watching! 🙏
благодаря тебе я все понял, спасибо чувак, твои видео восхитительны
this tutorial failed at 'npm run server' code: 'ETIMEOUT' i guess there is something to need to do what is not in the video
Superb exactly what I want
Greetings from Brazil. Tks!
Hey thanks so much for watching! All the way from Brazil 🎉🙏
Need to increase the font size on code to be more readable.
Thank you, I will remember that for my next video 🙏
I literally can not thank you enough ❤
You're very welcome! Thank you for watching 🙏
what i do not understand is if i host my website some where online how do i access the database i mean since the database is local?is there free platform that gives an online connection string???
Great video, thanks. I got distracted by your very nice-sounding keyboard lol
Lol thank you, it's a Drevo Caliber v2 keyboard. Saves my hands from carpal tunnel 😂
Awesome!
I followed your instructions to connect to sql on VMware and got the error: "E:\Learning
eact-sql
ode_modules\tedious\lib\connection.js:2104
request.error ??= error;
^^^". Please help me. Thanks you !
Does this configuration applies to accessing the sql server database remotely ?
can I use SQLEXPRESS TCP dynamic ports instead of TCP port, because the TCP port is blank :|
I fixed the issue, thanks in advance.
@@daifdriss9390 how did you fix it
Part 2 plz great video
You got it, coming this weekend :) thanks so much for watching!
I just wanted to ask, would this be a method of connecting Microsoft SQL to nodeJS or can this work with elephantSQL too?
Super Helpful!! I am having a connection "ETTIMEOUT" error going on similar to @spa.3239's error... will poke around server and make some changes. Thank you All!
Good video thanks :D Am a bit stuck but will fix it somehow
Thank you so much! 🙏 I'm sure you'll be able to find an answer. The art of Googling is a skill all developers should master 🎉
can we fetch and access stored procedure table data in reactjs application , could you please help me
what video are you referring to, to set up react for this particular project? edit: "The full stack coding challenge"
If you look in my channel videos you'll see one called full stack developer coding challenge 🙏 thanks so much for tuning in
When I tried to add a new user to the Logins, it woulden't let me set db_owner for the new user
Hey Crystal, thanks so much for watching! When I run into a problem like this, I open up Google and start searching for an answer. Typically stack overflow will have answers to a lot of programming issues. I would recommend you pop this into a Google search and let us know what you find if you find a solution! 🙏
I wish I could help, but like I mentioned in the video, there are way too many differences in peoples computers for me to be of any help. This could be a permissions thing, a installation error with SQL, or another random scenario that could be different on your computer than mine. That’s why the art of googling is such a valuable skill as a developer.
ca you share the repo?
I believe it is supposed to be instanceName, as opposed to instancename
Hey thanks for catching that 🙏 I appreciate you watching!
helpful
What video is he recommending? Please tag the video, I couldn't find it in the intro.
Check out the link here. Thanks so much for watching!
ua-cam.com/video/jzBgZjOJJnY/v-deo.html
Not iterate the data how to iterate the data in your video it's only one data only show in the browser
Hey there, I don't understand what you're asking.
I filter the data from SQL but browser show only one data ,second data not display, I'm using map function is not working, tell solution for me bro please
Great video, how would I use this in production on an IIS server? Would I replace nodemon with node start server.js? Silly question but when I remove nodemon and use npm start server.js no components like home or etc are being served?
thanks for watching! I believe the command is
node server.js
Let me know if that works! I'm sure others could benefit from that as well.
pleace make the text in the editor bigger
Thanks man this is worked for me. But I have a doubt, the data base details we provide is that visible in the browser window.
Hey there, I'm sorry, I don't understand your question. Can you ask it in another way?
@@CodingWithKevin1 sure Kevin, in the file dbconfig.js we have mentioned our server name and login credentials right. Is that possible to view those details in the browsers Console window?.
gotcha, yes, we definitely would not want to use that way of coding in any production release. you would want to make sure you set those as environment variables, but for the sake of this tutorial I did not go that deep so I could give the knowledge needed for this video
havinh problem with connecting to sql from node says connection error: login failed for user ..... code 'ELOGIN' but have copied your exact code, do you know what could be wrong?
Hey there thanks for watching, unfortunately I don't know. Everybody's machine is different and this might be something you'll have to do some searching for and work your way through with stack overflow. But please post your answer if you figure it out for anybody who might have this problem.
I had the same error message: Login failed for user And it turned out to be that I was not using SQL Server Authentication. So I right-clicked DESKTOP- (on the object explorer), then properties, then on Security I selected SQL Server and Windows Authentication mode. So that worked for me, I hope it might be useful for someone :)
Thanks for the video Kevin! I'm getting error while connecting to my database. Code is able to connect with sql server but fails to login my database. What could be wrong?
hey thanks so much for watching! Really appreciate you. Unfortunately like I said in the beginning of the video it's gonna be very difficult for me to troubleshoot problems. Your best course of action is to use Google and stack overflow to see if you can find others who have had a similar issue. and once you do find the answer, please share it in a comment here so other people can use your solution 🙏
Sure Kevin 😊 One more query, if possible, can you please tell which mssql version you used in this video?
yoyo nice video, i have an issue where i get the error Unable to resolve module stream from ...
ode_modules\mssql\lib\base
equest.js: stream could not be found within the project. Do you have any idea how to fix that?
Hey there thank you! Hmmm, it's hard to debug with you but I have a couple things I can recommend.
1. Delete node_modules folder and do a fresh npm install
2. Try setting up your sql server again or checking permissions as well to grant access to it from an external application (you'll have to google this)
3. Uninstall sql server, and maybe just start from scratch.
4. Google around, unfortunately there's too much that can be different between your system and mine. Maybe you can find someone in stack overflow to help.
5. When you figure it out, post your solution here! 🤙 Someone else might find it helpful.
@@CodingWithKevin1 for sure will do! keep up the good work! I can tell its new for you the whole youtube thing but you are doing great! ima check more of your stuff!!
forget the part where i say you are new, i saw that you made videos 2 years ago but yeah! keep the good work! subscribed
Right on, thank you a bunch! Always here for you guys and working on more stuff 🤙
Did not work and could not find the video before this
This is not working for me, I got the error "failed to connect to DESKTOP-CG9K2OC:1433 - self signed
certificate", despite I used " encrypt: true, trustServerCertificate: true, trustedconnection: false, enableArithAbort: true,"
Hey there, Thanks so much for watching! You heard me mention that everybody’s machines are different and have different set ups, so as developers we need to be really good at the art of googling. I’d recommend you search the internet for this error message and see what you can do from there
@@CodingWithKevin1 The problem is the solution that suppose solve the error is add "trustServerCertificate: true" but we already have it and its not working.
pd: good video and thanks for your time. Sorry for the bad English I'm from Rep. Dominicana
@@enmanuelruiz544 thank you, I appreciate your kind words. I hope things are well in Dominican public! if anyone else has a similar problem and has a solution, please comment here. In the meantime, again since there are such vast differences between machines and operating systems and system preferences, your best bet to find a solution is to try to keep going down the rabbit hole as much as you can by searching on the Internet. Unfortunately I don’t have a solution for you off the top of my head, but once you figure it out, please post the solution as another comment so other people who might run into it can use it :-)
@@enmanuelruiz544 Hi Emmanuel, I don't know if this is your case, but with me the problem was with SQL Server Configuration Manager. The port 1433 must be open there. The "Full-stack coding challenge" video from Kevin himself teaches how to do it right on the start. Regards...
I am also having this same error. We have a class of about 20 interns doing this tutorial as an assignment and the issue is all the same. Been looking everywhere for an answer. If one was found, please share.
Can u send the github repo of this projevt
Hey Rohan, I don’t have a github for my coding channel. However, going through this tutorial will give you a good project for your github
26:34 // dbOperation.createEmployee(Pam); code error sytantx help me ?
You probably fixed this by now, but I had the same error and I'll respond here for anyone else. I was using single quotes (') instead of backticks (`) inside of .query in dbOperations.js (pool.request().query('INSERT INTO...') vs. pool.request().query(`INSERT INTO`)). It took me a while to spot it, but everything worked once I caught that.