locked
common data view task- filter : field equals [current user] is not working RRS feed

  • Question

  • I have added a data view in SharePoint Designer and I need it to be filtered, to display only the items that have a certain field equal to the current user. but it is displaying no item when using the filter.and my field looks like this: domain\user_name.

    ant ideas why this doesn't work or how should i make this work?

    thanks

    Friday, July 1, 2011 11:50 AM

Answers

  • Hi ,

     

    I have come up with a workaround .You can have a try .You can set the filter to Current user for other people’s use .As for yourself you can add a view on the data view .

    1.       Choose Paging under the Filter in the common Task view in SharePoint Designer .

    2.       Under  the General tab ,choose to show ‘SharePoint List Toolbar’ .Click Ok to save .

    3.       Open the page in browser and View on the top of the data view >Create view .Set this view as the default view .

    4.       In the Filter field you can set the show item when column is equal to your user name .

     

    In this way ,you have to change the view to see your items .And when other people login ,they can only see their stuffs .

     

    Thanks,


    Entan Ming
    • Marked as answer by ziara Wednesday, July 6, 2011 6:22 AM
    Tuesday, July 5, 2011 9:46 AM
    Moderator

All replies

  • What is the column type of your field?

    You usually can use  [Current User] for columns of the type "People or Group"
    Friday, July 1, 2011 4:12 PM
  • It is of the type "People and Groups". and if I type my username it works but when choosing [Current User] it displays nothing in my list.
    Monday, July 4, 2011 6:47 AM
  • Hi ,

     

    I  understand that your filter in the data view doesn’t work as your expectation .

    1.       What kind of user are you login ? Is it a system account ?

    2.       If it is a system account ,then it will no show as Domain\username after you login .So the filter vaule [current user] doesn’t match .But it will match when you type the value as the username .It is by design .

     

    If you have any more questions ,please feel free to ask .

     

    Thanks,


    Entan Ming
    Monday, July 4, 2011 7:37 AM
    Moderator
  • Hello,

    Yes it is a system account. But I need it to match different users not  just mine, so what could I do in this case?

    Thanks


    • Edited by ziara Monday, July 4, 2011 8:09 AM wrong
    Monday, July 4, 2011 7:54 AM
  • Hi ,

     

    I have come up with a workaround .You can have a try .You can set the filter to Current user for other people’s use .As for yourself you can add a view on the data view .

    1.       Choose Paging under the Filter in the common Task view in SharePoint Designer .

    2.       Under  the General tab ,choose to show ‘SharePoint List Toolbar’ .Click Ok to save .

    3.       Open the page in browser and View on the top of the data view >Create view .Set this view as the default view .

    4.       In the Filter field you can set the show item when column is equal to your user name .

     

    In this way ,you have to change the view to see your items .And when other people login ,they can only see their stuffs .

     

    Thanks,


    Entan Ming
    • Marked as answer by ziara Wednesday, July 6, 2011 6:22 AM
    Tuesday, July 5, 2011 9:46 AM
    Moderator