locked
Error regarding Concatenation function in office MOSS 2007 RRS feed

  • Question

  • I have created a list in Office sharepoint 2007. I have created a new coloumn, that needs to be a calculated value of Date(ie created by) and ID.

    I used  "=CONCATENATE(TEXT([created], "dd-MM-YYYY"), " ", [ID])." It is working fine.

    Problem is If I create a new item only date section is displayed, and if try again go to calculated value section and just give ok, It is working fine.

    Kindly help me out in this issue.

     

    • Moved by Mike Walsh FIN Friday, May 6, 2011 10:42 AM admin question (OOB function usage) (From:SharePoint - Development and Programming (pre-SharePoint 2010))
    Friday, May 6, 2011 7:09 AM

Answers

  • Hi,

    I agreed with vivek, you should create one more column in your list with auto generated number. Then use this column instead of ID.

    OR else,

    You can create custom event handler (Events: ItemAdded and ItemUpdated), which will concatenate both the columns (Created and ID) value and save in custom column. Here you can use the item ID in your custom event handler.

    Off Topic:

    Here is the link of your duplicate thread.

    Duplicate Thread: http://social.msdn.microsoft.com/Forums/en-US/sharepointadmin/thread/8be31250-c689-4701-832f-2ea285edea6c


    Cheers, Hemendra-MCTS "Yesterday is just a memory,Tomorrow we may never see"
    • Marked as answer by David HM Friday, May 13, 2011 10:32 AM
    Friday, May 6, 2011 8:28 AM
    Moderator

All replies

  • Hi,

    ID will not be available during Add operation because, It was not yet generated then, that is why on second try; you see it!

    I discovered that the [ID] column should not be used in a calculated column because it wreaks havoc and causes many errors. Sorry - remove the ID column and use some auto-number column or different strategy please.


    ------------------------------------ Happy Workaround :) Vivek
    Friday, May 6, 2011 7:48 AM
  • Hi,

    I need the sequence as

    Date-number

    for example 06-05-2011 - 1

                      06-05-2011 - 2

    Can anyone derive me the formula in sharepoint list

     

     

     


    Friday, May 6, 2011 8:23 AM
  • Hi,

    I agreed with vivek, you should create one more column in your list with auto generated number. Then use this column instead of ID.

    OR else,

    You can create custom event handler (Events: ItemAdded and ItemUpdated), which will concatenate both the columns (Created and ID) value and save in custom column. Here you can use the item ID in your custom event handler.

    Off Topic:

    Here is the link of your duplicate thread.

    Duplicate Thread: http://social.msdn.microsoft.com/Forums/en-US/sharepointadmin/thread/8be31250-c689-4701-832f-2ea285edea6c


    Cheers, Hemendra-MCTS "Yesterday is just a memory,Tomorrow we may never see"
    • Marked as answer by David HM Friday, May 13, 2011 10:32 AM
    Friday, May 6, 2011 8:28 AM
    Moderator
  • Re:

    Off Topic:

    Here is the link of your duplicate thread.

    Duplicate Thread: http://social.msdn.microsoft.com/Forums/en-US/sharepointadmin/thread/8be31250-c689-4701-832f-2ea285edea6c

     


     

    Moderator Note to OP:

    NEVER post duplicate threads in different forums. Always wait for replies to the original post - do not re-post.

    In this case the original post was move to the Admin forum because this is NOT a programming question but a question about a standard function (Calculated column). As such this thread belongs in the Admin forum and that is where I am moving this copy to (you have a couple of hours ago deleted the copy there).


    SP 2010 "FAQ" (mainly useful links): http://wssv4faq.mindsharp.com/default.aspx
    WSS3/MOSS FAQ (FAQ and Links) http://wssv3faq.mindsharp.com/default.aspx
    Both also have links to extensive book lists and to (free) on-line chapters
    Friday, May 6, 2011 10:42 AM