Can set any date except 28-03-2004 02:00:00

It seems I cannot set the datetime to 28/03/2005 02:00:00 (the problem is the hour).
I have the following pieces code:
1.
Date d0 = new Date("03/28/2004 02:00:00");
System.out.println(d0);
prints out Sun Mar 28 03:00:00 CEST 2004: the hour is 3 instead of 2
2.
Calendar startCal = GregorianCalendar.getInstance(Locale.ITALY);
startCal.set(Calendar.DAY_OF_MONTH, 28);
startCal.set(Calendar.MONTH, Calendar.MARCH);
startCal.set(Calendar.YEAR, 2004);
startCal.set(Calendar.HOUR_OF_DAY, 0);
startCal.set(Calendar.MINUTE, 0);
startCal.set(Calendar.SECOND, 0);
startCal.set(Calendar.MILLISECOND, 0);
Date start = startCal.getTime();
Calendar endCal = GregorianCalendar.getInstance();
endCal.set(Calendar.DAY_OF_MONTH, 28);
endCal.set(Calendar.MONTH, Calendar.MARCH);
endCal.set(Calendar.YEAR, 2004);
endCal.set(Calendar.HOUR_OF_DAY, 5);
endCal.set(Calendar.MINUTE, 0);
endCal.set(Calendar.SECOND, 0);
endCal.set(Calendar.MILLISECOND, 0);
Date end = endCal.getTime();
while(!startCal.getTime().after(end)){
startCal.add(Calendar.HOUR_OF_DAY, 1);
System.out.println(startCal.getTime());
It prints out
Sun Mar 28 01:00:00 CET 2004
Sun Mar 28 03:00:00 CEST 2004
Sun Mar 28 04:00:00 CEST 2004
Sun Mar 28 05:00:00 CEST 2004
Sun Mar 28 06:00:00 CEST 2004
and it skips Sun Mar 28 03:00:00 CEST 2004
3.
Calendar cal = GregorianCalendar.getInstance(Locale.ITALY);
cal.set(Calendar.DAY_OF_MONTH, 28);
cal.set(Calendar.MONTH, Calendar.MARCH);
cal.set(Calendar.YEAR, 2004);
cal.set(Calendar.HOUR_OF_DAY, 2);
cal.set(Calendar.MINUTE, 0);
cal.set(Calendar.SECOND, 0);
cal.set(Calendar.MILLISECOND, 0);
Date d = cal.getTime();
System.out.println(d);
it prints out Sun Mar 28 03:00:00 CEST 2004 !!!!
It seems I am unable to set hour to 2 am for the 28th March 2004. The same for 27th 2005.
Where I am wrong ? Is it a bug ? For the other days it works correctly.
thanks for your help

Hi
Your problem is due to Daylight Saving Time. The dates you are using are the dates seheduled for the switch between GMT+1 and GMT+2
See: http://wwp.greenwichmeantime.com/time-zone/europe/italy/

Similar Messages

  • Can set any IP on ACS 4.0 SE - accept the one I need

    We are trying to upgrade from an ACS 3.2 for Windows server to our new ACS 4.0 SE box. We have upgraded the Windows box to 4.0, backed up the configuration and restored it to the new box. We have pointed a couple of clients to the new box for testing, and can authenticate. So far so good, but when we went to the final step, assigning the IP address of the old server to the new box, we had a problem ? the ACS SE box will not let us assign the address to the local NIC ? I get an message that the configuration could not be assigned to the NIC.
    To go into detail on what was done:
    The Windows server was changed from x.x.3.45 to x.x.0.45 (we use a 255.255.248.0 subnet mask), and rebooted.
    On the ACS SE box, I used set IP to change the IP from x.x.0.20 (used for testing and setting up the configuration) to x.x.3.45. The system would not complete this step - This is when The system indicated that the configuration could not be applied to the NIC.
    I then set the NIC to DHCP, which was success fully applied. I then set the NIC to x.x.3.46, which it also accepted. At this point I thought it may be doing DNS lookup, and seeing another host name for the IP, so I deleted the PTR record for x.x.3.45, and tried setting that as the IP again. I got the same response.
    I thought it for some reason could be detecting an IP conflict, so I tried setting the IP to an address I knew was in use. As I expected, this did not work, but the error did say IP conflict ? and I was not getting that error on x.x.3.45.
    At this point I moved the connection on the ACS to the other Ethernet interface, but that did not improve the issue.
    I tried performing a reboot on the ACS box, but still could not set the desired IP address. At this point what I thought would be a 5 minute outage for VPN authentication had lasted 45 minutes, and I had to put the target address back on the Windows ACS server.
    Any idea what is causing this? I can set the IP address of the ACS SE to any IP accept for the one that I need! Since we have 70+ Cisco devices that point to x.x.3.45 for authentication, we really do not want to change the address of our ACS.

    You need to open a TAC case with Cisco for this.
    If I recalled this correctly, the old IP
    address is save into a registry file and when
    you backup the configuration, that registry
    containing the old IP address will be in there.
    When you restored the configuration, it will
    restore the old IP address along with it.
    Cisco TAC can help you modified the registry
    to fix this problem.
    You do not have this problem when you run
    Freeware TACACS+. You can change the IP of
    the box at anytime and not breaking anything.
    David
    CCIE Security

  • Do we can set any scroll option in the query designer?

    Hi,
    I would like to know is there any setting for scroll option at the query designer level.
    This is because if I look at some reports so I could see little ups and down (small up and down arrows) symbol at the column level, and is enabled for only few reports.
    Need some input on the same.
    Thanks

    Hi
    I think you are right clicking on KeyFigures Heading, instaed of that can you on any Keyfigure (example KF1 and KF2 etc..). once you done that you will see the following options.
    EDIT     
    COPY    CTRL + C
    CUT       CTRL + X
    PASTE   CTRL + V
    DELETE   DEL
    WHERE USED LIST
    LEVEL DOWN         CTRL+ >
    LEVEL UP     CTRL + <
    PROPERTIES   ALT + ENTER
    please select the highlighted options on the required key figures, then execute the query.
    regards
    Pavan

  • When using numerous browsers,  i can load any site, except ebay!! What's with that??

    I have done all the normal corrections... such as repairing permissions and startup disk.  I have also cleared the cookies and other website data.  Ebay is the only website that I have tried that won't load... Safari, Chrome, Firefox, Camino and Opera... none can open to eBay website...  Other computers and my iphone have no problem using my wifi to load this site.  WTH????

    AVCHD:
    1080/60i @ 24, 17, 12, 5 Mbps
    (all video interpolated up from less than 1,440x1,080 pixels;
    Read more: http://reviews.cnet.com/digital-camcorders/jvc-everio-gz-hd500/4505-6500_7-33949 105.html#ixzz1N9w4EXt6
    G'Day Ian,
    This is what the camera shoots. The NTSC version anyway.
    Al

  • Can not change data in Input Ready Query

    All,
    I have created an input ready query on an aggreagation level which has one transactional cube underlying it however, after run the query I am unable to change data in the cells even though I get a warning message saying query is ready for input
    Note:
    1. The underlying realtime cube is in "Planning Mode:Loading not allowed" state in rsa1
    2. I tried including all characteristics so that the record can be uniquely identified at that aggregation level).
    3. I am not using any characteristic restrictions
    4. I have not set any data slices
    5. I have set the property for Planning "Start query in Change Mode"
    6. I have set the 'Key Figure' Planning Properties to "Can be changed Manually or via Planning Functions" for the key figures
    7. I do not have currency/unit in row/column.
    8. There are any locks occurring
    Any pointers welcome.
    Thanks,
    Milind

    Hi Milind,
    Was wondering how was your problem solved. I get the same message when I run the query in web from query designer and in bex analyzer the cells are not updated with the changes that I make.
    I am hitting my head against the wall to figure what could be the problem as my plan query is simply based on aggregation level created directlty upon the real time info cube.
    Have cross checked all the points that you mentioned in this post but I cells do not change.
    There should be some way around to solve this problem.
    Thanks

  • XL Reporter not getting any data

    <b>Hi</b>
    When I am using XL Composer and generating report using it, I am getting data what the fields I have dragged. Not getting any data when generating same report in organizer from composer except the Title field names. Before I got but now I am not getting.
    <b>STEPS Taken</b>  
                     XL Reporter Composer Tool bar
                     Generate
                     Generate(Window)(Name: given Sample & checked Generate report    then ok)
    And having another problem when generating sample reports I am getting data and when editing that report are preparing new with some fields, I am not getting any data.
    <b>Example:</b>   I have made Edit of Bank Book and placed extra field Document No,   saved the report and generated I am not getting any data except titled fields.
         In new report I have taken BP Code and sales Employee I am not getting any data.
    Please Can any one help me,   It is urgent.
    Thanks in Advance.
    <i><b>Urs
    Sindhu</b></i>

    If you did not select any "total" field (quantities, totals, etc), XL Reporter will show data only at report composer. It will not work at final XL Report itself.
    This is a normal behaviour of XL Reporter, unfortunetaly.
    If you are trying to create a simple list of records, I suggest to use Query Generator, combined to PLD in order to get a formatted report.

  • Can't display data that exist in cupe

    Hi All,
    I get a problem which is thar even i entered data in the cube i cant display with charecteristics. When i go to bw and display data if i say select charecteristics i can see any data but if i dont select charecteristics i can display data. Also when i enter data and sen data it say succesful but i loose data on view. Have anyone get any problem like that thanks for your interest.
    Kasim

    Hi,
    The code you sent appears to be the Audio Talkthrough example with several modifications. Here's the first thing I noticed that appears to be incorrect: You're using the BF AD1871 Wait on Data Ready Flag VI to fill the sub-buffer, then you go into a loop and get the contents of that buffer 256 times. You should be filling the buffer each time before you get the buffer instead of only filling it once. You also aren't resetting the data ready flag by using the BF AD1871 Clear Data Ready Flag VI.
    Message Edited by Michael P on 07-28-2006 09:55 AM
    Michael P
    National Instruments

  • Can you retrieve data when stuck in recovery mode

    Curious if you can reset an iPod touch 4th gen to get data backed up before you restore?  Daughters iPod is stuck on the screen that shows the USB cable and the iTunes logo.  When I plug it in, iTunes detects it & only gives me the option to restore to factory settings and that I will lose the content.  2yrs worth of video and pics of her baby sister is going to be hard to lose if no other way around...

    See if one of these program will kick it out of recovery mode:
    For PC
    RecBoot: Easy Way to Put iPhone into Recovery Mode
    If necessary:
    Download QTMLClient.dll & iTunesMobileDevice.dll for RecBoot
    and                                           
    RecBoot tip
    For MAC or PC       
    The Firmware Umbrella - TinyUmbrella
    Next, restore the the iPod and see if you can get any data off the restored iPod
    via How to perform iPad recovery for photos, videos
      Wondershare Dr.Fone for iOS: iPhone Data Recovery - Wondershare Official

  • How applet can read continuous data stream

    How applet can read continuous data from server(like database update)

    You can keep opened a socket to the server. You can send any data from/to the applet in that way.

  • Can you please help to understand how the firefox decides on the Expires date for a cached javascript file ( my server did not set any Expire header, but firebox set it down).

    # Question
    Can you please help to understand how the firefox decides on the Expires date for a cached javascript file ( my server did not set any Expire header, but firebox set it down). I tried to understand but different javascript file gets different Expires date value when it is being cached. Please help me as I tried lot and could not get proper answer for this. Thanks in Advance.

    Try posting at the Web Development / Standards Evangelism forum at MozillaZine. The helpers over there are more knowledgeable about web page development issues with Firefox. <br />
    http://forums.mozillazine.org/viewforum.php?f=25 <br />
    You'll need to register and login to be able to post in that forum.

  • I have a smartphone but dont want any data, can I set up my account so I dont have to pay the monthly access fee?

    I have a smartphone but dont want any data, can I set up my account so I dont have to pay the monthly access fee?

    No you are required to do so.

  • Is there any way we can set default value for a Date Attribute to current date in Master Data Services

    Is there any way we can set default value for a Date Attribute to current date in Master Data Services.
    I as well wants to know that is there any posibility to show Calendar control while input data into respective date attributes.
    Thanks.

    Hi Anagha,
    So far i havent found any way to set todays date by default from MMI, but i guess this flow should work as workaroud
    1. Add buisness rule which can set a default value when Date = NULL/Blank
    2.get the entity table ,use -select EntityTable from mdm.tblEntity where Name = '<enter entity name>'
    3.Go to that table and add a after update trigger like
    if uda_<entityid>_<attributeid(Date attribute)> = default value
    update uda_<entityid>_<attributeid(Date attribute)> =getdate() where id = <LastUpdatedRow>
    I will check on this too from my side.
    By the way AFAIK i dont think so calendar control integration is possible .

  • HT1339 Hi i have an I pod and i had used it as hard disk also. Now when ever i connect it with my Laptop it shows restore to factory setting....i wanted to knwo is there any way i can save the data which i had already stored in the I pod

    Hi i have an I pod and i had used it as hard disk also. Now when ever i connect it with my Laptop it shows restore to factory setting....i wanted to knwo is there any way i can save the data which i had already stored in the I pod. I dont want to loose that data???

    sure pretty simple.  make a backup of your current settings
    http://support.apple.com/kb/HT1766?viewlocale=en_US
    then restore device from old backup you need pics off of
    then import pics to computer
    http://support.apple.com/kb/HT4083
    you may need to save pics to camera roll first
    then restore the new backup and sync pics back to phone via itunes
    Peace, Clyde

  • TS3988 When i update my iphone to ios 6.1.3 I can not restore my data neither from icloud nor from my device.How can I restore again. I do not have any backups except the one on icloud.

    When i update my iphone to ios 6.1.3 I can not restore my data neither from icloud nor from my device.How can I restore again. I do not have any backups except the one on icloud.

    What happens when you try to restore from icloud?
    instructions here, under line "restore from icloud."
    iOS: How to back up and restore your content - Support - Apple

  • How can I set the data binding between Web Dynpro & Database table

    Dear friend,
    I am a beginner of Web Dynpro. I want to develop my simple project like these:
    1. Create my own database table via Dictionary Project such as TAB_USER and have 3 fields: USER_ID, USER_NAME, USER_POSITION and I have already deployed & archived it.
    2. Create my own Web Dynpro Project, and create the input fields as User ID, User name, User position and icon 'Save' on the selection screen and I have deployed it already.
    For the process, I want to input data at the screen and save the data in the table, please give me the guide line like these:
    1. How can I set the data binding between Web Dynpro and Database table ?
    2.  Are there any nescessary steps that I will concern for this case?
    Sorry if my question is simple, I had try  to find solution myself, but it not found
    Thanks in advances,
    SeMs

    Hi,
    You can write your own connection class for establishing the connection with DB.
    Ex:
    public class  ConnectionClass {
    static Connection con = null;
    public static Connection getConnection() {
    try{
    Context ctx = new InitialContext();
    DataSource ds = (DataSource) ctx.lookup("jdbc/TSPAGE");
    con = ds.getConnection();
    return con;
    }catch(Exception e){
    return null;
    You can place the above class file in src folder and you can use this class in webdynpro.
    You can have another UserInfo class for reading and writing the data into the DB .
    Regards, Anilkumar
    PS : Refer
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/java/simple java bean generator for database.pdf
    Message was edited by: Anilkumar Vippagunta

Maybe you are looking for

  • Cannot import .mp3 files into Audition 3.0

    I just reinstalled after reformating (I was already on Windows 7 x64 Ult, just changed primary hard drives), now when I try to import an .mp3 file into Audition 3.0, it tells me that is isn't a supported file type. Suggestions? Correction: I cannot o

  • RMBP random crashes Yosemite

    Any idea what this crash report means? I've removed the UUIDs I've had this crash a few times now. Thanks! *** Panic Report ** Machine-check capabilities: 0x0000000000000c0a family: 6 model: 70 stepping: 1 microcode: 15 signature: 0x40661 Intel(R) Co

  • Displaying Specific xml data.

    Hi there, I have a database exporting stock detail as xml data.  I've been using spry to format. What I was wondering, is it possible to filter to display only certain data? My xml data contains electrical products. Can I filter to only display certa

  • Rtmp on iOS?

    i wanna stream live videos based on rtmp by using adobe air. i successfully ported application(originally for android) and other things work well but i cannot play any video(live not recorded) here some retrieved texts show that ported application ca

  • Initializing Installer for Audition CS5.5

    I tried to install Audition CS5.5 but got this message: "Installer failed to initialize". What could be the reason for this? How to solve? Alex