473,626 Members | 3,245 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

TimeZones - help wanted ... help needed ... desperate for help

Hello,

I am writing an application that will be used across multiple time zones
(Eastern to Pacific) and since much of the application revolves around time
stamps, I need a best practice for storing time information in a database
and displaying it correctly to the user (adjusted for his respective time
zone). I have been thinking about using UTC and adjusting everything when I
output it, but then the user cannot use the native data in the database
(e.g. for reporting services).

Is there any elegant way to do this (my dream would be a session-specific
time zone setting that will adjust all date to string and string to date
functions). Anybody had a similar problem?

I CANNOT SAY HOW MUCH YOUR HELP WILL BE APPRECIATED

Oliver
Jul 21 '05 #1
1 1259
Does it need to be adjusted for the user? Would it work to simply display
EST or CST along with the date/time?

I like your idea about using UTC the best, because any way you cut it, the
user will have to make adjustments for the time unless you have a field for
each time zone and store the info for each time zone. But, this seems like
a huge waste to me.

You mentioned having the user access native data for reporting. How are
these reports generated?

What type of database are you using (SQL?)?

Do the users actually "see" the data in the database?

"Oliver" <sp**@deviso.co m> wrote in message
news:1104398554 .4cff3923c180ed 9cb74037ebe6a8c 43e@teranews...
Hello,

I am writing an application that will be used across multiple time zones
(Eastern to Pacific) and since much of the application revolves around
time
stamps, I need a best practice for storing time information in a database
and displaying it correctly to the user (adjusted for his respective time
zone). I have been thinking about using UTC and adjusting everything when
I
output it, but then the user cannot use the native data in the database
(e.g. for reporting services).

Is there any elegant way to do this (my dream would be a session-specific
time zone setting that will adjust all date to string and string to date
functions). Anybody had a similar problem?

I CANNOT SAY HOW MUCH YOUR HELP WILL BE APPRECIATED

Oliver

Jul 21 '05 #2

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

Similar topics

20
3271
by: msa | last post by:
Hi there, First off, let me say that I know that launching to full screen is a bad idea. I would never do it given the choice, but I must follow orders from my boss, the boss that desparately wants a desktop application made out of Internet technologies. We're writing an application that has JavaScript enabled as a client machine requirement. We need to support Windows with IE 5+ and Netscape 7+ plus Mac with IE 5+ and Netscape 6.2+.
13
7020
by: Michael | last post by:
I would like to set the timezone of a thread to allow me to calculate the UTC time for data sourced from a number of time zones. Although this can be done in C and C++, I annot find how to do this is C#. Can this be done ? If so how ? Please note setting the culture does not impact the timezone and a culture (like en-US) may have many timezones.
1
244
by: Oliver | last post by:
Hello, I am writing an application that will be used across multiple time zones (Eastern to Pacific) and since much of the application revolves around time stamps, I need a best practice for storing time information in a database and displaying it correctly to the user (adjusted for his respective time zone). I have been thinking about using UTC and adjusting everything when I output it, but then the user cannot use the native data in...
0
1144
by: Robert Treat | last post by:
I am trying to figure out if there is a way to determine the timezones supported in postgresql from within the database. If you look at http://www.postgresql.org/docs/7.4/static/datetime-keywords.html it notes that time zone information is system dependent, (I interpret to mean that anything I find in /usr/share/zoneinfo on linux should be supported, can someone confirm that?) so how can an external app determine which timezones are...
3
1375
by: Mark | last post by:
We are all, or at least most of us, are writing web applications that can be accessed from any place on the planet. And yet Microsoft has yet to write a datetime object that can deal with anything other than local and UTC time. I have users in Toronto. I have users in Bangor. Why can't I convert their dates and times from one place to another? I can convert my local time to the Japanese calendar. I can convert it to the Gregorian...
7
1677
by: Ladysniper | last post by:
DESPERATE doesn't begin to describe it. Can someone PLEASE tell me what is WRONG with this code? Now..a bit of background. It is a search results page for http://www.azsoma.info/directory.htm. (use Scottsdale for the city) If you go look, you see that the search results post (I do have my table borders up for debugging) but it doesn't line up with the table above it...the whole scroll background doesn't show up and I cannot get
7
4260
by: =?Utf-8?B?U3R1?= | last post by:
I have a ASP.NET Ajax app (using client library) calling ASP.NET Ajax-enabled web services. We are making use of the javascript proxies generated by ASP.NET Ajax. The problem we have is that the UTC dates sent by the browser are being adjusted for timezones by the server, but we do not want dates adjusted for timezones. For example, the user enters the date of a transaction as '25 May 2007'. That ends up as a javascript Date()...
7
3851
by: David T. Ashley | last post by:
In a web database (PHP), per user, I'd like to allow each user to specify their timezone (this would change how times are adjusted for display for that user). How do I enumerate all possible timezones from a PHP script or compiled 'C' program? Given a specific timezone, how do I get the time adjustment from UTC (which can vary, based on daylight savings rules)?
27
5309
by: Sanjay | last post by:
Hi All, I am using pytz.common_timezones to populate the timezone combo box of some user registration form. But as it has so many timezones (around 400), it is a bit confusing to the users. Is there a smaller and more practical set? If not, some suggestions on how to handle the registration form effectively would help me a lot. thanks Sanjay
0
8269
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8203
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8711
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8642
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8368
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7203
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5576
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
2630
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1815
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.