If using LINQ to SQL is there any good reason to l

2019-07-03 21:50发布

I do understand SQL querying and syntax because of previous work using ASP.NET web forms and stored procedures, but I would not call myself an "expert" in it.

Since I have been using ASP.NET MVC and LinqToSql it seems that so much of the heavy lifting is done for me and encapsulated away at the SQL end that I'm questioning whether there is any benefit in continuing to top-up my knowledge of SQL queries or whether I'm better off focusing my "learning time" on other things.

Your thoughts?

12条回答
我只想做你的唯一
2楼-- · 2019-07-03 22:23

It is still important to learn SQL queries/syntax. The reason is you need to at least understand how Linq to SQL translate to the database behind the scenes.

This will help you when you find problems, for example something not updating correctly. Or a query performance needs to increase.

It is the same that you need to understand what assembly language is and how it eventually becomes machine language. However in all you don't have to be an expert, but at least be able to write in it and understand it.

查看更多
Animai°情兽
3楼-- · 2019-07-03 22:25

In my opinion, knowing SQL is more valuable than any vendor specific technology. There will always be cases when those nice prepackaged frameworks will not be able to solve a particular situation and knowledge of advanced SQL will be required.

查看更多
干净又极端
4楼-- · 2019-07-03 22:25

It depends what you're working on, and from what you said it might make more sense to focus on other areas.

Having said that I find knowing SQL allows the following:

  • The ability to write queries to extract data from systems easily. For adhoc queries, or for checking things.
  • The ability to write complex stored procedures, which allows me to group complex data processing in one place, where it should be, in the database.
  • The ability to fine tune LinqToSql by adding indexes, and understanding the SQL/query plan's it procedures.

Most of these are more of a help on more complex systems, so if you're not working on those it might not be as much of a help.

It may help in your situation to list the technologies which might be of use, and then prioritise them.
In order words make a development plan for yourself, which may encompass more then just learning technical knowledge but allow a more broad focus like design patterns, communication skills and other areas.

查看更多
迷人小祖宗
5楼-- · 2019-07-03 22:33

Sooner or later you will run into problems that need at leat a working knowledge of SQL to solve. And sooner or later you will run into requirements that are best realised in the DB (whether in SP-s or in triggers or views or whaterver).

查看更多
劳资没心,怎么记你
6楼-- · 2019-07-03 22:38
  • You may not always be working in .NET.
  • Doesn't hurt to know the underlying concepts.
  • LINQ to SQL is not being maintained anymore in favor of the Entity Framework
查看更多
趁早两清
7楼-- · 2019-07-03 22:40

LINQ To SQL will only work with .NET. IF you happen get another job where you are not working with .NET, then you will have to go back to writing Stored Procs.

Knowing SQL will also give you a better understanding of how the server operates as well as possibly making you a better database designer.

查看更多
登录 后发表回答