Git Product home page Git Product logo

cs9dotnet5's Issues

Typo in chapter 5, page 180

Topic: Positional Records.

There seems to be a difference, possibly a typo in Records.cs within the book.
"data class" was used as a keyword instead of "record"

Typo on pages 120-121, chapter 04

The Fibonacci sequence at the bottom of page 120 ends with "21 34 65" instead of "21 34 55". This is repeated in the first sentence of the next page where the next term is given as "34 + 65".

Error on pg 116

Just an FYI in case you reuse the factorial example. 0! = 1 not 0.

Page 505 small syntax inconsistency.

Thru out the book the syntax for writing substructures are mentioned in the convention
Whatever
{
some stuff
}

on 505 however this is broken as it uses
Supplier = new[] {
stuff..
}

not a critical issue but for consistency you might want to adjust this.

Page 391

Not sure if the problem is a subtile security update in EF Core as ive tried it using both the code on the git/book and latest EF Core also.

The Example on page 391 will return 0 rows as the expression $"%{input}%" is used, this issue is due to Escaping but can easily be corrected with $@"%{input}%"

Page 506 - NorthwindWeb.Pages.SuppliersModel or NorthwindWeb.RazorPages.SuppliersModel

Fantastic book! I'm really enjoying it.

I entered the code on page 506 - Chapter 15 for the suppliers.cshtml file. The book shows the second line:
@model NorthwindWeb.Pages.SupplierModel

Autocomplete changes Pages to RazorPages.
@model NorthwindWeb.RazorPages.SupplierModel

The original code from the book will not run on my machine with "Pages". I have a slightly later version of .NET Core and VSCode than that used for the writing of the book.

Jeff

Page 40 - errata

Don't mean to be pedantic but carriage-return should be replaced with "line terminator".
Especially considering that carriage-return doesn't put the cursor on a new line at all (that's line-feeds job for linux and CR+LF for windows)

Question on the exercises

Hello,

I've really enjoyed the book so far but as i am new to C# i can't seem to find a solution to exercise 15.3 and have struggled through some previous exercises.

Are there practical examples of the additional exercises anywhere?

Is there an official C# code style?

I wrote my code in my own style different from yours style.
For example i wrote for loop as:

for (int i = 0; i < 100; i++) {
    // some...
}

But you wrote it as:

for (int i = 0; i < 100; i++)
{
  // some...
}

Too many different:

  • The curly brackets every at new line.
  • The indent of 2 spaces instead of 4.

I need some official coding style.

Suggestion for improvement regarding csproj files.

Many chapters of the book point out how to manually alter the csproj file to add references to packages or other projects.
However its never mentioned that you can utilize dotnet command lite to add these, and by doing so skipping the dotnet build step as the package is downloaded with the add package argument.

example
For Package references "dotnet add package Microsoft.EntitityFrameworkCore"
For Project reference "dotnet add reference ../NorthwindContextLib/NorthwindContextLib.csproj"

Error when executing the Northwind.sql script

Hi,

When creating the Northwind sample database for SQLite with the .sql file (sqlite3 Northwind.db -init Northwind.sql), I get an error in Visual Studio:

-- Loading resources from Northwind.sql
Error: near line 7: near "<": syntax error
Error: near line 36367: near "<": syntax error

SQLite version 3.36.0 2021-06-18 18:36:39
Enter ".help" for usage hints.
sqlite>

I found a second script in the "cs9dotnet5/Chapter11/WorkingWithEFCore/" folder with remark "fix SQL script", but same thing...

Any idea what's happening?

Thanks and kind regards,

Björn

.NET Core Launch (console) (Debugging) - Windows 10 not available?

Good evening,

on my system the option ".NET Core Launch (console Debugging)" is not available , as it is quoted on page 124.
Never the less it is possible to debug the project with the option ".NET Core Launch (console)".
Is it a configuration "problem" of the system?

The configuration: Windows 10 V20H2, .NET 5 Version 5.0.101, Omnisharp: 1.23.8, VS Code 1.52.1.

sqlite studio Could not add database with Northwind.db

Issue Description

@markjprice
i'm beginner with sqllite , i follow the steps in the book ( ch11 - Working with EF )
when i try to init sqllite database it gave me this error

image

and when i tried to opened the database with Sqlite studio
image

Steps i Follow

the problem i notice when i opened the database file with notepad ++ i't look like this

image

i try to copy the statement from github to be like this

image

finally

same error still appear

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.