473,408 Members | 2,813 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

Distributed model date time strategy

I recently posted this message to
microsoft.public.dotnet.framework.aspnet.webservic es, but received no
response, so I'm trying here in this group. I could really use some
feedback.

I'm working on a commercial application that will have data, web
service, and client application tiers. I have no control over where any
of these systems might be deployed, and it's fairly likely that users
running the client application will be in different time zones than the
web service and database server.

What I'd like to do is always store date/time values in the database in
UTC (GMT) format, and then convert them to local date/time values on
the client side. This should minimize the need to be concerned about
time zones in general.

I believe what's required here is that DateTime objects in .NET code
use the ToUniversalTime() function prior to be stored in the database
(a SQL Server in this case). Then I would always call ToLocalTime()
when I display any of these values in the client application. The
client will *always* go through an ASP.NET (ASMX) web service tier to
read/write any data (including date/time values).

Does this seem logical? Any gotchas that I'm overlooking? Just as an
aside, I'm using .NET 2.0 through all layers.

I'd very much appreciate any input, and thanks.

- Mark

Mar 4 '06 #1
2 1400

It's okay and logical. What does confuse you?
I recently posted this message to
microsoft.public.dotnet.framework.aspnet.webservic es, but received no
response, so I'm trying here in this group. I could really use some
feedback.

I'm working on a commercial application that will have data, web
service, and client application tiers. I have no control over where
any of these systems might be deployed, and it's fairly likely that
users running the client application will be in different time zones
than the web service and database server.

What I'd like to do is always store date/time values in the database
in UTC (GMT) format, and then convert them to local date/time values
on the client side. This should minimize the need to be concerned
about time zones in general.

I believe what's required here is that DateTime objects in .NET code
use the ToUniversalTime() function prior to be stored in the database
(a SQL Server in this case). Then I would always call ToLocalTime()
when I display any of these values in the client application. The
client will *always* go through an ASP.NET (ASMX) web service tier to
read/write any data (including date/time values).

Does this seem logical? Any gotchas that I'm overlooking? Just as an
aside, I'm using .NET 2.0 through all layers.

I'd very much appreciate any input, and thanks.

- Mark

---
WBR,
Michael Nemtsev :: blog: http://spaces.msn.com/laflour

"At times one remains faithful to a cause only because its opponents do not
cease to be insipid." (c) Friedrich Nietzsche
Mar 4 '06 #2
Hi Mark,

I just replied to your other post - sorry for the delay. I posted my
findings here:
http://www.thejoyofcode.com/DateTime..._Services.aspx

Josh
http://www.thejoyofcode.com/

Mar 4 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Constandinos Mavromoustakis | last post by:
CFP: CLADE 2004-Challenges of Large Applications in Distributed Environments ------------------------------------------------- PhD student - Dept.Informatics at Aristotle University of...
7
by: Richard Maher | last post by:
Hi, I am seeking the help of volunteers to test some software that I've developed which facilitates distributed two-phase commit transactions, encompassing any resource manager (e.g. SQL/Server...
0
by: DotNetJunkies User | last post by:
I am writing a distributed transaction code. My current scenario include a client database(Suppose client- having 4 main database) which can be installed anywhere which would connect to a public...
0
by: AMDIRT | last post by:
I have a few questions about IssueVision (from WindowsForms) concerning its scalability and performance. Rather, if I were to implement techniques described here into another application, how...
8
by: Rob S | last post by:
I have UDB 8.1 Personal Edition installed. I'm using Development centre to develop JAVA Stored Procedues. I am unable to debug them. I have installed IBM Distributed Debugger and have set...
9
by: Tony Lee | last post by:
Some time a ago, on this newsgroup the following comments were made in recommending good references for Access (2003) >I used to recommend Dr. Rick Dobson's, "Programming Access <version>" for...
11
by: jason | last post by:
we have developed a .NET class library that defines a family of reusable business objects. the class library is developed in C#, and works quite well. one problem, however, is that as more and...
2
by: Matik | last post by:
Hello, I've follow problem - thing to consider. SQLServer 200 sp3a, ms win 2003 server db simple recovery There is a production database, wich is around 20gb big. Db is backed up each...
9
by: Marc De Schrijver | last post by:
I'm designing an OO Model for a large application, and I have some question on how to model a particular situation; it's not directly related to C# but rather to general OO. The applicaiton will be...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.