Issue is that you won’t be able to run it due to that licenses compilation issue.
However I can create a full .NET-targeted console app that will use 100% the same code as the .NET Core would.
For the start let’s cover some basic stuff.
One can build Data Abstract client app in .NET Code using 2 different sets of assemblies - one targeted for .NET Standard and one targeted for .NET Core. Latter one is not available for download yet (will be available in the first post-RTM beta). It will provide access to the same feature set as the desktop .NET-targeted one, including Scripting and DataTable-based data adapter.
Former one (the .NET Standard-based) provides only DA LINQ-based way of data access, mostly because .NET Std is multi-platform and some of these platforms just don’t have
DataSet classes at all.
DA LINQ by itself is a fairly simple to use thing. To make it easier to start with it let me give a simple explanation how it does work:
- There is a set of classes describing server schema (aka Table Definitions)
- One writes select queries using fancy code like
var query := from u in dataAdapter.GetTable() where u.Id > 100 select u; // Query definition
and then executes (materializes) that query using
var users := query.ToList(); // Actually execute the query
Another way of writing the same query ans in the 1st line is
var query := dataAdapter.GetTable().Select(u -> u).Where(u -> u.Id > 100);
That’s exactly the same query as in the 1st line, just written in a different form. This latter form is exactly the same in terms of performance, but it is easier to understand what’s going on there and it somewhat resembles “real” SQL:
- Take a data source table
- Select data from it (
- Filter that selected data (
And here’s the sample app (targeting desktop .NET). This app uses sample domain from the Relativity Server as a data source: LinqConsoleApplication.zip (38.0 KB)