Ayende @ Rahien

My name is Oren Eini
Founder of Hibernating Rhinos LTD and RavenDB.
You can reach me by phone or email:


+972 52-548-6969

, @ Q c

Posts: 6,124 | Comments: 45,483

filter by tags archive

Small touches: Complex text in RavenDB

time to read 1 min | 162 words

This is what we call a “mini feature”, something that you’ll probably not notice unless pointed out to you. Often, we want to store documents that contain multi line strings properties. JSON has a very simple way to handle that:


And it works, and if the text is small, it is even readable. But it isn’t really working on anything even remotely complex or long. So we have worked to fix that:


Now you can actually read this much more easily. We run into this when we look at stack trace information, where without line breaks, it is nearly impossible to see what is going on.


Daniel Häfele

This is so simple, but extremly usefull.

I like what I see of RavenDB 3.

Itamar Syn=Hershko

This is not a "mini-feature". This is a usability feature. There's a huge difference.

khalid abuhakmeh

I think I'd rather see it how I stored it with all the newlines and tabs. It can help me identify quickly issues with text, where as this "feature" could make that more difficult. Maybe a toggle between both views would help more.

Ayende Rahien

Khalid, This is a presentation only feature, it only impact how you see things, it doesn't change anything in the way the data is stored.

Jahmai Lay

Does it always do \r\n, or does it support reading/writing just \n too?

Ayende Rahien

Jahmai, We will read \n, but we'll always write \r\n.


I can see @Khalid's point and can see the benefit of a toggle view as well.


+1 for a toggle switch. Sometimes you want to know the exact characters in place...


This probably indicates other problems, but consider a document that contains stringified JSON as one of its properties. i.e. { "requestId": "1234", "requestBody": "{\"foo\":\"bar\",\r\n\"fizz\":\"buzz\"}" } I'm going to get confused! +1 for toggle.

I actually kind of like the way Visual Studio does it in watch windows. Normally you see the encoded text, but you click that little magnifying glass to see it with actual line breaks.


+1 for toggle view

Ayende Rahien

Troy & Koen, There is a toggle for that, sure.

Comment preview

Comments have been closed on this topic.


  1. RavenDB 3.5 whirl wind tour: I’ll find who is taking my I/O bandwidth and they SHALL pay - 3 hours from now
  2. The design of RavenDB 4.0: Physically segregating collections - about one day from now
  3. RavenDB 3.5 Whirlwind tour: I need to be free to explore my data - 2 days from now
  4. RavenDB 3.5 whirl wind tour: I'll have the 3+1 goodies to go, please - 5 days from now
  5. The design of RavenDB 4.0: Voron has a one track mind - 6 days from now

And 12 more posts are pending...

There are posts all the way to May 30, 2016


  1. RavenDB 3.5 whirl wind tour (14):
    02 May 2016 - You want all the data, you can’t handle all the data
  2. The design of RavenDB 4.0 (13):
    03 May 2016 - Making Lucene reliable
  3. Tasks for the new comer (2):
    15 Apr 2016 - Quartz.NET with RavenDB
  4. Code through the looking glass (5):
    18 Mar 2016 - And a linear search to rule them
  5. Find the bug (8):
    29 Feb 2016 - When you can't rely on your own identity
View all series


Main feed Feed Stats
Comments feed   Comments Feed Stats