Hey Gav,
No, that's not supported yet, I'm planning to do some work on compound operations like that in 2.0, which is probably starting in earnest around the end of the year.
In the meantime, stored procs are my catch-all work-around recommendation. 😊
Cheers,
Mark
Sent from Windows Mail
From: Gavin Osborn
Sent: 08 November 2012 19:27
To: simpledata@googlegroups.com
Subject: Complex Delete Scenarios
Does Simple.Data support the following style query?
DELETE FROM Users
WHERE locationId IN
(
SELECT locationid FROM Location WHERE continent = Europe
)
I've tried a few examples including:
db.Users.DeleteAll(db.Users.LocationId.IN(db.Locations.FindAllByContinent(" Europe").Select(db.Location.LocationId)));
It's not throwing exceptions, but the SQL Server Profiler also tells me that it isn't executing any SQL either.
How would I best achieve this in Simple.Data?
Cheers,