views:

17

answers:

1

Hi everybody,

I'm not very familiar in programming databases, but I have a Mysql-Database which I access with Dblinq under C#. Now when I enter dates, numbers etc, the english notation is used, but my customer needs german. How can I switch my database from english to german? (The Database is still empty, I can easily re-create it, if needed)

Thanks in advance!

Christian

+1  A: 

I am not a C# developer but I use MySQL (and others). Usually dates are stored using the ISO format and I cannot change that, or nobody does that. When you print a date, you should specify a format. So you should retrieve the date from a record and print it in the required format. I know that one of the most used ORM library in C# is NHibernate. Usually with an ORM library you get an object that maps a record and a date field is a property of something like DateTime, a class, so in a pseudo language:

calendar = Calendar.findById(1);
print calendar.event_date.toString("%d/%m/%Y"); # <- prints 03/10/2010
rtacconi
Here you can see how format date and time in C sharp: http://www.csharp-examples.net/string-format-datetime/
rtacconi
That explains well, why I cannot find any answer in any forum :-)Thank you, now I searched in the correct direction, changed my WPF settings and voilà, it works!
Badeoel