Getting Modified date of a particular document in KM Content

Hi,
Can I fetch the modified date of a particular document from KM Content?
I know  i can find the date in settings -> properties. But I want to fetch the value of modified date/time.
I want to save that  modified date/time in particular attribute in a program developed in NWDS so that I can proceed with my code depending on modified date/time.
Please guide me.
Regards
Simin

Belw code snippet gives me the Modified date for the document RFCCall.html stored in documents folder.
public void doContent(IPortalComponentRequest request, IPortalComponentResponse response)
          IUserContext uc = request.getUser();
          IUser user = (IUser)uc.getUser();
          ResourceContext ctxt = new ResourceContext(user);
          RID rid = RID.getRID("/documents/RFCCall.html");
          IResource resource;
          try {
               resource = ResourceFactory.getInstance().getResource(rid, ctxt);
               response.write(resource.getLastModified().toString());
          } catch (ResourceException e) {
               // TODO Auto-generated catch block
               e.printStackTrace();
You need to add a sharing reference to knowledgemanagement for this to work.
Regards
Prashant

Similar Messages

  • How can you find the Last Modified Date of a particular table

    Hi,
    I want to show to the LAST MODIFIED date of a particular table to the user before refreshing the table with new data. Experts please suggest me the way using JDBC-SQL connection.

    There is no generic SQL way for this. It depends completely on the features your DBMS offers. With Oracle you'd need to create column which gets updated in a trigger. I believe MS SQL Server offers a special data type for this, which is updated automatically. I don't know about others.

  • OIM 11g - How to get modified data on a reconciliation event

    Hi,
    We're running OIM 11.1.1.5.2 with Ad (9.1.1) , exchange ( 9.1.1.7), dbum (9.1.0.4) and dbat (9.1.0.5) connectors.
    When we run reconciliation we can get the recon data on the event management tab of the advanced administration console, but, update succeded events show all fields mapped on the reconciliation with the new values only. For example, for AD, if an account on the target resource has its "TelephoneNumber" field updated, we can see the event, but, we cannot identify what was changed on that event was the telephone number, as the event shows all fields on the Ad account...
    Our requirement is to inform th customer as soon as the reconciliation has ocurred for each particular updated account, in a manner that is fast and easy to understand.
    We have the audit on OIM on Resource Form (XL.UserProfileAuditDataCollection) and we can see the upa tables being populated.
    Now, the question is, what is the recommended or most used way to process the information on upa tables? Is there any ootb report that maybe we're missing that shows this info? Are there api's documented to work with audit data (i just couldn't find them)?
    Having in consideration our requirement, I'm thinking on creating a new task for each process form to be triggered by "Reconciliation Update Succeeded" that executes a pl/sql to find events on upa tables related to the user and resource, then parse the generated xml and send an email with old and new values, but I want to be sure there's no ootb or simpler way to do it.
    Thanks.

    Thanks Kevin,
    I think that we found an easier way though. By setting the system property XL.EnableExceptionReports to TRUE, the tables UPA_FORMS y UPA_FORMFIELDS get populated automatically.
    This tables contain information of the fields that were modified an the reason (i.e. 'Reconciliation', 'API').
    I have created a database job that executes a stored procedure that searches for new records on upa_ud_formfields and gets the resource name, resource key, field name, old and new values and then sends an email with all modified data to the corresponding administrators for each resource. I use an auxiliary table on a different schema to keep track of records already read on previous runnings of the job.
    It takes sometime to get the info because we depend first on the running of the recon scheduled job, then the "issue audit message task" job, and finally our own job, but it works.

  • How to get the View for a particular Document position?

    Hi there,
    Does anyone know how to get the "deepest" View that is responsible for rendering a particular Document offset?
    I tried looking at modelToView() and some other methods, but I am lost.
    Can anyone please help me?
    Thanks,
    Swati

    Bart--
    To find the table cell of the insertion point, you could use something like:
    InterfacePtr<ITextStoryThread> storythreadp(txtModel->QueryStoryThread(startPos + 1));
    InterfacePtr<ICellContent> cellcontentp(storythreadp, UseDefaultIID());
    if (! cellcontentp) {
      // Not a table cell, so see if it's the primary thread (kTextStoryBoss/ITextModel).
      InterfacePtr<ITextModel> threadmodelp(storythreadp, UseDefaultIID());
      if (threadmodelp) {
        // It's the primary thread...
      else {
        // It's something else with an ITextStoryThread (note, footnote, etc.).
    else {
      // The insertion point's in a table cell (kTextCellContentBoss).
      InterfacePtr<ITableModel> tableModel(cellcontentp->GetTableModel(), UseDefaultIID());
      GridID gridID(cellcontentp->GetGridID());
      GridAddress gridLoc(cellcontentp->GetGridAddress());
      // ...and so on.
    Hope this helps get you where you want to go.
    Chris Roueche / Freelance Developer

  • Get modified date inside the File content of CM

    hi,
    In CM I have uploaded a file and have set the permission to modify the file to a group of users.Now when each and every time any user modifies the file content I want to have the modified date inside the updated file.
    How can i achieve this?.....
    Please help.....
    Thanks in advance,
    shami.

    Hi All,
    @Parvathy:There is no such property on your files, you should create one in your filter and depending on this custom property your filter should decide if a document update is required or not.
    As already said follow this:
    You have a content filter which can do updates to these files:
    -- Content filter sets a custom property new_modifieddate on each resource after updating resource. (new_modifieddate==cm_modified of resource)
    -- It compares new_modifieddate with cm_modified of resource to determine if it should update the resource with cm_modified.
    @Shami: Use some logging in your Filter code, so that you can make sure your code is being executed. One more way is to dubug you code by setting break points in NWDS (Ofcourse the server should be in debug mode for this option).
    logging :
    http://help.sap.com/saphelp_nw2004s/helpdata/en/a0/58db515b95b64181ef0552dc1f5c50/frameset.htm
    debug:
    http://help.sap.com/saphelp_nw2004s/helpdata/en/5d/31e540b1278631e10000000a1550b0/frameset.htm
    Greetings,
    Praveen Gudapati

  • What is the best and easiest way to get xml data into the rtf document

    Hello Frenz
    I'm using rtf document(with bi publisher desktop plug in installed in the word document)... please suggest me the best way(to get the xml data from tables) to load the xml data into this rtf document..
    I'm not developing oracle apps reports. It is for Oracle retail...
    another doubt is... in the rtf document itself there is oracle bi publisher.. can it be used for generating xml data...
    please bear with me and suggest me a way out
    Thanks and regards

    What will you be using in your production system to generate XML? Or are you just trying out BIP?
    If you're familiar with dbms_xmlquery.getxml , you can pass your SQL to generate the XML output. Save the output in a file and use it in your RTF template.
    If you have Oracle reports, you can create XML output when you run the report.

  • Getting all dates of a particular month and year

    I want to get list of all dates of a particular month and year .
    How to get using Calendar List?

    Create a Calendar object. Set it's month and year. Then call getActualMaximum(Calendar.DAY_OF_MONTH); on the Calendar object. That will tell you how many days are in the month of that year.

  • Get the date of a particular week day from given date

    I have a given date.
    from that date i want to get the date of sunday of that week
    wat is the best possible way to do the same.
    for eg:
    if i am given 03/11/2007 which is a saturday
    i want to get 27/10/2007 which is the sunday which falls in the same week as of 03/11/2007
    can anybody please help.

    hi,
    Here I am posting code for your requirement.
    Here I am hard coding the date value.
    import java.util.*;
    public class DateTest{
         public static void main(String ar[]){
              Calendar calendar =new GregorianCalendar(2007,7,4);
              System.out.println("DAY_OF_WEEK: " + calendar.get(Calendar.DAY_OF_WEEK));
              calendar.set(2007,7,4-calendar.get(Calendar.DAY_OF_WEEK)+1);
              System.out.println("DAY_OF_MONTH: " + calendar.get(Calendar.DAY_OF_MONTH));
              System.out.println("MONTH: " + calendar.get(Calendar.MONTH));
    }

  • How to get the Date in a particular format?

    Hi,
    How to get the Date in the below format? I will be passing the year in my method..
    2/10/2003 9:46:52 PM
    D/M/YYYY H:M:S A
    public Date getDate (String year) {
    Here i want to get the Date in this format
    2/10/<Passed Year> 9:46:52 PM
    Thanks

    This is my code
    public static Date getCalendar(Calendar calendar,int getYear) {
    String      formatted_date="";
         int year = getYear;
         int month = calendar.get(Calendar.MONTH+1);
         int day = calendar.get(Calendar.DATE);
         int hour = calendar.get(Calendar.HOUR);
         int min = calendar.get(Calendar.MINUTE);
         int sec = calendar.get(Calendar.SECOND);
         int am_pm =calendar.get(Calendar.AM_PM);
         formatted_date = month+"/"+day+"/"+year+" "+hour+":"+min+":"+sec+" PM";
         System.out.println("formatted_date is "+formatted_date);     
         o/p : formatted_date is 1/4/2006 1:44:21 PM
         SimpleDateFormat dateFormat = new SimpleDateFormat("dd/MM/yyyy");
    //     DateFormat dateFormat =DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.SHORT);
         Date passdate = new Date();
         try {
              passdate = dateFormat.parse(formatted_date);
         } catch (ParseException e) {
              System.out.println("Invalid Date Parser Exception "+e.getLocalizedMessage()+"DateFormat is "+dateFormat);
              System.out.println("The Date inside the function is "+passdate+"and the year passed is "+year);
    o/p : The Date inside the function is Sat Apr 01 00:00:00 IST 2006and the year passed is 2006
         return passdate;
    Expected O/P is 3/1/2006 1:44:12 PM
         }

  • How to get the data  of a particular attribute

    Hi,
    I want to display some of the names in a table .
    (condition is given in the SELECT statement)
    please tell me what to write in the while loop for getting the data . I used
    while (rs.next()!=null){
    String i =rs.getString("name");
    it`s not compiling.

    replace this line with
    while (rs.next()!=null){
    with
    while (rs.next()){

  • Getting the last modified date of the contact in addressbook

    Hi all,
    Is there any way to get the last modified date and created date of the contacts stored in address book . I have gone through the api docs and could nt find any api's to get the modified date of the particular contact .
    Any help would be greatly appreciated ..
    Regards,
    Mohammed Sadiq.

    Hi,
    Is the above feauture available in AddressBook fraamework ?
    Best Regards,
    Mohammed Sadiq

  • Get Original Date Created/ Document Upload

    Hello, 
    How can i get original Date Created of a document when i make a file Upload? 
    Thanks

    Hey. 
    I ´m looking for Date Created (file). The date that i can see if i make: (Right click
    the file -> Properties). 
    I have a another post here about this issues : http://social.msdn.microsoft.com/Forums/sharepoint/en-US/9e7a461d-fb97-4207-9963-2d4e680d8e54/file-info-return-01011601#81d77556-84b1-43c9-89e2-b5f7f544006e
    Take a look.
    Thanks for help me. 

  • Search results showing incorrect modified date

    Hi All,
    I have a one difficulty in search results.
    Document showing incorrect modified date in search results. And this happens for one document only.
    We have customized the search/results.aspx page, Our document is showing correct modified date in document properties,All Items.aspx like 31/4/2013.
    But when i search with document name in search, result showing incorrect modified date like 24/6/2004.
    I checked with database in SQL, every thing is fine.
    I have updated the Modified date through powershell script for one document and after that this recent modified date is showing in search results.
    But after updating the Modified date through powershell, issued document not showing the recent modified date in search results. still showing as 24/6/2004.
    I should not do edit property and save, to create new version.
    I don't know what is happening in search crawl. All ready full crawl running daily basis.
    I want to check whether this issued document is crawling or not. Could anybody help me to get out of this. what is the main cause of this issue.
    Thanks & Regards
    MD.Liakath ali

    Hi,
    I'm seeing the same issue after upgrading the SharePoint 2010 to SharePoint 2013.
    When I search any upgraded document in SharePoint 2013, the document's "Last Modified Date" was showing an incorrect value in Search Results page but other metadata of document like "Last Modified User" is showing the correct
    value so the problem is not with document crawl, something wrong with Last Modified Date property in Search results.
    I have seen below comment as answer but I didn't understand the solution to fix this issue for all upgraded documents.
    The most likely cause is that there is metadata on the documents that is set to that date which is overriding the other dates in the search result. SharePoint isn't particulary imaginative so it's got to be finding that date from somewhere.
    Do we have any solution for this issue? Is this issue will be addressed in SharePoint 2013 SP1?
    Note: No issues with documents, which uploaded after upgrade.

  • Getting a data from a grid

    Hi All
    In a grid display template i am displaying row of data (there will be one row always in this case).
    and  this grid i made it invisible
    Now i need to get the row of data and display it in the html.
    i can get the data using
    var BatchGrid = document.BatchList.getGridObject();
    var selBatch = BatchGrid.getSelectedCellValue(1);
    we cant select the row in the grid since the grid is invisble.
    How i can get the row without selecting
    Please provide your inputs
    Thanks
    Karthi D

    Hi Karthi,
    Try to use Frontpage and add XMII script assistant in front page under Tools->Add-ins.
    You can learn what all applet methods available and also object method in that.
    Like you will get information for grid applet, or icommand, iBrowser etc etc.
    That will make you easy to understand all methods available.
    There will methods available for Query template , display template etc for which Applet u select.
    Use Wizards.
    Regards
    Padma
    Edited by: Rao on May 8, 2009 11:17 AM
    Edited by: Rao on May 8, 2009 11:45 AM

  • How to insert dummy record as KF =0 when i dont get trx data from customer

    Hi
    In BI DSO, i wanted to insert a dummy record with its Key Fields values = 0 in case i don't get any data for a particular day from customer. Could you pls suggest me what to do.
    Thanks...
    Edited by: Harpal Singh on Aug 18, 2010 3:19 PM

    hello,
        Well my first suggestion is it would be great if you could give us example with data for better understanding. Here is what i understood, at a given date and customer number you want key figure value zero if there is no transaction data for this customer on that date.
    You can write this code at endroutine:
    Step1: You need to select all the customer records from customer infoobject and store that in internal table
    Step2: Now you will compare the internal table with all customer number with the result package ( this result package is nothing but a kind of internal table at end routine ).
    Step3: On comparison with the result package append the result package with reocords of customer which is not found during comaprison..
    If you can give the data i can write sample code.....
    Hope this helps
    thanks
    syed

Maybe you are looking for

  • Just got the new IPod - Warranty Coverage Question!

    So, I just leaped into the 90's and got an IPod - the new color screen video version. I purchased it at Best Lies (Buy) and they mentioned a 3 year warranty that included the battery replacement. It also covered the buttons/wheel/screen going dead ov

  • Using the " character in a to be executed command (EMM)

    Hi, I ran against a small challange building a feature in a EMM based menu. I would like to have an user to change the number dialed in a chat-script but the chat-script command uses the character " in it's command. The same character " is also used

  • Oracle Database Standard Edition One

    I have several Microsoft Access databases (ugh) that thankfully will be shelved to be replaced with Oracle products. I plan on getting Oracle Database SE One because that best fits my #users/#processors. In shopping for the best products to fit my ne

  • Bar codes in Smart Forms

    Hello, Maybe anyone could provide short guidance how to create SmartForm for fixed assets barcode labeling?

  • Simple servlet shoed error in tomcat server sql error

    import java.sql.*; import java.io.*; import javax.servlet.*; import javax.servlet.http.*; public class submit extends HttpServlet      //Connection con;      public void doGet(HttpServletRequest req,HttpServletResponse res) throws IOException,Servlet