subsonic

SubSonic: MaxLength of TableColumn (exceeding)

Hey all! So, we're using SubSonic as our DAL/ORM for one of our projects. Everything has been running smoothly (the database already existed, so we used SubSonic on top of it), however, on occasion we'll run into an exception that says something like the integer is exceeding the max length. In this example, our MySql field is an int(4) ...

Why is SubSonic and ActiveRecord throwing an exception when updating a record?

I have the following table in MS SQL Server 2008 Standard Edition: CREATE TABLE [dbo].[NewTestQueue]( [JobID] [int] IDENTITY(1,1) NOT NULL, [ServerName] [varchar](50) NULL, [DomainID] [int] NOT NULL, [Action] [varchar](50) NULL, [Folder] [varchar](150) NULL, [Method] [varchar](50) NULL, [ActionProfile] [varch...

SubSonic - getting sproc output parameters by name?

My sproc signature is defined as: ALTER PROCEDURE [dbo].[AuthenticateUser] -- Add the parameters for the stored procedure here @UserName varchar(64), @UserPassword varchar(64), @Result INT OUT, @ErrorMessage VARCHAR(25) OUT AS BEGIN.... Calling this sproc with SubSonic: DataSet dsResults = new DataSet(); Stored...

Plans for eager loading for ActiveRecord in Subsonic 3?

Just curious if there are plans for eager loading using ActiveRecord in Subsonic 3. Is there a roadmap out there? It seems like a pretty sweet library. Very similar to Rails but missing a few sweet spots. ...

How to disable lazyload in subsonic programmatically?

By default if the table has FK, subsonic also retrieves data of the FK table. Is it possible to disable this? ...

SubSonic SQL CE Error

Hi There, I have an old c# project which currently runs on a SQL CE database. I decided yesterday that I would like to use SubSonic to generate a DAL for me as I have used SubSonic a lot in my other projects (with a standard MS SQL database backend) and I love it's ease of use. Everything seems fine, I can create and delete records but...

Subsonic and CSLA.NET

Can SubSonic be used with CSLA.NET? Has anyone tried this. From my understanding SubSonic is a DAL CSLA.NET is a BAL (BLL) I can't seem to find any information on this. ...

Subsonic 3.0 and "Link" tables.

I have the following set-up. BlogPosts BlogToCategory Category One blog post can have many categorys and a category can be in many blog posts. (Hence the intermediate table. How would I go about getting a list of all the blog-posts in one category. I've tried this but cant seem to get it right (I get a IQueryable -> IEnumerable cast...

SubSonic 3. Get results as DataTable

How can I get .All() method's result as a DataTable ? Currently it returns IQueryable, wich can't be used as datasource for the WinForms DataGridView control. dataGridView1.DataSource = Product.All(); // not working ...

If you had one wish for SubSonic what would it be?

I know this question seems subjective but it's really pretty simple. As a long term user, and part time contributor to SubSonic I'm interested in what the community thinks would be the single best way to improve it. So what's your opinion, how would you make SubSonic even better? What one thing would make you more likely to use/recommend...

Why does SubSonic's ActiveRecord T4 template generate ActiveRecord1.cs and not ActiveRecord.cs?

I've used SubSonic's ActiveRecord T4 templates in a couple of projects. Today I added the same templates from one of these projects (without the generated .cs source files) to a new project. For some reason when I run the T4 template code generator, instead of generating: ActiveRecord.cs, Context.cs, StoredProcedures.cs and Structs.cs...

Subsonic 3 ActiveRecord Delete/Destroy throwing strange exception

...

subsonic 3.0.0.3 for multiple primary keys table

When I use ActiveRecord template,that can't generator correct primary key for multiple primary keys table. I can't update that table. ...

Subsonic - My base class to accommodate different model classes and repository instances

I want to have a baseclass that will assign a DataGridView's datasource property. I am using the ActiveRecord approach so all my code generated classes are of IActiveRecord. IRepository needs my class to instantiate it. I cannot seem to get this to work What I want to do is something like this.. IActiveRecord GridObject; public voi...

How to initialize subsonic programmatically at runtime

Would like to initialize @ run-time as needed with the connection string coming from a non app.config source ...

Subsonic 3 + SQLite 3

I am trying to use Subsonic for SQLite. I got an exception "SQLite error near ".": syntax error". VS 2008; Subsonic 3.0.0.3; SQLite 3. How I can to resolve it? Also, cananybody provide an project example with Subsonic for SQLite included. ...

Select query with Datetime? and Datetime doesn't work!

Here what I would like to do: var groups = from g in Group.All() where g.FirstDay < startDate && (g.LastDay == null || g.LastDay >= startDate) select g; FirstDate is a dateTime and LastDate is a nullable datetime. I'm getting an "System.InvalidOperationException: The operators of the 'LessThan' do not correspond with parameter...

SubSonic .Update() method does not work with MySQL

Could someone tell me, why static Update() method doesn't work with MySQL ? Product.Update(5 ,"ProdName", 12.99); // Record is not updated, Why? SubSonic ver 2.2 However, the method below is updating OK. Product p = Product.FetchByID(5); p.Name = "ProdName"; p.Price = 12.99; p.Save(); Thank you. ...

SubSonic 3.0.0.3 SimpleRepository Int64/BigInt issue

I have a Class called Project that has ID property with a data type of long/Int64 but with Auto Migrations the ID column in the Projects table is not a bigint column. Is this a bug or am i missing something? Any help would be appreciated ...

Using SQL DSN With SubSonic

I am a newbie with Subsonic. I want to create a SQL connection using DSN; then I want to generate the DAL using Subsonic. Please can you give me some pointers on what to do? ...