Solution: Back-End Development Challenge in C#

Поделиться
HTML-код
  • Опубликовано: 18 сен 2024
  • On Tuesday, I issued a challenge to build a data capture system in C#. Hopefully, by this time you have been able to build that system. If not, take the time to finish up your project before watching this video. Today, I am going to walk through the process of how I would tackle this challenge. Part of this process will be about knowing what steps to take next even as I complete the actual challenge. So let's get started building our back-end solution.
    Full Training Courses: IAmTimCorey.com
    Source Code: leadmagnets.ap...
    Mailing List: signup.iamtimc...

Комментарии • 39

  • @cirezno5960
    @cirezno5960 Год назад +4

    I learn a lot from your precious tec teaching.
    I learn from you : doing things good.
    Thank you again Tim C. 🇫🇷

  • @torrvic1156
    @torrvic1156 Год назад +3

    Brilliant! I sincerely believe that you are the best teacher of C# on the whole RUclips (or maybe in the Internet itself). I learned so many things from you dear Mr. Tim Corey! Texas and US must be proud to have people like you living in it!
    Mr. Corey, can you recommend me a video where you do a CRUD operation of creating some record in some relational database in a child table (Purchases for example) and where table column with foreign key (CustomerId for example) automatically binds to a value of Id (Primary Key) in the Parent table (Customer for example) and sets this foreign key automatically appropriately to the Parent table Primary key? I am pretty sure that you did something like this but I failed to find it. I am really struggling with it and only managing to create record with NULL foreign key column.
    And thank you so much again!

  • @rameshshinde1193
    @rameshshinde1193 10 месяцев назад

    As a total newbie in C# and Dotnet this solution taught me a ton of concepts all at once. Thanks Tim! I wish something like a course which starts with simpler concepts teaching C# and dotnet and slowly with increasing complexity with the final result of a real production type application creation integrating all the concepts without teaching each concept in silos would be of great help.

    • @IAmTimCorey
      @IAmTimCorey  10 месяцев назад

      That would be the C# Mastercourse ( www.csharpmastercourse.com/ ).

  • @thefattysplace
    @thefattysplace 11 месяцев назад +1

    Dapper looks pretty good, will have to look into that. I spent way too long writing my own custom classes to access the database (just using SQL client dependency). Probably should have used a stored procedure too to check for existing callers (did my checking class side and posted back of there was a change detected) which would have ment less database calls.

    • @IAmTimCorey
      @IAmTimCorey  11 месяцев назад

      I am glad it was helpful.

  • @thomstunes6485
    @thomstunes6485 Год назад +3

    Never heard about the upsert technique ! Thanks Tim !!! I usually do that on the C# side of the project and I guess that it's way quicker when it's done by SQL itself.

  • @user-tj3gn1mr8c
    @user-tj3gn1mr8c 6 месяцев назад

    Thanks a lot Tim, btw do you have video about model relationships(one to one...), I am using Entity Framework for that, It is bit uncomfortable, watching you creating procedures and using dapper seems interesting and more clear, at least some information from you about using this two methods(their pros and cons) will be really helpful

  • @rikudouensof
    @rikudouensof Год назад

    I missed the challenge. Had too much work to do. Thanks for the video.

  • @ml210993
    @ml210993 10 месяцев назад

    Hmm, joined the challenge a but late, did the challenge a bit different... Used Api project and included Entity framework migrations with sqlite. So Api project is used to access database.

  • @chrisjohansson9971
    @chrisjohansson9971 Год назад

    Question regarding your upsert. Do you normally just update all parameters even though say one columns data changed from the front end in a row of 10 columns. So either tracking changes by "isdirty" and building an update string
    on those columns or comparing columns that are passed in to update to what is in the database and then building a sql string to update only what has changed?

    • @IAmTimCorey
      @IAmTimCorey  Год назад +1

      In most cases, it is simplest to update all values that could change. Trying to track the dirty status and then forming specific queries to handle each case or doing dynamic queries (which can cause performance problems) just isn't worth it for most scenarios.

    • @chrisjohansson9971
      @chrisjohansson9971 Год назад

      @@IAmTimCorey could be an issue for applications that have concurrency and high volume of users plus speed.. but i guess depends

  • @nitrodaxsgg9919
    @nitrodaxsgg9919 Год назад

    New coder here!
    Would highly appreciate it if someday you have the time to create a step by step tutorial for making a portfolio website.

    • @IAmTimCorey
      @IAmTimCorey  Год назад +1

      We build one of those in here: www.webdevelopmentmastercourse.com/

  • @nilswierling5899
    @nilswierling5899 Год назад +1

    I was going with EF Code First - do you think your Solution has benefits compared to ef code first approach?

    • @RebelliousCanadian
      @RebelliousCanadian Год назад

      I think it's a subjective answer. I personally like and went the EF route but you are relying and EF and if it breaks, do you know how to fix it. Tim Cory has a video explaining more why he doesn't really like it. Plus Dapper is still faster, esp. with the stored procedures this method enforces.

  • @kandycan
    @kandycan Год назад

    I saw this video just today. I would have definitely participated in this one if i saw it earlier. I'll be participating in next one. What i am thinking about is that it's a good initiative. I think we can have such weekly and monthly challenges and at the end of the challenges we can discuss different approach people came up with and why or why not some approach is good or bad. Right?

    • @IAmTimCorey
      @IAmTimCorey  Год назад +1

      You can participate at any time. You didn't have to do it in real time. As for sharing approaches, I don't have a system for sharing solutions in place.

  • @michelchaghoury9629
    @michelchaghoury9629 Год назад +1

    can you make a c#/NET tutorial for experienced Java/Spring developers?

  • @ahmedifhaam7266
    @ahmedifhaam7266 Год назад +1

    Why not use guid? And when to actually use guid

    • @IAmTimCorey
      @IAmTimCorey  Год назад +1

      It would take a video to properly answer. However, here are some basics. First, an int is easier to refer to and remember. Second, an id is somewhat more performant. Third, an int takes up less space.

    • @ahmedifhaam7266
      @ahmedifhaam7266 Год назад

      @IAmTimCorey thank you, I think it'd be a very good video to have, more videos related to design.
      About guid, the advantaged I can think of are, no reference issues ever with duplicate record etc. A little bit safer, in case there was an unprotected API, attacker cant just do 1,2,3 and get admin records..And to generate a new guid you can do it on backend instead of going to db, and it's just extremely unique. But these are the only advantages I know.
      But I see a lot of new projects even small ones using guid as pk in tables lately so I was wondering if I am missing out on something or if it's not a sql server thing and preferred in other databases like postgresql.
      Genuinely really curious about this and it's hard to find information online and, thanks tim.

    • @IAmTimCorey
      @IAmTimCorey  Год назад +1

      Thanks for the suggestion. Please add it to the list on the suggestion site so others can vote on it as well: suggestions.iamtimcorey.com/

  • @XphosRed
    @XphosRed Год назад

    Nice vid mate

  • @isaacohibor3278
    @isaacohibor3278 10 месяцев назад

    Great

  • @joannagechanfon4770
    @joannagechanfon4770 Год назад

    You are the best

  • @澳贼
    @澳贼 Год назад +3

    first

    • @UnclaimedClock
      @UnclaimedClock Год назад +3

      No one cares.

    • @YashTrivedi21
      @YashTrivedi21 Год назад +4

      ​@@UnclaimedClockI do. I am the guy who cares

    • @澳贼
      @澳贼 Год назад

      if u dn't care, no need to reply@@UnclaimedClock

    • @IAmTimCorey
      @IAmTimCorey  Год назад +10

      It is actually helpful for telling RUclips the video should be shared more, so I care as well.

    • @澳贼
      @澳贼 Год назад

      @@IAmTimCorey