Comments (10)
I think here is collision with linq2db's IsNullOrEmpty
function. We already have this extension function but not mapped to SQL https://github.com/linq2db/linq2db/blob/master/Source/LinqToDB/Common/Tools.cs#L42
from linq2db.linqpad.
Tried it with linqpad 5.40.0 - still works for me.
Only possible fail point I can see now - you load diffrerent version of linq2db for My Extensions
compared to version, used by linqpad provider. Try to reload it using F4 in My extensions
file (extension use linq2db v2.9.1, if you have latest version).
from linq2db.linqpad.
Well, yep that was it! My Extensions was using 2.9.1, but the connection was using 2.7.0. I updated the connection driver to 2.9.1 and now it works perfectly. Thank you so much! Can't believe I didn't check that before.
from linq2db.linqpad.
Not sure what's going on, but it sounds strange - this error means that your query compiled successfully (found extension properly) and then linq2db wasn't able to handle it.
I've tried your extension with My Extensions
file and it worked fine for me.
from linq2db.linqpad.
Could you post your query code?
from linq2db.linqpad.
Also linqpad version. I use v4.59.0 free
for testing.
from linq2db.linqpad.
LinqPad version 5.4
Here is the query:
Projects.Select(p => new { p.ProjectID, p.ProjectManager })
.Where(p => !p.ProjectManager.IsNullOrEmpty())
I don't have a using
for LinqToDb nor LinqToDb.Tools in either the query or the extension, so it wouldn't be a collision right?
For reference, this works of course:
Projects.Select(p => new { p.ProjectID, p.ProjectManager })
.Where(p => !string.IsNullOrEmpty(p.ProjectManager))
from linq2db.linqpad.
Just for clarifying. Could you please rename method to IsNullOrEmptySql
? If problem still exists we will dig here more deeply.
from linq2db.linqpad.
Renamed it, but still getting the same error :(.
Tried both IsNullOrEmptySql
and IsNullOrEmptySqlasdfdsfasdfdsfa
juuust in case.
from linq2db.linqpad.
I'm not so familiar with LINQPad.
How do you define extension method in script? Screenshot can be enough.
Also which type of Driver do you use? Dynamic or using existing model?
from linq2db.linqpad.
Related Issues (20)
- Support for Azure Cosmos DB HOT 1
- table names that are reserved words in c# are not @escaped
- Vulnerability Issue
- NRE in OracleSchema provider HOT 17
- MS Access HOT 2
- Another issue with oracle HOT 1
- What format does the connection string use? HOT 2
- Migrate to new scaffold framework for model generation from old T4-based code
- Add ClickHouse support
- Error when reading Guid from Sql Azure. HOT 2
- Adding MySQL broken HOT 5
- Add non-persistent connection string option and LinqPad password manager support
- No control over table name capitalization. HOT 1
- SQL vs C# Language differences in table and query names
- Using SQL syntax when opening an SQLite DB HOT 2
- Can't close connection HOT 2
- Upgrade linq2db.LINQPad support LINQPad 8 HOT 5
- Upgrade dependency Azure.Identity package HOT 2
- Unhandled error in method 'PreprocessObjectToWrite' for LINQPad8 HOT 4
- Request - Support for InterBase? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from linq2db.linqpad.