Which ORM will give me compile-tested queries?
Is linqtosql compile time tested?
Edit:
Say I write a query that references a column named 'TotalSales'. I then rename the column in my database to TotalSales2 (and any other config file like: Employee.cfg.xml in nHibernate).
When I compile the project, I want Visual Studio to tell me ...
Sorry for this point being all over the place here...but I feel like a dog chasing my tail and I'm all confused at this point.
I'm trying to see the cleanest way of developing a 3 tiered solution (IL, BL, DL) where the DL is using an ORM to abstract access to a DB.
Everywhere I've seen, people use either LinqToSQL or LLBLGen Pro to ge...
I have an ASP.NET 3.5 application that I want to allow the user to select a table and allow CRUD operations on that table. The user will be restricted to a number of tables to edit however the tables and even database won't be known until after deployment; the web.config will setup the connection and tables.
So I need to build a framewo...
This is related conceptually to my question here. However, I've been playing around with NHibernate, and realized what the real core of my question is.
In classic OO design, to properly encapsulate data, it's a common pattern to have values passed in to an object's constructor that are stored in data members (fields). Those values whic...
Projectfundingdetail has a foreign key to project.
The following query gives me the list of all projects that have any projectfundingdetail under 1000. How do I limit it to latest projectfundingdetail only.
projects_list.filter(projectfundingdetail__budget__lte=1000).distinct()
I have defined the following function,
def latest_fundi...
I'm very interested in using NHibernate.Burrow for my session handling and DAO in my ASP.NET app but I'm having trouble with the configuration. Burrow requires an XML NHibernate config for setting up its persistence but I don't have a config file since I'm using Fluent NHibernate to generate my config. So is there a way of letting Burrow...
I'm currently building a new app based on a legacy database. In the app, there are many "list" tables that have the following format:
table listLanguages
{
PrimaryId bigint;
Item varchar(30);
}
...with some sample entries like this:
PrimaryId Item
1 English
2 French
3 Spanish
...
They were used to p...
I love the abstract database API that comes with Django, I was wondering if I could use this (or something similar) to model, access, and manage my (postgres) database for my non-Django Python projects.
...
Just wondering if it is possible to get a result that I can get using this SQL query with only Django ORM:
SELECT * FROM (SELECT DATE_FORMAT(created, "%Y") as dte, sum(1) FROM some_table GROUP BY dte) as analytics;
The result is:
+------+--------+
| dte | sum(1) |
+------+--------+
| 2006 | 20 |
| 2007 | 2230 |
| 2008 | 49...
I am developing a transactional application in .NET and would like to get some input on how to properly encapsulate database access so that:
I don't have connection strings all
over the place
Multiple calls to the same stored
procedure from different functions
or WORSE, multiple stored
procedures that are different by a
single column
...
Possible Duplicates:
Use only some parts of Django?
Using only the DB part of Django
I want to use the Django ORM as standalone. Despite an hour of searching Google, I'm still left with several questions:
Does it require me to set up my Python project with a setting.py, /myApp/ directory, and modules.py file?
Can I create a ne...
I have been playing with some LINQ ORM (LINQ directly to SQL) and I have to admit I like its expressive powers . For small utility-like apps, It also works quite fast: dropping a SQL server on some surface and you're set to linq away.
For larger apps however, the DAL never was that big of an issue to me to setup, nor maintain, and more...
I am mapping my database tables to my java objects. Generally I name my tables in the plural form in that a table holding books information is called BOOKS. The java object represents however one book and should be called Book. Similarly for AUTHORS/Author etc.
On the other hand, its kind of simplistic to give the same to the domain ob...
I have a simple question about usage of Hibernate. I keep seeing people using JPA annotations in one of two ways by annotating the fields of a class and also by annotating the get method on the corresponding beans.
My question is as follows: Is there a difference between annotating fields and bean methods with JPA annoations such as @I...
Possible Duplicates:
unit-of-work-pattern-in-net
rhinocommons-unitofwork-question-with-asp-net-mvc
The Unit of Work pattern is a way to keep in a context to track all the actions on your domain and to apply them all at once when your - possibly - complex logic is done.
When used with an ORM (NHibernate for instance), it is cons...
I have two fields of an entity class which I don't want to be unique but to instead be used as composite fields for a key which must itself be unique. For example I have two fields (name and version) which can be the same for other records but together they must be unique. What is the best way to do that using Hibernate (with annotatio...
How does Hibernate compare to NHibernate?
I've heard the claim that "Hibernate is much worse than NHibernate, even to the point of not using it (and using JDBC over it)". Can anyone support or refute this?
Update - I am not trying to decide between them. Our DAL team decided to use NHibernate for our .Net side, but not use Hibernate on...
I'm trying to map an @Embeddable object in a subclass whose parent class already has a field of that @Embeddable type.
The hibernate Embeddable Objects documentation claims I can use the @AttributeOverrides to override the column names of an @Embeddable object:
e.g.
@Entity
public class Person implements Serializable {
// Persist...
Is there a way to map a factory method in Hibernate (as opposed to having Hibernate call a default constructor and reflectively set properties or fields)?
And if it can't be mapped, does Hibernate provide a hook for custom object creation on a class by class basis?
Thanks!
...
Bear with me as I try to simplify my issue as much as possible.
I am creating a new ORM object. This object has an auto generated primary key which is created on the database using as an identity. Within this object, is a child object with a many to one relationship with the parent object. One of the attributes I need to set to create t...