plinqo

LINQ2SQL + PLINQO: How does one handle a simple situation like this?

Hello, I’m new to PLINQO, I’m fairly new to LINQ2SQL and I’m adding a new DAL (called DAL2) in parallel with our old existing DAL. Our idea is to start using linq2sql for every new thing we add and slowly start moving old DAL usage to the new DAL2. As we all know, DLINQ is nice for simple things but in more complicated scenarios (many...

How to catch BrokenRuleException in PLINQO?

I’ve created a custom rule by adding the static partial void AddSharedRules() { RuleManager.AddShared<Tag>( new CustomRule<String>( "TagName", "Invalid Tag Name, must be between 1 and 50 characters", IsNullEmptyOrLarge)); } to my Entity class. ...

Use strongly typed data rather than a string to bind to a drop down list

Given the following class.... namespace IMTool.Data { public partial class AllContracts { internal class Metadata { public int ContractId { get; set; } [Required] public string Name { get; set; } } } } and given the following. using (var context = new IMToolDataC...

Correct way to remove M:M in PLINQO?

Suppose you have this table structure: Patient -> PatientTag -> Tag A typical N:M relationship between patients and tags, PatientTag being the intermediate entity with both FKs. (PatientId and TagId). I want to remove a specific tag, I have its ID. I’m doing this but I’d like to know if there’s a better way, since these are the 1st m...

Plinqo 4 vs EF 4

Does anyone has experience with plinqo 4? what are the benefits vs EF 4? ...

PLINQO Not Naming Entities Correctly

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 pr...

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

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 y...

Use the repository pattern when using PLINQO generated data?

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...

PLINQO Stop generation on build class library

Hi I've just started using PLINQO which looks really good so far. The only problem I have is whilst I'm doing custom amends on the entities I rebuild the contained class library and codesmith wants to regenrate my class library which prompts the visual studio message. "Your project has been amend outside, do you want to reload?" etc.. ...

PLINQO Primary key AND index problem

Hi, I've two tables, Profile and ProfileCategory ProfileId INT IX UserId UNIQUEIDENTIFIER PK (For one-to-one mapping with aspnet_membership) CompanyName Description ProfileCategory CategoryId ProfileId When I generate the code with PLINGO I get following errors Operator '==' cannot be applied to operands of type 'int?' and 'System....

PLINQO / LINQ-To-SQL - Generated Entity Self Save Method?

Hi I'm trying to create a basic data model / layer The idea is to have: Task task = TaskRepository.GetTask(2); task.Description = "The task has changed"; task.Save(); Is this possible? I've tried the code below Note: The TaskRepository.GetTask() methods detaches the Task entity. I'd expect this to work, any ideas why it doesnt? T...