Search Results

Search found 6 results on 1 pages for 'plinqo'.

Page 1/1 | 1 

  • Anyone have any issues with using PLINQO and ASP.NET MVC 2.0?

    - by Chad
    I'm asking because I'm working on an ASP.NET MVC 1.0 site, thinking of upgrading to ASP.NET MVC 2.0. Then I read that PLINQO 5.0 was released (I had never heard of PLINQO before) and have been impressed with what PLINQO appears to be capable of. 1) Is PLINQO capable of building out an ASP.NET MVC 2.0 UI project when it's run? 2) Have you had any bad experiences using PLINQO (particularly in an ASP.NET MVC app)? Let me make sure I have the scenario right in my mind: Using PLINQO (assuming it supports ASP.NET MVC 2.0), I should be able to point it to my DB and it will create 3 projects: data, test, and mvc 2.0 UI? The data would contain LINQ to SQL queries, with the PLINQO extensions added in and the other projects setup to use the data project by default?

    Read the article

  • Use the repository pattern when using PLINQO generated data?

    - by Chad
    I'm "upgrading" an MVC app. Previously, the DAL was a part of the Model, as a series of repositories (based on the entity name) using standard LINQ to SQL queries. Now, it's a separate project and is generated using PLINQO. Since PLINQO generates query extensions based on the properties of the entity, I started using them directly in my controller... and eliminated the repositories all together. It's working fine, this is more a question to draw upon your experience, should I continue down this path or should I rebuild the repositories (using PLINQO as the DAL within the repository files)? One benefit of just using the PLINQO generated data context is that when I need DB access, I just make one reference to the the data context. Under the repository pattern, I had to reference each repository when I needed data access, sometimes needing to reference multiple repositories on a single controller. The big benefit I saw on the repositories, were aptly named query methods (i.e. FindAllProductsByCategoryId(int id), etc...). With the PLINQO code, it's _db.Product.ByCatId(int id) - which isn't too bad either. I like both, but where it gets "harrier" is when the query uses predicates. I can roll that up into the repository query method. But on the PLINQO code, it would be something like _db.Product.Where(x = x.CatId == 1 && x.OrderId == 1); I'm not so sure I like having code like that in my controllers. Whats your take on this?

    Read the article

  • PLINQO Not Naming Entities Correctly

    - by Clever Human
    I have my CSP file set up to use TableNaming and EntityNaming as Singular: <TableNaming>Singular</TableNaming> <EntityNaming>Singular</EntityNaming> Yet the generated entities are plural. For instance, I have a table called Companies. The generated name is "Companies" I expected "Company" (like LinqToSql did -- I am upgrading a project.) I have a table named EntityStorageItems (no relation to these entities.) The generated name is "EntityStorageItems" I expected the entity name to be "EntityStorageItem" IOW, it is creating plural names. And I need them to be singular (to work with existing code.) Am I doing something wrong?

    Read the article

  • linq Multiple Where based on conditions.

    - by Bathan
    I want to query a table with some conditions based on user input. I wrote this : IQueryable turnoQuery = dc.Turno; if (helper.FechaUltimaCitaDesde != DateTime.MinValue) { turnoQuery = turnoQuery.Where(t => t.TurnoFecha >= helper.FechaUltimaCitaDesde); } if (helper.FechaUltimaCitaHasta != DateTime.MinValue) { turnoQuery = turnoQuery.Where(t => t.TurnoFecha <= helper.FechaUltimaCitaHasta); } if (helper.SoloCitasConsumidas) { turnoQuery = turnoQuery.Where(t => t.Estado == Convert.ToInt32(EnmEstadoDelTurno.Consumido)); } else if(helper.AnuladoresDeCitas) { turnoQuery = turnoQuery.Where(t => t.Estado == Convert.ToInt32(EnmEstadoDelTurno.Cancelado) || t.Estado == Convert.ToInt32(EnmEstadoDelTurno.Ausente)); } The problem I'm having is that the "where" clause gets stepped over with the last one. Whats the correct way to do something like this on LINQ? The "helper" object is a custom class storing the user input dates for this example.

    Read the article

  • How to Add Serialized LINQ to SQL Entities to a Word 2007 Document

    - by Ryan Riley
    I built a template-based document generator using the Open XML SDK (1.0), the Word 2007 Content Control Toolkit and LINQ to SQL (using the CodeSmith PLINQO templates). To do this, I serialized the LINQ to SQL entities to XML by retrieving the entity using DataLoadOptions specified in the source code. This works great, except that to initially populate the XML in my template, I currently have to copy and paste the XML from the Immediate window in VS2008 into the Content Control Toolkit, and it still has all the data from the current entity. I'm looking for two solutions: 1) Is this a good way to build a document generator with Word 2007? 1) How can I generate just the XML I need without the data? I've thought of creating an XSD and then creating an empty XML document, but wasn't sure how to do that programatically so that a business user can get the XML for the template. (That's not a requirement, just a nice-to-have.) Thanks for your feedback, Ryan

    Read the article

1