How to change language in T-SQL
It's very complicated to change the default culture for SQL Server: SET LANGUAGE 'English'. Duh!
It's very complicated to change the default culture for SQL Server: SET LANGUAGE 'English'. Duh!
Now this is a Russian band with a male+female vocal. This is by far the best of their songs and they have a nice video clip on it. Enjoy!
Can you imagine 1922? It was 85 years ago. That means that almost certainly all the people that worked on this movie are now dead! But it is still a masterpiece of cinema. They did that with no previous inspiration. After you watch this, you can only ask yourself how come people have 85 years of example and they still screw movies up. So here it is: Nosferatu
I've accidentally stumbled upon a thing called OutputCache. Weird little thing, I thought, how come I didn't hear about it? It seemed such a wonderful concept: just cache the output of ASP.Net pages and controls for a specific amount of time, specify for what parameters or controls or properties the cache is valid for and if it is shared between different users. Then just output the cached version and don't execute the entire thing all the time.
This book is written by a guy that made a small company dedicated to programming with free tools. Thus, it tries to show how to debug ASP.Net assuming that you come from an ASP background and that you don't have Visual Studio .Net. So I don't think I have to tell you how much useless information there is in there. It even covers programmatic code tracing.

After finishing the Commonwealth Saga, by the same author, I started reading the next series: The Void Trilogy. As in the aforementioned saga, the story does not end in any way at the end of the first book, you have to read all three books to reach the end, which effectively makes this another huge monolithic story, not a series or saga.
I wanted it to sound like Fruit of the Loom, for the connoisseurs in gaming :), but failed miserably. This blog post is about the exotic (and shamelessly expensive) fruits one can found in market stores.
I've been to a small village near Sibiu, home of my parents in law, called Sarata. First major trip outside Bucharest by car, we managed to reach Sibiu, Ocna Sibiului, Sighisoara, Basna, Balea Lac, Paltinis and to travel the entire area back and forth.
Am I turning metal? I used to hate songs played by long haired guys barking aimlessly on a heavy and repeating guitar riff. But I really enjoy listening to Sonata Arctica. Maybe because they're Finnish? :) I am developing a taste for Finnish music, apparently.
You are trying to use a WebMethod or a web service ScriptMethod in Javascript and you get an InvalidOperationException saying something about a circular reference. It happened to me when trying to read a DataTable in Javascript.<system.web.extensions>
<scripting>
<webServices>
<jsonSerialization >
<converters>
<add name="DataTableAjaxFix" type="AjaxTypeConverters.DataTableConverter"/>
</converters>
</jsonSerialization>
using System;
using System.Collections;
using System.Collections.Generic;
using System.Data;
using System.Web.Script.Serialization;
namespace AjaxTypeConverters
{
public class DataTableConverter : JavaScriptConverter
{
public override IEnumerable<Type> SupportedTypes
{
get { return new Type[] {typeof (DataTable)}; }
}
public override object Deserialize(IDictionary<string, object> dictionary, Type type,JavaScriptSerializer serializer)
{
throw new NotImplementedException();
}
public override IDictionary<string, object> Serialize(object obj, JavaScriptSerializer serializer)
{
DataTable listType = obj as DataTable;
if (listType != null)
{
// Create the representation.
Dictionary<string, object> result = new Dictionary<string, object>();
ArrayList itemsList = new ArrayList();
foreach (DataRow row in listType.Rows)
{
//Add each entry to the dictionary.
Dictionary<string, object> listDict = new Dictionary<string, object>();
foreach (DataColumn dc in listType.Columns)
{
listDict.Add(dc.ColumnName, row[dc]);
}
itemsList.Add(listDict);
}
result["Rows"] = itemsList;
return result;
}
return new Dictionary<string, object>();
}
}
}
Yesterday I was trying desperately to understand why my web site was crashing without any error, the only information I could get being that the connection to the server has been reset. I've spent hours trying to determine what was wrong. Apparently I needed a break, because today it took me a few minutes to realize what it was.protected override PageStatePersister PageStatePersister
{
get
{
//return base.PageStatePersister;
return new SessionPageStatePersister(this);
}
}

You may have noticed that in debug mode, in Visual Studio, you have a little magnifier glass next to some of the variables in Autos, Local or Watch debug windows. Once you click on it, you get to visualize your data in a more comprehensive way. A good example are the DataSet Visualizer or the DataTable Visualizer which show you in a normal DataGridView a DataSet or DataTable.
The good news is that you can build your own visualizers and that in a very simple way. Here are the quick steps to achieving this, followed by some links to other people detailing:
[assembly : DebuggerVisualizer(typeof (--YourVisualizer--),
Target = typeof (--Your Type--),
Description = "--Your Type-- Visualizer")]
namespace ...
[assembly : DebuggerVisualizer(typeof (--YourVisualizer--),
typeof (--YourVisualizerObjectSource--),
Target = typeof (--Your Type--),
Description = "--Your Type-- Visualizer")]
namespace ...