Advertisement

Is being more comfortable with SQL than C# says something about how your brain works?

Started by November 06, 2011 05:15 PM
9 comments, last by davepermen 13 years ago
I ask this because I work with both all the time. Actually I work with C# more than I work with SQL. However, when I work with SQL, I can pull up a query quicker than I can blink. Put a better way I can go from spec to algorithm to code far faster in SQL than I can in C#. So I'm wondering if any studies have been done on this. If my brain works a certain way or if I have a definite deficiency in coding knowledge that I am unaware of.

Has anyone else comes across a similar, but not necessarily the same, problem?


(Didn't know if this belonged in General Programming or Lounge. Felt safer to put here.)

Beginner in Game Development?  Read here. And read here.

 

Maybe it says something, but not about your programming ability in general.

The kind of set manipulation you do in SQL is quite similar to some functional styles of programming, IMO. Have you done any functional stuff in C#? Any LINQ?
[size="1"]
Advertisement
SQL is declarative. Perhaps this is the difference you are feeling?
SQL is a different kind of "programming". I've found that I've taken to it pretty well myself. I've went from never using MySQL before starting my current job to being the go to guy whenever more then more then a basic query comes up. I think my brain works better with relational data then trying to think of a procedural way of doing something.
It means you have brain cancer.

Seriously though, what they said. Take a look at LINQ. Its pretty cool.
I've used LINQ (query extensions, not lambda) and yes, It's very easy (not as easy as sql though) to use it.

Beginner in Game Development?  Read here. And read here.

 

Advertisement

Maybe it says something, but not about your programming ability in general.

The kind of set manipulation you do in SQL is quite similar to some functional styles of programming, IMO. Have you done any functional stuff in C#? Any LINQ?



SQL is declarative. Perhaps this is the difference you are feeling?

I'm wondering if it's the fact that it's set-based or declarative which is making it "easier" for me to program in it. Again, I have no idea, but it's just strange to me. So I wonder if it's an affinity to ... something or am I missing something.

Beginner in Game Development?  Read here. And read here.

 

Totally possible that you're just in a particular mental groove, sure.

I wouldn't put any serious worry into it, though. It's kind of like speaking Latin better than ancient Greek. Sure, maybe you fall into that pattern more easily, but... does it matter? Not so much.


(Unless of course you feel like it's getting in the way of your career or something, but I didn't get that impression.)

Wielder of the Sacred Wands
[Work - ArenaNet] [Epoch Language] [Scribblings]

I think I know what you mean. I find SQL to be more 'englishy' and follows the thought process of what my head is thinking. "Select all orders from the order table then group them by customer". Plus the end query is a lot more of a 'one layer' process, in that you run it, it returns data, you move on. At most if might be saved as a stored proc.

With C# though, every action feels like there could be 20 different ways of achieving the same result. You have to think of scope, where and what will instantiate it, proper method names, method signatures or initializers. All for possibly the exact same SQL you had which is now in LINQ. Working in SQL is almost relaxing sometimes because the scope of considerations comes down drastically. That's not to say SQL is easy, but it tends to be a lot more 'it works or it doesn't', and you can check that right away.

It might just be me, but working in C# is akin to building a house, SQL like laying the concrete. That might not make much sense, but to my odd brain it does >_>
It means you have a latent predisposition to schizophrenia.

This topic is closed to new replies.

Advertisement