How to compare the datetime to find the latest datatime

Hi,
I have an xml payload with multiple fields for date-time. The datetime is populated as below:
2007-04-06T10:46:47.411-05:04
2007-04-06T10:46:47.410+02:01
2007-04-06T10:46:47.411-03:00
2007-04-06T10:46:47.411+09:03
2007-04-06T10:46:47.411-09:03
Now how do I find out which is the latest datetime. Any help is appreciated.
Thanks

Use SimpleDateFormat to parse those strings into java.util.Date objects.
Date is Comparable, so stick them into a list or array, sort it, and grab the last one.
Or just walk down the list, using Date's before() or after() method to see it the current element is before/after the next one.
Calculating Java dates: Take the time to learn how to create and use dates
Parsing
a Date Using a Custom Format
Making Java Objects Comparable
http://java.sun.com/docs/books/tutorial/collections/interfaces/order.html
http://www.javaworld.com/javaworld/jw-12-2002/jw-1227-sort.html

Similar Messages

  • TS2972 used to be able to pick out which songs in iTunes in my computer were not on a 2nd computer on homeshare in iTunes 10.  Now with V11, cant find the button that compares two libraries and finds the songs that are different.  Anyone know how to do th

    Used to be able to pick out which songs in iTunes in my computer were not on a 2nd computer on homeshare in iTunes 10.  Now with V11, cant find the button that compares two libraries and finds the songs that are different.  Anyone know how to do this now?

    Jneklason wrote:
    ~snip~
    I know this email is confusing and really hard to understand...perhaps now you will know how i've been feeling--lost and confused with all the mis-information, with a hit and miss phone, and out of time with all the 1 1/2 hr to 2 hrs EACH wasted on this issue.
    On top of all this, I can't even find out how to file a complaint with anyone higher up than Customer Service.
    I hate to tell you this, but you didn't write an email. You wrote a discussion post on the Verizon Wireless Community forum which is a public peer to peer forum. Unfortunately since you didn't mark your post as a question, the VZW reps that roam this community won't ever see your post. Before you re-post it, don't. Duplicate posts get removed from the community.
    I see there were several missteps both by the reps and yourself in your post. First you should have insisted on returning the phone within the 14 day return policy period. Second which Samsung Galaxy mini model did you purchase? The S3 mini or the S4 mini? Did you do any research prior to deciding on this device. The reps at that time deflected the easiest course of action, by trying to get you to replace the phone under insurance instead of returning the phone. The Early Edge payment option requires the current phone on the line using the early Edge must be returned to Verizon Wireless. Did you once considered going to a third party site like Swappa to purchase a gently used device for your daughter?

  • When I first turned on iMovie all videos from iPhoto automatically were found. Now I have more videos on iphoto, how do I get iMovie to find the new ones?

    When I first turned on iMovie all videos from iPhoto automatically were found. Now I have more videos on iphoto, how do I get iMovie to find the new ones?

    jtcollins wrote:
    if iMovie is open, connect your iPhone to comp. iMovie '11 will now find your phone and look for videos as it would if camera was connected
    (Underline is my emphasis)    
    Hi jt - Alex was actually referring to video clips in iPhoto not appearing in the item "iPhoto Videos" in the Events Library in iMovie - thanks for your post though (the 2 words are very similar).
    John

  • How do I use Spotlight to find the location of a document?

    Spotlight used to show the location of document when I hovered the mouse over an item in its list. It no longer does this. Now it tells me that a document exists and allows me to open the document, but doesn't tell me where to find the document. How do I use Spotlight to find the location of a document?

    Hi Thomas ...
    Open System Preferences > Spotlight then select the Search Results tab.
    Select the all the categories for the search results you want.
    Restart your Mac.
    If that didn't help the Spotlight preferences may be corrupted.
    Go to ~/LIbrary/Preferences
    Move the com.apple.spotlight.plist file from the Preferences folder to the Trash.
    Try Spotlight.
    edited by:  cs

  • When typing I will sometimes look at the document and find the curser moved and the typing is going on in a different area.  How do I stop that curser movement?

    When typing I will sometimes look at the document and find the curser moved.  The typing has been happening in the wrong place.  How do I stop the curser movement while typing?

    You're not the only person asking this question. You might want to read this post, which contains possible solutions, and references support documents:
    https://discussions.apple.com/thread/2322020?start=0&tstart=0
    Others have the same question as you. Post here if this information answered your question; post also if you have any additional questions!

  • HT201363 How the **** do I find the option to change my security questions? I made these questions years ago & have not needed to answer them since.

    I made my apple account years ago. I made the security questions years ago. And therefore I cannot remember the answers to the questions. I keep looking up how to change them & I keep finding the same page that tells me to choose "send rescure email", but that option does not exist at all. I repeatedly tried to remember the right answers & now I am locked out of my account for repeated failed attempts. I need to get into my account so some help would finally be appreciated.

    You need to ask Apple to reset your security questions; ways of contacting them include phoning AppleCare and asking for the Account Security team, clicking here and picking a method for your country, and filling out and submitting this form.
    They wouldn't be security questions if they could be bypassed without Apple verifying your identity.
    (105130)

  • I use Microsoft Office Professional Plus 2010, when clicking a link in Outlook I always get a General Failure box stating 'The system cannot find the file specified' yet it still goes to the specified page. Any ideas on how to resolve this

    I use Microsoft Office Professional Plus 2010, when clicking a link in Outlook I always get a box stating
    General Failure. The URL was "http:// etc etc".The system cannot find the file specified.
    Yet it still goes to the specified page. Any ideas on how to resolve this

    I am having the exact same problem with Windows 7 Professional. Out of the blue, this issue just started a few months ago when running my monthly Windows Backup where I have used a USB drive for the last 3 years, and never ever had this issue before. Most
    of the solutions listed on the Microsoft websites and answers deal with
    "Restore" functions, not the
    "Backup" itself. I have 3 folders being skipped during the backup.
    So I went and changed the Backup from "let Microsoft choose files, directories, etc" to "Let me choose". I included the files and folders that were being skipped, and ran the "Backup" again, and got the same error message,
    but the files that were skipped the first time were "Backed up" finally. This issue is somehow related to my "Libraries"?
    The 3 backup problems are:
    Backup encountered a problem while backing up file C:\Windows\System32\config\systemprofile\My Audio Books\Audio Book Recordings. Error:(The system cannot find the path specified. (0x80070003))
    Backup encountered a problem while backing up file C:\Windows\System32\config\systemprofile\My Audio Books\Audio Book CD Label-Cover Art. Error:(The system cannot find the path specified. (0x80070003))
    Backup encountered a problem while backing up file C:\Windows\System32\config\systemprofile\My Audio Books\Audio Book MP3 Tag Art. Error:(The system cannot find the path specified. (0x80070003))
    Did a "checkdisk" - no problems. Ran a program to fix registry - no problems. All updates up to date. I guess I could eliminate these folders from the Backup folders in the
    Library, and just choose them under the "Users" locations, and be done with it. But I really want to understand this, and fix it. This is within Windows 7 and may be related to Windows Media Player or
    some recent Windows update.  Thanks.

  • Error message on my development workstation: The system cannot find the file specified.

    Post Author: cseverin
    CA Forum: Crystal Reports
    Hi,
    I am currently developing an ASP.NET website using Visual Studio.NET 2005. I am using the .NET 2.0 framework, VB.NET as my programming language and I connect successfully to a SQL Server 2005 database.  I can select, insert, update and delete data from the database elsewhere in my project, so I know basic connectivity isn't an issue.  The problem seems to be with Crystal Reports. 
    I created a folder called 'Reports' in my project and added a Crystal Report file (OpenFiles.rpt) to it.  I designed the report and initally used a hard-coded SQL query as its datasource so I could quickly get the database fields onto the report and preview them.  All worked fine. 
    To make the report accessible to the rest of the website, I created an .xsd dataset file containing the three tables (and their corresponding tableadapters) that the report requires and then redeveloped the report using the dataset as the datasource for the report.  After doing this, the preview no longer worked.
    Next, I added a page to the website and dragged a Crystal Report Viewer Control onto it.  In the code behind the page I wrote:
    Option Strict On
    Imports System.Data
    Imports CrystalDecisions.CrystalReports.Engine
    Imports CrystalDecisions.Shared
    Partial Class Reports
         Inherits System.Web.UI.Page
         Private objOpenFilesreport As OpenFilesReport
         Private rptOpenFiles As ReportDocument
         Private strLastErrorMessage As String = Nothing
         Private errLastException As Exception = Nothing
         Dim strFileKey As String
         Dim strJurisdictionCode As String
         Dim strStaffId As String
         Dim strReportId As String
         Private Sub ConfigureCrystalReports()
              Dim reportPath As String = Server.MapPath("OpenFiles.rpt")
              Dim rptopenfiles As New ReportDocument
              rptOpenFiles.Load(reportPath)  <== I checked this during execution and the value correctly points to the OpenFiles.rpt file in the Reports     folder of my project
              Dim ConnectionInfo As ConnectionInfo = New ConnectionInfo()
              ConnectionInfo.DatabaseName = my database
              ConnectionInfo.UserID = login id of user
              ConnectionInfo.Password = user's password
              SetDBLogonForReport(ConnectionInfo, rptopenfiles)
              CrystalReportViewer1.ReportSource = rptopenfiles
         End Sub
         Protected Sub Page_Init(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Init
             ConfigureCrystalReports()
         End Sub
         Private Sub SetDBLogonForReport(ByVal ConnectionInfo As ConnectionInfo, ByVal myReportDocument As ReportDocument)
              Dim myTables As Tables = myReportDocument.Database.Tables
              For Each myTable As CrystalDecisions.CrystalReports.Engine.Table In myTables
                   Dim myTableLogonInfo As TableLogOnInfo = myTable.LogOnInfo
                   myTableLogonInfo.ConnectionInfo = ConnectionInfo
                   myTable.ApplyLogOnInfo(myTableLogonInfo)
              Next
         End Sub
    End Class
    I added a hyperlink to one of the existing pages on the website to navigate to this page with the report viewer on it.  When I run the website in Visual Studio and click on the hyperlink I get the following:
    Server Error in '/MyTest' Application.
    The system cannot find the file specified.
    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Runtime.InteropServices.COMException: The system cannot find the file specified.Source Error:
    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. Stack Trace:
    &#91;COMException (0x80004005): The system cannot find the file specified.
    &#93;
       CrystalDecisions.ReportAppServer.ClientDoc.ReportClientDocumentClass.Open(Object& DocumentPath, Int32 Options) +0
       CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.Open(Object& DocumentPath, Int32 Options) +126
       CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.EnsureDocumentIsOpened() +442
    &#91;Exception: Load report failed.&#93;
       CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.EnsureDocumentIsOpened() +513
       CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String filename, OpenReportMethod openMethod, Int16 parentJob) +1378
       CrystalDecisions.CrystalReports.Engine.ReportDocument.EnsureLoadReport() +149
       CrystalDecisions.CrystalReports.Engine.ReportDocument.get_DataDefinition() +85
       CrystalDecisions.CrystalReports.Engine.ReportDocument.get_ParameterFields() +158
       CrystalDecisions.Web.CrystalReportSource.BindControlParameter(Parameter parameter) +130
       CrystalDecisions.Web.CrystalReportSource.DataBindParameters() +191
       CrystalDecisions.Web.CrystalReportSource.EnsureParameters(Boolean forceDataBind) +90
       CrystalDecisions.Web.CrystalReportSource.LoadCompleteEventHandler(Object sender, EventArgs e) +47
       System.Web.UI.Page.OnLoadComplete(EventArgs e) +96
       System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +4086
    Version Information: Microsoft .NET Framework Version:2.0.50727.832; ASP.NET Version:2.0.50727.832 
    Any ideas, anyone?
    Also, assuming I can get past this error, I will need to figure out how to fill the tables in the .xsd dataset file.  I have written a class for the dataset that includes functions that populate the tables in the dataset from the database by executing SQL queries.  But how do I call these functions at the time the report is run?
    This is my first Crystal report written in .NET and I've been struggling with it for days now.  Any help would be most appreciated!
    Thanks very much!
    Chris Severin

    hello, the error message is obviously coming from one of the installed mcafee extensions. please directly contact mcafee technical support - they can likely give you more detailed guidance and are the only ones who can fix bugs or make necessary adjustments in the addon.

  • While loading site collection in SharePoint 2010, Error shows "Could not find the file or assembly or one of its dependencies. The system cannot find the file specified."

    I have restored one web application in SharePoint Server 2010 from a different domain and  can complete successfully. Changed each users domain also to old to new one by using Move-SPUser. But While accessing the site collection it is showing an error
    that  "Could not load file or assembly 'A##.SP.Intranet, Version=1.0.0.0, Culture=neutral, PublicKeyToken=03b4f320ebedaffc' or one of its dependencies. The system cannot find the file specified."
    What may be the reason? Please help me to solve this issue since I am stuck up on this .
    Regards 
    Mine1981

    Hi Nico
    Martens,
    Thank you for your reply. But
    how can I find out the custom solutions in the source farm. I didn't got any other details regarding this farm other than WSS_Content, Web application Database, SharePoint_Config database back ups.
    Please help me to solve the
    issue.
    Regards
    Mine

  • Need to know the sqluery to find the disabled date from OIM 9.1.0.1

    Hi Experts,
    Need very urgent inputs from you all for the preparation of our audit.
    We are using OIM9.1.0.1
    We need to know the sqlquery for finding the Disabled date in OIM given the user ids, as currently we are unable to get the exact data from Historical Reports Option in OIM.
    I need to give in this format:
    select usr_login, usr_disabled from schemaname.tablename where usr_login in
    ('aaa','bbb'..... etc)
    We have three attributes :USR_DISABLED_BY_PARENT,USR_DISABLED,USR_DEPROVISIONING_DATE,but none of them give the exact date,
    USR_DISABLED gives just a flag as 1 or 0.
    Also there are no other fields in the corresponding usr table.
    So how to fetch the exact Disabled date from OIM system when I input the user ids.
    Your immediate response is appreciated.
    Thanks
    SS

    In the entire thread many experts have given nice queries in different formats...
    The best approach would be to open up the SQL Developer, connect with the OIM Database and experiment with all sorts of SQL queries provided by all the experts..
    Learn some SQL techniques, like Inner Join etc...
    Then you yourself will be able to figure out what you need, in exactly which format, for which users and for whom you have to restrict
    Then not only this question, you would be able to solve dozens of similar such issues yourself...
    And trust me, nothing can match that...
    Just in case, you are not familiar with SQL Developer,
    http://www.oracle.com/technetwork/developer-tools/sql-developer/downloads/index.html
    Oracle SQL Developer 3.2.1 (3.2.10.09.57)
    September 24, 2012
    The Disabled DATE will be the creation date of that entry in the UPA_FIELDS table when Users.Status changed to Disabled.
    SELECT USR.USR_LOGIN, UPA_FIELDS.CREATE_DATE
    FROM UPA_FIELDS
    WHERE UPA_FIELDS.FIELD_NAME='Users.Status'
    AND UPA_FIELDS.FIELD_NEW_VALUE='Disabled'
    AND UPA_FIELDS.UPA_USR_KEY=USR.USR_KEY
    AND USR.USR_LOGIN NOT IN ('XELSYSADM', 'XELOPERATOR', 'WEBLOGIC');

  • Upgrading to MBAM 2.5: Could not load file or assembly 'System.Web.WebPages.Razor, Version=2.0.0.0.....the system cannot find the file specified.

    Upgrading from MBAM 1.0 to 2.5 on the Administration and Monitoring server (database server already upgraded). To upgrade the administration server, I uninstalled MBAM 1.0 -> Deleted the MBAM website from IIS manually -> Reboot -> Installed MBAM
    2.5. After upgrade if I go to selfservice portal via
    https://myserver.mycompany.com/selfservice, I get this error:
    Server Error in '/SelfService' Application.
    Could not load file or assembly 'System.Web.WebPages.Razor,
    Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its
    dependencies. The system cannot find the file specified.
    Description:
    An unhandled exception occurred during the execution of the current web
    request. Please review the stack trace for more information about the error and
    where it originated in the code.
    Exception Details:
    System.IO.FileNotFoundException: Could not load file or assembly
    'System.Web.WebPages.Razor, Version=2.0.0.0, Culture=neutral,
    PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot
    find the file specified.
    Source Error:
    An unhandled exception was generated during the execution of the
    current web request. Information regarding the origin and location of the
    exception can be identified using the exception stack trace below.
    Stack Trace:
    [FileNotFoundException: Could not load file or assembly 'System.Web.WebPages.Razor, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.]
    System.Web.Mvc.PreApplicationStartCode.Start() +0
    [InvalidOperationException: The pre-application start initialization method Start on type System.Web.Mvc.PreApplicationStartCode threw an exception with the following error message: Could not load file or assembly 'System.Web.WebPages.Razor, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified..]
    System.Web.Compilation.BuildManager.InvokePreStartInitMethodsCore(ICollection`1 methods, Func`1 setHostingEnvironmentCultures) +12980619
    System.Web.Compilation.BuildManager.InvokePreStartInitMethods(ICollection`1 methods) +12980328
    System.Web.Compilation.BuildManager.CallPreStartInitMethods(String preStartInitListPath, Boolean& isRefAssemblyLoaded) +280
    System.Web.Compilation.BuildManager.ExecutePreAppStart() +172
    System.Web.Hosting.HostingEnvironment.Initialize(ApplicationManager appManager, IApplicationHost appHost, IConfigMapPathFactory configMapPathFactory, HostingEnvironmentParameters hostingParameters, PolicyLevel policyLevel, Exception appDomainCreationException) +1151
    [HttpException (0x80004005): The pre-application start initialization method Start on type System.Web.Mvc.PreApplicationStartCode threw an exception with the following error message: Could not load file or assembly 'System.Web.WebPages.Razor, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified..]
    System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +12979668
    System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +159
    System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +12819261
    Anyone know how to solve this? Thanks in advance

    Sorry for late response. I fixed the issue by installing the correct version of ASP .NET 4 from
    here.
    If .NET Framework 4.5 is already installed, also run aspnet_regiis -i from C:\windows\microsoft.net\Framework\v4.0.30319

  • "The system cannot find the path specified" error

    Hi, Thanks for taking the time and reading.
    I had to update an old report that was made in CrystalReports. I copied the rpt files and pasted them into a csharp solution in VS 2010.
    The report structure is of a Main report and 6 subreports. I have to run this Main report many times and feed it a different integer as a parameter.
    I can preview the report in report viewer perfectly. When i try to export the main report into a pdf format
    i get an exception. I have tried a few different formats and it spews the same error. 
    Oddly enough the export sometimes works if the report i am previewing has the "Save data in the report" check box checked. My guess is that this is cached. Also when i run just the subreports through my application, it works.
    Things i have tried:
      I installed: CRRuntime_64bit_13_0_13
      I installed: CRforVS_13_0_13
      Took a look at the Procmon and i could not find an access denied error
      Event Viewer has no detail.
      Changed Registry values of ConnectionDirectoryPath and ReportDirectoryPath to "c:\"
    Code:
      if (!Directory.Exists(filePath))
      Directory.CreateDirectory(filePath);
      string fileName = filePath + string.Format(GlobalVaraiables.FILE_SAVE_NAME, i);
      cryRpt.SetParameterValue(GlobalVaraiables.FUND_DATA_KEY_PARAMETER, i.ToString());
      cryRpt.ExportToDisk(CrystalDecisions.Shared.ExportFormatType.PortableDocFormat, fileName);
    Error message:
      System.Runtime.InteropServices.COMException (0x80004005): The system cannot find the path specified.
        at CrystalDecisions.ReportAppServer.Controllers.ReportSourceClass.Export(ExportOptions pExportOptions, RequestContext pRequestContext)
        at CrystalDecisions.ReportSource.EromReportSourceBase.ExportToStream(ExportRequestContext reqContext)
        at CrystalDecisions.CrystalReports.Engine.FormatEngine.ExportToStream(ExportRequestContext reqContext)
        at CrystalDecisions.CrystalReports.Engine.FormatEngine.Export(ExportRequestContext reqContext)
        at CrystalDecisions.CrystalReports.Engine.ReportDocument.ExportToDisk(ExportFormatType formatType, String fileName)
        at FundDataPDFSaver.SaveReport.GenerateReports(List`1 l) in C:\Users\user.name.here\Documents\Visual Studio 2010\Projects\FundDataToPDF\FundDataPDFSaver\SaveReport.cs:line 74
    System Details:
    Windows 7 Enterprise N  64 bit
    ServicePack 1
    IDE:
    Visual studio 2010 .Net framework 4
    Application is set to run as "Any CPU"
    CrystalReports :
      dll's: C:\Program Files (x86)\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Common\SAP BusinessObjects Enterprise XI 4.0\win32_x86\dotnet\CrystalDecisions.CrystalReports.Engine.dll
        C:\Program Files (x86)\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Common\SAP BusinessObjects Enterprise XI 4.0\win32_x86\dotnet\CrystalDecisions.ReportSource.dll
        C:\Program Files (x86)\SAP BusinessObjects\Crystal Reports for .NET Framework 4.0\Common\SAP BusinessObjects Enterprise XI 4.0\win32_x86\dotnet\CrystalDecisions.Shared.dll
    Thanks for your help

    I don't see where you're ever setting the logons for the tables in the report and subreports.  The reports with saved data are working because they already have data in them.  The reports without saved data are not working because they don't know how to connect to the database.
    See the Database section here Crystal Reports for .NET SDK Samples - Business Intelligence (BusinessObjects) - SCN Wiki for more information about how to set the logons.
    -Dell

  • Outlook 2010 - sending mail with attachment - "The system cannot find the file specified"

    Hi forum Fellows,
    I have the following failure scenario:
    1. A user receives an e-mail with an attachment.
    2. The user opens the attachment --> Forwards the mail and writes something in the body of the e-mail
    3. For whatever reason the user leaves the e-mail and works on something else --> the user comes back to the e-mail an hour or more later.
    4. The user then wants to send the e-mail but gets the following error message: "The system cannot find the file specified"
    5. The effect is that the user cannot send the e-mail.....
    ------------------------------ TROUBLESHOOTING -----------------------
    - I can see that when the user opens an attachment this attachment is saved in the OutlookTemp folder. Actually, there is a difference between opening the attachment before or after clicking forward on the e-mail.
    ---- Before: Two files is written to the OutlookTemp folder. For example if the attachment name is FileX.pdf - there will be a FileX.pdf but also a FileX (2).pdf in the folder (if OutlookTemp is empty/do not contain a file with the name FileX.pdf already)
    ---- After: Only one file is written to OutlookTemp. That is FileX.pdf
    - Running Process Monitor when trying to forward the e-mail I can see that Outlook is calling a file that is not in the OutlookTemp folder anymore.
    **** To me this is the heart of the issue. For some reason, when a user has an e-mail with an attachment open for an extended period of time (not sure on exactly how long is necessary), files in the OutlookTemp folder is deleted - files that Outlook is depending
    on to be there.
    - Going with a totally clean OutlookTemp folder does not help.
    ------------------ NOW WHAT ---------------
    - The question now is: Is this by design? Can it be fixed by some Outlook 2010 patch? Or perhaps a group policy/registry setting as a workaround.
    ------------------------------ TECH. INFO -----------------------
    Outlook 2010 v14.0.7132.5000
    Outlook bit depth: x86
    Running on a 2008R2 SP1 TS environment.
    No antivirus on the TS
    Looking forward to hear from you.
    Regards The Red Baron
    Red Baron

    Hello Red Baron,
    Although not a complete answer, the way to treat attachments in emails require some discipline:
    1. Never open an attachment directly from the email (and NEVER edit it from there). Always save it in a known location as the desktop or (better) in a designated document folder. Then you can proceed as usual, like editing the contents, printing, forwarding
    the new version etc.
    2. Directly forwarding the attachment is ok, along with additional text in the body of the email.
    3. Having any (unsaved) document open for several hours should
    never occur. What if there is a power outage?
    Bottom line is thus Discipline. This is regardless of Operating System (which might handle temporary files differently).
    These are the rules I teach my customers and they never leave any document unsaved for hours ...
    Best regards George

  • Unable to open the physical file "D:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\DATA\abc.mdf". Operating system error 2: "2(The system cannot find the file specified.)".

    hi,
    am running the below command for moving sql serevr mdf and ldf files  from one  drive to another : c  drive to d drive:
    but am getting the below error
    SQL Server\MSSQL11.MSSQLSERVER\MSSQL\DATA\abc.mdf". Operating system error 2: "2(The system cannot find the file specified.)".
    use master
    DECLARE @DBName nvarchar(50)
    SET @DBName = 'CMP_143'
    DECLARE @RC int
    EXEC @RC = sp_detach_db @DBName
    DECLARE @NewPath nvarchar(1000)
    --SET @NewPath = 'E:\Data\Microsoft SQL Server\Data\';
    SET @NewPath = 'D:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\DATA\';
    DECLARE @OldPath nvarchar(1000)
    SET @OldPath = 'C:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\';
    DECLARE @DBFileName nvarchar(100)
    SET @DBFileName = @DBName + '.mdf';
    DECLARE @LogFileName nvarchar(100)
    SET @LogFileName = @DBName + '_log.ldf';
    DECLARE @SRCData nvarchar(1000)
    SET @SRCData = @OldPath + @DBFileName;
    DECLARE @SRCLog nvarchar(1000)
    SET @SRCLog = @OldPath + @LogFileName;
    DECLARE @DESTData nvarchar(1000)
    SET @DESTData = @NewPath + @DBFileName;
    DECLARE @DESTLog nvarchar(1000)
    SET @DESTLog = @NewPath + @LogFileName;
    DECLARE @FILEPATH nvarchar(1000);
    DECLARE @LOGPATH nvarchar(1000);
    SET @FILEPATH = N'xcopy /Y "' + @SRCData + N'" "' + @NewPath + '"';
    SET @LOGPATH = N'xcopy /Y "' + @SRCLog + N'" "' + @NewPath + '"';
    exec xp_cmdshell @FILEPATH;
    exec xp_cmdshell @LOGPATH;
    EXEC @RC = sp_attach_db @DBName, @DESTData, @DESTLog
    go
    can anyone pls help how to set the db offline. currently  i  stopped the sql server services from services.msc and started the  sql server agent.
    should i stop both services for moving from one drive to another?
    note: I tried teh below solution but this didint work:
    ALTER DATABASE <DBName> SET OFFLINE WITH ROLLBACK IMMEDIATE
    Update:
    now am getting the message :
    Msg 15010, Level 16, State 1, Procedure sp_detach_db, Line 40
    The database 'CMP_143' does not exist. Supply a valid database name. To see available databases, use sys.databases.
    (3 row(s) affected)
    (3 row(s) affected)
    Msg 5120, Level 16, State 101, Line 1
    Unable to open the physical file "D:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\DATA\CMP_143.mdf". Operating system error 2: "2(The system cannot find the file specified.)".

    First you should have checked the database mdf/ldf name and location by using the command
    Use CMP_143
    Go
    Sp_helpfile
    Looks like your database CMP_143 was successfully detached but mdf/ldf location or name was different that is why it did not get copied to target location.
    Database is already detached that’s why db offline failed
    Msg 15010, Level 16, State 1, Procedure sp_detach_db, Line 40
    The database 'CMP_143' does not exist. Supply a valid database name. To see available databases, use sys.databases.
    EXEC @RC = sp_attach_db @DBName, @DESTData, @DESTLog
    Attached step is failing as there is no mdf file
    Msg 5120, Level 16, State 101, Line 1
    Unable to open the physical file "D:\Program Files\Microsoft SQL Server\MSSQL11.MSSQLSERVER\MSSQL\DATA\CMP_143.mdf". Operating system error 2: "2(The system cannot find the file specified.)"
    Solution:
    Search for the physical files(mdf/ldf) in the OS and copy to target location and the re-run sp_attach_db with right location and name of mdf/ldf.

  • "The system cannot find the file specified" - error reading properties file

    I have packaged a class file and a .properties file in the same folder as a ejb-jar file and in the class file i try reading the properties file and it throws me the error - "The system cannot find the file specified". But when I put the complete path, it has no problem finding the file.
    I know that this must be the problem with classpath, but can anybody tell me why it is not finding the properties file even if they are in the same folder. How do I make class files find .properties file which are in a folder.
    Any help will be greatly appreciated.

    Hi,
    I am not sure if your question is realted to the Oracle Application Server - anyway, if you are packaging a class file and a properties file in a JAR File, you need to read the contents in a different manner...something like this... :
    URL url = new URL("jar:file:/home/duke/duke.jar!/");
    JarURLConnection jarConnection = (JarURLConnection)url.openConnection();
    You might want to have a look at this link for more information :
    http://java.sun.com/docs/books/tutorial/index.html
    You may also get better responses if you post your question in one of the Java Forums.
    Regards,
    Sandeep

Maybe you are looking for

  • Setting up Online chat or realt ime messaging with iWeb

    I am new to this, so apologies if question is niave. I want to be able to to set up a messaging system through a web-site (created with iWeb) & have an online chat facilitiy preferably in real time, rather than posts on a messge board, so I can ask q

  • Wifi error - HELP!

    I have trouble connecting to Wifi connections, ive tried it at home and work. Soon after i enter the password i get the error message saying 'Unable to connect to Wifi connection'... i have been trying this for months now. Could it be a virus? Will i

  • Why can I not take pictures since I updated my Iphone?

    It will act as if I am taking a picture but it will not save. Please help, thanks.

  • Adobe Air Application only works using Super Administrator account on Windows XP

    Good day i really need some help. I developed air application that uses remote service, sql lite etc. It is working on my computer WIndows XP sp2. To test, i even created a guest account and it works fine. But when i deployed it to our client, the ap

  • Multiple MPLS Carriers/Networks

    Does anyone have any experience with using 2 MPLS carriers for load balancing. We'd like to have a primary MPLS network with ATT and then a backup MPLS network with MCI. But rather than use MCI strictly for backup we'd like to load balance traffic ac