» Home » Related » Page 1
Are NServiceBus handler's members safe for storing message related (and not related) data?
by Denmark in Programming Languages

Are handlers reused to proceed another message?

public abstract class SomeHandler : IHandleMessages<MyEvent>
public IBus Bus { get; set; }
public String Message { get; set; }
public void Handle(T message)
Message = "Test";
public void SomeInstanceMethod()

How do I get the entity framework to lookup whether related data EXISTS in a related table?
by sdifox in Web Design

I am working on making an entity framework project more scalable to suit our requirements. The project uses an EDMX file, Entity Framework, and .NET 4.0. The project has globally setup lazy loading.

Basically, I have 2 tables:


I have a situation where there will

Magento Related Product Controller - Show Related Even If Collection = 0
by Matt Willtrout in Programming Languages

I am looking for the controller / function which shows the Related Product child html.

On the product view page it is simply called via <?php echo $this->getChildHtml('related'); ?>

I have modified this phtml file to count the related items and show an alternate fallback of a random selection of products by using this:

(Within /catal

Issue related to upgrading application related to Database in Android
by Drift King in Android

When i modify the database and upgrade the existing app in my Phone, the DB is not getting overwritten which makes my application crash.
How to tell phone to delete the DB and add fresh one during installation of APK file?

django can we select related a field on a prefetch related model?
by Jpark in Web Design

Assuming these as django model for the sake of simplcity:

class A():
a = manytomany('B')
class B():
b = charfield()
z = foreignkey('C')
class C():
c = charfield()

Can we do something like this to fetch the z also:

foo = A.objects.get(pk = 1).prefetch_related('a').select_related('a__z')<

Related elements of related element
by Platinumjsi in Programming Languages

I have the following problem. When debugging a project where I'm playing around a bit with Code First, the Items are somehow not added to the purchase. The purchases are added to the client.

This is how I seed the Data.

public class PublicDatabaseInitializer : DropCreateDatabaseIfModelChanges<PublicDataContext>
protected override void Seed(Public

Filtering simultaneously on count of related objects and on count of related objects that satisfy a condition in Django
by Randy K in Databases

So I have models amounting to this (very simplified, obviously):

class Mystery(models.Model):
name = models.CharField(max_length=100)
class Character(models.Model):
mystery = models.ForeignKey(Mystery, related_name="characters")
required = models.BooleanField(default=True)

Basically, in each mystery there are a number of charac

LINQ query where record does not exist in related table, or does exist in related table with condition
by green in Coding

What is the optimal way to perform the following query?

I have two tables with the following structure:

I want to find all "unowned" assets - where that means there is no AssetOwner record which has the AssetID and either no EndDate or an EndDate in the future.

I have made a first pass at this query:

return from a in db.Assets

For MySQL, is there tool to dump a set of rows from one tables and all related (by foreign key) rows from all related tables?
by NAM TRON in Databases

I'm using MySQL db.

I want to dump a set of rows from one table and if these rows have foriegn keys that point to rows on some other tables, I want to dump those too.

Then I want to load these dumps into their respective tables on a different database (e.g using LOAD DATA INFILE command). So simply using select...join...into outfile is not enough since the r

nHibernate query looking for the related object's related object
by arbeitandy in Programming Languages

I have an nHibernate querie issue that looks quite straight forward, but I can't seem to get my head around it!

I am creating some simple example classes to illustrate my problem:

public class Car {
public int Id { get; set; }
public IList<Interior> InteriorParts { get; set; }
public class Interior {
public int Id { get; se

Privacy Policy - Copyrights Notice - Feedback - Report Violation - RSS 2017 © bighow.org All Rights Reserved .