Dzoukr / Dapper.FSharp

Lightweight F# extension for StackOverflow Dapper with support for MSSQL, MySQL, PostgreSQL, and SQLite
MIT License
365 stars 35 forks source link

namespace 'LinqBuilders' is not defined #81

Closed diegopego closed 1 year ago

diegopego commented 1 year ago

Hi! I got this message error FS0039: The namespace 'LinqBuilders' is not defined

Program.fs: open Dapper.FSharp.LinqBuilders

paket.lock

STORAGE: NONE
RESTRICTION: == net7.0
NUGET
  remote: https://api.nuget.org/v3/index.json
    Dapper (2.0.123)
    Dapper.FSharp (4.3)
      Dapper (>= 2.0.123)
      FSharp.Core (>= 6.0.7)
    FSharp.Core (7.0)
    Microsoft.Extensions.Logging.Abstractions (7.0)
    Microsoft.NETCore.Platforms (7.0)
    Microsoft.NETCore.Targets (5.0)
    Npgsql (7.0.1)
      Microsoft.Extensions.Logging.Abstractions (>= 6.0)
    SqlHydra.Query (1.1.1)
      FSharp.Core (>= 5.0.2)
      SqlKata (>= 2.4)
Dzoukr commented 1 year ago

Hi, did you just update from some old version?

diegopego commented 1 year ago

Thank you very much for you reply!

No, It is a fresh new project. To be sure. I created a new empty project

OS: Windows 11

dotnet new console -lang F# -o test --framework net7.0
dotnet add package Dapper.FSharp

dotnet --list-sdks
5.0.415 [C:\Program Files\dotnet\sdk]
6.0.405 [C:\Program Files\dotnet\sdk]
7.0.102 [C:\Program Files\dotnet\sdk]

I tried with 6.0 and the same error occurs. dotnet new console -lang F# -o test6.0 --framework net6.0

image

image

Dzoukr commented 1 year ago

And why do you need them? 🤔

diegopego commented 1 year ago

I'm testing SqlHydra and Dapper example https://github.com/JordanMarr/SqlHydra/wiki/DataReaders#dapper

Dzoukr commented 1 year ago

I seeeeeeee. 😄 Yup, it's an old example - please just use what's in this repo README and it should work ok.

JordanMarr commented 1 year ago

Yup, just delete the open Dapper.FSharp.LinqBuilders line and you should be good to go! (The LinqBuilders were moved into the main Dapper.FSharp namespace.)

diegopego commented 1 year ago

Thank you again! I'm an FSharp beginner. I'm finding it hard to take off with the README and current tests, would you mind if I try to create a beginners HOWTO and make a PR? Also, may I please ping you if I'm in deep trouble while doing it?

Dzoukr commented 1 year ago

Welcome to the best community EVER, bro! 🎊 🎆 🥳

Sure, feel free to send any improvement! 👍