ravendb

Is it possible to work with OrientDB using C#?

不问归期 提交于 2020-01-12 07:15:28
问题 Are there any implementations, api or examples of OrientDB and C#. The reason I am looking at OrientDB is becuase it's the only one that I found that is a combination of Graph and Document. Any suggestions on how I should try this. My next choice is RavenDB, but I am not sure if it supports joins or linked documents? Any thoughts... 回答1: I just developed a first version of a REST client for OrientDB. http://netorientdb.codeplex.com 回答2: OrientDB has an official binary driver for .NET look

Querying a RavenDB index on ID given not-indexed-error, how to fix?

你。 提交于 2020-01-05 03:44:07
问题 I have a RavenDB database with two document collections. I need to combine documents from these two into a single business entity using a multi map/reduce index. The business entity isn't complete if I don't combine the two collections. You could probably argue that this indicates that my domain model or data model is broken but it is what it is and there isn't anythig I can do about it. So, on with the question :-). Basically the three documents: { // RootDocuments/1 "Foo" : "Bar", "Bar" :

RavenDB OrderByDescending and Take - Incorrect Results

时间秒杀一切 提交于 2020-01-04 05:59:26
问题 This query was working for me until recently. I now have 135 InstallationSummary documents in my RavenDB. Instead of getting the most recent by start time, it's mostly working, but the last couple, most recent documents aren't showing up from this query. Am I querying incorrectly? Is there a different way to do OrderByDescending and Take with RavenDB that I should be aware of? Is there a document number limit to what I can query correctly? Note: I have debugged this, and the query indeed

RavenDB OrderByDescending and Take - Incorrect Results

喜你入骨 提交于 2020-01-04 05:58:22
问题 This query was working for me until recently. I now have 135 InstallationSummary documents in my RavenDB. Instead of getting the most recent by start time, it's mostly working, but the last couple, most recent documents aren't showing up from this query. Am I querying incorrectly? Is there a different way to do OrderByDescending and Take with RavenDB that I should be aware of? Is there a document number limit to what I can query correctly? Note: I have debugged this, and the query indeed

RavenDb and MultiTenancy

∥☆過路亽.° 提交于 2020-01-03 07:54:15
问题 I have looked and played around with RavenDb for a while and have started to look at MultiTenancy. Ayendes sample for multitenancy looks like this: using(var store = new DocumentStore { Url = "http://localhost:8080" }.Initialize()) { store.DatabaseCommands.EnsureDatabaseExists("Brisbane"); store.DatabaseCommands.EnsureDatabaseExists("Melbroune"); store.DatabaseCommands.EnsureDatabaseExists("Sidney"); using (var documentSession = store.OpenSession("Brisbane")) { documentSession.Store(new {

RavenDb and MultiTenancy

强颜欢笑 提交于 2020-01-03 07:51:09
问题 I have looked and played around with RavenDb for a while and have started to look at MultiTenancy. Ayendes sample for multitenancy looks like this: using(var store = new DocumentStore { Url = "http://localhost:8080" }.Initialize()) { store.DatabaseCommands.EnsureDatabaseExists("Brisbane"); store.DatabaseCommands.EnsureDatabaseExists("Melbroune"); store.DatabaseCommands.EnsureDatabaseExists("Sidney"); using (var documentSession = store.OpenSession("Brisbane")) { documentSession.Store(new {

How to do a cross join / cartesian product in RavenDB?

别来无恙 提交于 2020-01-02 15:03:13
问题 I have a web application that uses RavenDB on the backend and allows the user to keep track of inventory. The three entities in my domain are: public class Location { string Id string Name } public class ItemType { string Id string Name } public class Item { string Id DenormalizedRef<Location> Location DenormalizedRef<ItemType> ItemType } On my web app, there is a page for the user to see a summary breakdown of the inventory they have at the various locations. Specifically, it shows the

Raven DB Count Queries

萝らか妹 提交于 2020-01-01 11:33:16
问题 I have a need to get a Count of Documents in a particular collection : There is an existing index Raven/DocumentCollections that stores the Count and Name of the collection paired with the actual documents belonging to the collection. I'd like to pick up the count from this index if possible. Here is the Map-Reduce of the Raven/DocumentCollections index : from doc in docs let Name = doc["@metadata"]["Raven-Entity-Name"] where Name != null select new { Name , Count = 1} from result in results

Unable to create databases when running RavenDB on IISExpress

随声附和 提交于 2019-12-25 12:55:29
问题 As the title says. (Cross post from the mailing list: https://groups.google.com/forum/#!topic/ravendb/hxP3REWVMdg) The iisexpress process is running as the currently logged in user, but I'm only getting Unauthorized error messages when trying to create databases. Accessing /debug/user-info only gives the following message: {"Remark":"Using anonymous user","AnonymousAreAdmins":false} 回答1: Courtesy of Fitzchak Yitzchaki, I got the answer on the RavenDB mailing list: https://groups.google.com

RavenDB - Indexing and querying complex hierarhical data (nested properties)

ぐ巨炮叔叔 提交于 2019-12-25 08:35:12
问题 I have a docuemnt like this: public class Order { public string ClientName { get; set; } public List<OrderItem> Items { get; set; } } public class OrderItem { public string ProductCode { get; set; } public int Quantity { get; set; } } And I need to query collection of theese documents like this: var q = session.Query<Order_Index.Result, Order_Index>() .Where(o => o.ClientName.StartsWith("Jho") && o.Items.Any(i => i.ProductCode == "Book" && i.Quantity >= 10)) .OfType<Order>(); Every example of