subsonic

Quick way to return a list of custom objects from a page method w/o a separate BLL

I am using jQuery to retrieve a JSON object from a page method. I have a DAL which uses SubSonic and if I return objects created from SubSonic-generated classes I will clog up the pipes. :) You know, all public properties get serialized. I don't want a separate business layer for this application, because it's small and focused on read o...

Subsonic many-to-many

For Subsonic users, is there a source of information about how to deal with many-to-many relations in Subsonic? I keep getting "//no ManyToMany tables defined (0)" in my generated code, although I have defined the right relations in database. any help? ...

Should I use SubSonic or Dynamic Data for a new CRUD asp.net application?

I need to throw together a quick CRUD asp.net site, but this may become a bigger application down the road. I have some experience with SubSonic, but it has been so long since I did a project with it I have to relearn it. I am also considering using Dynamic Data. Does anyone have any experience with these tools that can tell me which way...

schema changes and subsonic - VS 2008

I have been using subsonic and the issues i keep running into is with when i make schema changes, I have to recompile everything and at times subsonic does not recognise some of the schema changes. Is there a better OR/M that i can use asp.net which is more efficient with working with schema changes ...

SubSonic.Query vs SubSonic.SqlQuery

I've been using SubSonic.Query all these while, until one day when I can't do "IS NULL" by adding WHERE, then I realized that SubSonic.SqlQuery existed and it has a function of "IsNull()". After checking out the source code, Query and SqlQuery is not inherited in any way, so what's their major difference and how to decide which to use? ...

subsonic preload object and child

Hi i'm looking to load a list of object with their child graph in subsonic. I know how to do it using linq to sql with dataloadoptions i have this graph product - location - prices new Select().From().Where(Product.Columns.Id).IsEqualTo(productId).ExecuteSingle(); I would like for my product object to preload location and pric...

Where do Subsonic classes go in an ASP.NET MVC Project?

I've built ASP.NET webform projects in the past, and when generating Subsonic classes, the teams I have been on have put our Business Layer/DAL objects into a Project.Framework project. Would that still be a recommended structure, or should the Subsonic classes go directly into the /Model folder within the MVC web project? ...

Could not find server 'dbo' in sys.servers

I have a lot of services which query the database. All of them work fine but one service calling a stored procedure gives me following error: Could not find server 'dbo' in sys.servers. Verify that the correct server name was specified. If necessary, execute the stored procedure sp_addlinkedserver to add the server to sys.s...

SubSonic Dynamic Schema: SelectList

Scenario I am using SubSonic for my latest project. First things first; this project is constrained to using .net 3.0 and SubSonic has been GREAT. I love it. However, I'm having some trouble with customization. The customer has requested that we use two SQL Server 2005 databases, one of which will replicate the other, minus some col...

SubSonic Ignore Column

Is there a way in SubSonic to update some columns of a table? For instance Dal.Users users = new Dal.Users(); users.UserId = user.id; users.Email = user.email; users.FirstName = user.firstName; users.LanguageId = user.languageId; users.LastName = user.lastName; users.Password = user.password; users.UserName = user.userName; users.Data...

Is connection pooling working correctly in Subsonic?

I am getting reports that connection pooling is not working in the Subsonic orm when used with sql server on a remote machine. I'm not sure how they are monitoring this, maybe with the profiler. Subsonic opens late, closes early as you are supposed to do in an orm layer, but is there any problem with the implementation that would cause...

How do you unit test Subsonic lazy-loaded properties?

Let's say I have the following function I want to test: public void CancelOrder(Order order) { order.Status = "Cancelled"; _emailService.SendEmail(order.User.Email, "Your order has been cancelled!"); } Now, the Order class is a SubSonic generated class and the User property on it is lazy-loaded, meaning that when I call order...

Calling an SQL function from a Subsonic.Select

I asked the following question on the subsonic forum, but only seemed to get one response, so I thought I'd post up here as well to see if anyone could shed some more light on the problem... I wish to create the following SQL statement through SubSonic using the Select tool (or Query tool) .. it uses a custom function called "SPLIT()": ...

Scaffold WhereExpression ignored

I'm using SubSonic with an Sqlite database, everything works very well, but one thing that doesn't is the WhereExpression in the Scaffold component. I haven't been able to get it to work. WhereExpression="Emember=true" TableName="blah" > Anyone else had this problem? ...

Replacement for subsonic forums

It's a bit hard to have a lengthy discussion on stackoverflow. We prefer questions that can be answered, not just discussed. So there is a loss replacing a real forum with this. From what I can tell stackoverflow is specifically set up to inhibit extensive discussion and followup. And woe unto you who violate the somewhat vague topic ...

Issue with SubSonic and Multiple Providers

Hi all, I have two Subsonic-generated Data Access Layers for 2 different databases that I use in one project and so I have the following in my web.config: <SubSonicService> <providers> <add name="BLLDB" type="SubSonic.SqlDataProvider, SubSonic" connectionStringName="BLLDB" generatedNamespace="BLLDB" useSPs="true" /> <ad...

Subsonic 2.2 and EnterpriseLibrary 4.1 in Framework 2.0

Hi i use subsonic version 2.2 in my project and this version of subsonic use EnterpriseLibrary 4.1 but i use EnterpriseLibrary 3.1 because i use framework 2.0, the version 4.1 need framework 3.5 or later, the problem is when i use subsonic in the web config i have this and when is load fail, and showme this Could not load file or as...

Why SS generated all Int data type to bool ?

Hi, My Db have some fields using Integer data type, but after SS generated them, all of them 're Boolean db type. Please tell me how to fix it ! Thanks ! ...

unit of work / batch update in SubSonic

I have a collection of objects returned from Subsonic and I want to change a value on them and then save them all, but if 1 save fails I don't want the other changes to persist. I was using linq to sql and using SubmitChanges(). Is there something similar in SubSonic? (I am using 2.1) ...

Populating field from enum table

I have the following tables Entity id,name,categoryid 21,"Blah",1 EntityCategory(Enum table) id, name 1,"New Blahs" I have a FK relationship between Entities->categoryid and EntityCategories->id I have generated SubSonic classes for both as well a corresponding Model object for Entity class Entity{ID,Name,CategoryName} I am trying t...