LINQ with FoxPro?
Is there a reasonable way to access FoxPro databases using LINQ? ...
Is there a reasonable way to access FoxPro databases using LINQ? ...
In visual studio 2008, when I drag a database table into my dbml screen, any tables that end with the letter s automatcially get the s removed from the dbml object. Is there any way to disable this? Also, the collection of rows also gets an s appended to the collection property name. Is there a way to change that as well? Thanks ...
Hello, I want to plan a data access layer and I thought to use Linq. I read that linq has its problems with performance and that you could use stored procedures with linq. Should I use stored procedures with linq when planning my data access layer? Is it crucial for the performance? When should I use them? I know that stored procedures...
Hey, I'm using Linq to entities applying a Table per Type approach. This has been going very well, up to now. I have the following setup: Parent Table Child Table (Inherits from parent) Grand Child Table (Inherits from Child Table) Linking Table (Has Foreign Key Nullable, to Child Table) Here is the database diagram Following the...
I've read Rick Strahl's article on Linq to SQL DataContext Lifetime Management hoping to find some answers on how I would manage my .dbml files since they are so closely related to DataContext. Unfortunately, Rick's article seems to be focused on DataContext lifetime at runtime though, and my question is concerned with how the .dbml's s...
I've been working with LINQ To SQL for a little while now and when it comes to removing an entity from the DB, I've always called the table's .DeleteOnSubmit and passed in the entity. Sometimes I've found myself writing something like: db.Users.DeleteOnSubmit(db.Users.Where(c => c.ID == xyz).Select(c => c).Single()); This of course ca...
i have never used LINQ in any of my projects , i have always used ado.net /OR tool in my Business App projects , so i want to know What are the benefits of LINQ ? why and when anybody should use LINQ ? ...
I have a Customer class. public class Customer { private string _id; private string _name; // some more properties follow I am inheriting the EqualityComparer form MyEqualityComparer(of Customer). This I am intending to use in LINQ queries. MyEqualityComparer is intended for partial check between two objects. If the custom...
What is the best way to get the Max value from a LINQ query that may return no rows? If I just do Dim x = (From y In context.MyTable _ Where y.MyField = value _ Select y.MyCounter).Max I get an error when the query returns no rows. I could do Dim x = (From y In context.MyTable _ Where y.MyField = value _ ...
I'm currently thinking about a repository pattern for my data objects, where multiple IQueryable<> instances can be registered as data sources. But it seems its not so easy to get it running :-) Running a simple LinQ Query with Linq to entities and linq to objects doesnt work. Do you think this is in general possible? Maybe the only sol...
My problem is that I want a grid that is populated with a set of times spent on tasks. It needs to have the days of the week at the top (these would preferably be fixed - i.e. Sun, Mon... Sat) and task names down the left column. The contents of the grid will have the individual hours spent for that day on that task. What would the be...
I've got a file filled with records like this: NCNSCF1124557200811UPPY19871230 The codes are all fixed-length, and some of them link to other flat files (sort of like a relational database). What's the best way of querying this data using LINQ? This is what I came up with intuitively, but I was wondering if there's a more elegant wa...
Can linq to sql query using not in? e.g., SELECT au_lname, state FROM authors WHERE state NOT IN ('CA', 'IN', 'MD') ...
Hi, I am looking to create an expression tree by parsing xml using C#. The xml would be like the following: <Expression> <If> <Condition> <GreaterThan> <X> <Y> </GreaterThan> </Condition> <Expression /> <If> <Else> <Expression /> </Else> <Expression> or another example... <Expression> <Add> <X> ...
Basically I am trying to retrieve a list of stored procedure parameters using Linq to SQL? Is there a way to do this? ...
Check out this test: [TestFixture] public class Quick_test { [Test] public void Test() { Assert.AreEqual(0, GetByYield().Count()); Assert.AreEqual(0, GetByEnumerable().Count()); } private IEnumerable<string> GetByYield() { yield break; } private IEnumerable<string> GetByEnumerable() { ...
I have been using LINQ to SQL for a while, and there is one thing that has always bothered me. Whenever I modify the schema of a table, in order to refresh it in the designer, I have to delete it and then add it back. That's fine, but this means I have to actually find the table in the designer. I have about 100+ tables in my database,...
I am trying to convert this test code to C# and having a problem with the Trim command. Has anyone done anything similiar like this in C# going to use this with a text box for searching the aspx page. Dim q = From b In db.Blogs _ Where b.BlogContents.Contains(txtSearch.Text.Trim()) Or _ b.BlogTitle.Contai...
Would a LINQ for java be a useful tool? I have been working on a tool that will allow a Java object to map to a row in a database. Would this be useful for Java programmers? What features would be useful? ...
Hi, can someone suggest a simple overview about Linq that is best suited for a programmer who is already familiar with the concept of Linq but doesn't know the syntax? Thanks! ...