Resource Department is showing wrong in SharePoint 2010

Hello All,
I have one Application which is In-house application (created by our developers) and this is running and hosted on SharePoint 2010. My concern is this I have one user in my application and her Department and Title is showing wrong in site collection. I have
deleted the user from site collection (UIL) and then try to add her name again but still her information is showing wrong. I have checked in Active Directory and all the information is correct there.
Please help me to resolve this issue. Any help will be greatly appreciated.
Many Thanks

Thanks Devendra for your suggestion, but not that much good in codes. Can you please tell me what should I change in the below code to update the fields.
function Sync-SPUser([string]$userName, [string]$title) {
Get-SPSite -Limit All | foreach {
$web = $_.RootWeb
if ($_.WebApplication.UseClaimsAuthentication) {
$claim = New-SPClaimsPrincipal $userName -IdentityType WindowsSamAccountName
$user = $web | Get-SPUser -Identity $claim -ErrorAction SilentlyContinue
} else {
$user = $web | Get-SPUser -Identity $userName -ErrorAction SilentlyContinue
if ($user -ne $null) {
$web | Set-SPUser -Identity $user -SyncFromAD
$list = $web.Lists["User Information List"]
$query = New-Object Microsoft.SharePoint.SPQuery
$query.Query = "<Where><Eq><FieldRef Name='Name' /><Value Type='Text'>$userName</Value></Eq></Where>"
foreach ($item in $list.GetItems($query)) {
$item["JobTitle"] = $title
$item.SystemUpdate()
$web.Dispose()
$_.Dispose()
Appreciate your response on this.

Similar Messages

  • Problems with Sharepoint 2010 view if group by and collapsed is activated - all items show up within each group!

    Hi there,
    we have a Sharepoint 2010 Enterprise environment where we use some lists for new feature ideas.
    These lists should be grouped by a certain coloums. If we keep the default view with expanded groups, only the items which should be inside a certain group will be displayed (the count is for example 7 and inside the group there are only 7 items).
    As there are a lot of groups inside the list we would like to create a new standard view with all groups collapsed. But as soon as we change the view, all groups contain ALL items from the list (what makes it really strange is that the count is still 7 but
    a couple of hundred items are inside the group even the ones which should have been filtered by the "group by" settings.
    I enclosed two pictures where you can see the difference between "collapsed" and "expanded" view (Group by settings!)
    Is this a bug or is there something wrong with our views/installation?
    Thanks for any help (by the way: i just installed the CU from April 2012 which didn't make any difference!)
    Greetings
    Jens
    "Collapsed View":
    "Expanded View":

    Hi ,
    I  understand that when you create a new standard view with group by BDE ,and all items show up when collapse is activated .I cannot reproduce your issue .This is not a bug .You should try to edit the view in browser multiple times to have a test whether
    it is showing correctly now .If this view is still not working ,you can try the workaround below :
    Open the Site in SharePoint Designer .
    Open the list and create a new view .Make the view as the default view .
    Edit the view in Advanced Mode . Click in the xsltlistview web part and Click Sort&Group in the ribbon .
    You can add Group by here .After making all the changes ,save and preview the view in browser .
    Thanks
    Entan Ming
    TechNet Community Support

  • SharePoint 2010 Present Wrong Timezone for External List of External Content Type

    External content is hosted on an independent SQL server DB from the SharePoint server. External content lists shows datetime fields 5 hours earlier as opposed to Eastern standard time but Web parts display data correctly.
    Yes, timezones on both servers are correct. Timezones settings in SharePoint have been checked and all appear correct. There are several places for settings. Is there a checklist in case something was missed. Our SharePoint administrator has
    looked for the cause and cannot determine.
    I poured through other blogs and issues with external content and timezone on this site including "External Content Type Saving Dates in UTC".
    Please provide a list for timezone settings such as global settings for a site, collection, external content, SharePoint 2010 designer settings, Central Administration settings, etc.

    Hi Benjamin,
    Please test the following approach for your issue, exporting the BDC Metadata Model from SharePoint Designer and change the normalization to use local time, and let us know the results.
    http://sharepoint.stackexchange.com/questions/91516/timestamp-in-sharepoint-external-content-type-not-matching-value-in-sql-table
    http://www.shillier.com/archive/2010/09/01/why-are-my-date-fields-wrong-in-business-connectivity-servces.aspx
    https://calshare.berkeley.edu/Blog/Lists/Posts/Post.aspx?ID=9
    Thanks
    Daniel Yang
    TechNet Community Support

  • SharePoint 2010 Web Analytics showing user Display Name and Account Name from the same user

    Hi!
    Since July, 16th 2012 the Web Analytics Daily Unique Visitors reports started to show almost the double of visitors we used to have on our Web Application. Here are some of the data (I intentionally deleted the weekend data):
    10/7/2012 2.497
    11/7/2012 2.723
    12/7/2012 2.722
    13/7/2012 2.699
    16/7/2012 5.055
    17/7/2012 4.963
    18/7/2012 4.954
    19/7/2012 4.998
    20/7/2012 4.965
    23/7/2012 5.117
    24/7/2012 5.012
    25/7/2012 5.071
    As you may notice the data jumped from around 2.700 unique visitors to around 5.000 unique visitors. As the number of permissioned users remains constant it is pretty odd. I also checked the Number of Page Views report and see no change on its behavior.
    The number of page views remained constant.
    So I went to look the Top Visitors report and understand why the visitors number almost doubled. The analytics started to count the users Display Name and Account name as two different visitors with a different number of page views. Let me show you an example
    from yesterday (July, 25th) Top Visitors report:
    #     Visitor                  Page Views    %
    1    Cinthia XXXXXXXXXX    359        0,55%
    5    Giselle XXXXXXXXXX     143        0,22%
    7    Aline XXXXXXXXXX       138        0,21%
    15  nt\cmazevedo              111        0,17%
    60  nt\gbsantana                 69        0,11%
    73  nt\aglsiqueira                 65        0,10%
    "Cinthia" and the account "nt\cmazevedo" are the same person. The same is applied to "Giselle" / "nt\gbsantana" and "Aline" / "nt\aglsiqueira".
    As I stated this is an example from July, 25th. If I checked the same report from a period before July, 16th I can only see the users Display Name as "Visitors". No account name is displayed or counted as a different visitor.
    About the environment:
    We have two SharePoint 2010 farms: a "corporate" and a "enterprise". The corporate farm contains four web servers and a central administration servers with publishing services. The enterprise farm contains two servers running User Profile Services, Search
    Services and some others. Our main version is the SP1 with June/2011 Cumulative Update with a few more hotfixes applied.
    This behavior on analytics is affecting all web applications (we have more than 20) installed on this farm and my company Support team said that no change were made on SharePoint on the weekend the problem started.
    Does anyone have any tip about what is going on?
    Thanks in advance!

    Hi, Manas!
    First of all thanks for your interest on this issue but I don't think it is related to the User Profile or the Active Directory.
    I checked both records and there was no change on the Display Names. All the users have "full names" as display names (first + middle + last name) and not logins as SharePoint is displaying on this report.
    But I did a test yesterday and checked the results today confirming that just the access been made using a specific server are causing this. Explaining it better:
    I have four web servers on my farm named from P01 to P04. Then I created this test script:
    Step 1: Change local HOSTS file to point the web application on the server P01.
    Step 2: Access site "A"
    Step 3: Access site "B"
    Step 4: Close the browser.
    Step 1: Change local HOSTS file to point the web application on the server P02.
    Step 2: Access site "C"
    Step 3: Access site "D"
    Step 4: Close the browser.
    Step 1: Change local HOSTS file to point the web application on the server P03.
    Step 2: Access site "E"
    Step 3: Access site "F"
    Step 4: Close the browser.
    Step 1: Change local HOSTS file to point the web application on the server P04.
    Step 2: Access site "G"
    Step 3: Access site "H"
    Step 4: Close the browser.
    I asked three users to execute that script. The results: All access to the sites "C" and "D" were registered on Web Analytics with the user account name such as "nt\cmazevedo". All the other sites registered the user Display Name correctly such as "Cinthia
    XXXXXXXXXX".
    With this test we could isolate the problem just on the server P02. It doesn't occur on the others. Now my support team is trying to find any configuration difference between this server and the other three that could point for the root cause.
    I am also looking for some information regarding the service responsible for this task ("transform the account name into a display name") to understand why it doesn't work on one server and works on the others.
    Thanks!

  • SharePoint 2010 Site Web Analytics - Top Pages report not showing complete data

    Hi,
    I have a custom page in a team site which takes list ID as an argument and shows the relevant data e.g.
    ../Dashboards/View%20Briefing.aspx?BriefingID=1078
    ../Dashboards/View%20Briefing.aspx?BriefingID=1079 etc
    When i look at the Top Pages report under Site Web Analytics all i can see is data for:
    /dashboards/view briefing.aspx
    I need stats for individual list items i.e. how many time BreifingID 1078 was viewed etc. Is it possible to achieve this using OOTB reports or can i write a custom report to achieve this? If yes then how...
    Any help would be appreciated.
    Regards,
    Kashif

    You’re dynamically filtering content on a single page with values on the query string. Your users are still only hitting one page (View%20Briefing.aspx). Analytics only sees that 'View%20Briefing.aspx' is being hit; it won’t record stats for what’s specified
    on the query string.
    I expect you could pull this data out of your IIS logs using log parser. Some links on this subject:
    http://www.toddklindt.com/blog/Lists/Posts/Post.aspx?ID=85
    http://blogs.technet.com/b/corybu/archive/2008/02/26/sharepoint-iis-traffic-analysis.aspx
    http://social.technet.microsoft.com/wiki/contents/articles/16072.sharepoint-2010-create-analytic-reports-using-logparser-and-powershell.aspx
    http://blogs.msdn.com/b/carlosag/archive/2010/03/25/analyze-your-iis-log-files-favorite-log-parser-queries.aspx
    http://logparserplus.com/Examples

  • SharePoint 2010 and PowerPoint 2010: Open PPTX File in Edit Mode and Open PPSX in in Slide Show Mode

    I have the following issue while opening PowerPoint PPTX file and PPSX from the Document ID link provided by SharePoint 2010.
    Issue
    Initially when I opened PPTX file from the DOC ID link from SharePoint 2010, it is opening up in Slide Show mode which is not how we want it to be.
    For PPSX, it is opening in Slide Show mode which is what we wanted.
    Thus, I did some research online and found this article at support.microsoft.com/kb/q299824  which requires some modification to the Registry of the client machine.
    I did the change as follows
    Open Registry
    Look for “Computer\HKEY_CLASSES_ROOT\PowerPoint.Show.12”
    Set BrowserFlags value to a
    After the change, PPTX is opening in Edit Mode in PowerPoint which is correct but PPSX is also opening in Edit Mode in PowerPoint which is not correct
    This issue only occurs if I open the document from the Doc ID link in SharePoint. If the documents are downloaded, it will not have this issue.
    Questions
    Can I set PPTX to open in Edit Mode and PPSX to open in Browser Mode?
    Is this fixed as in if I change the registry setting it will affect both file types?
    Is there other ways I can achieve opening PPTX in Edit and PPSX in Browser Mode?
    [Environment]
    My Client machine is running on I.E 9 and Office 2010.
    Thank you.

    Hi,
    To make the PPTX file open in Edit mode and PPSX file open in Slide Show mode, I recommend to edit the registry key HKEY_CLASSES_ROOT\PowerPoint.Show.12 to 8.
    I tested the scenario in my environment with changing the key value to 8, after that PPTX file opened in Edit mode and PPSX file opened in Slide Show mode.
    Best regards.
    Thanks
    Victoria Xia
    TechNet Community Support

  • Workflow menu option not showing up in edit form or the ribbon in SharePoint 2010 list

    In a SharePoint 2010 list I created a workflow (in SPD)  and published, but in the Edit Item form, there is no Workflow option. In the ribbon, the "Workflow" button is greyed out.
    But I see this option in other lists.  Where is the setting I can get this workflow option show up in menu?
    Thanks in advance

    Hi,
    Glad to hear your issue solved and thanks for your posting!
    Best Regards,
    Eric
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • Lync 2013 - Presence not showing in SharePoint 2010

    Hello,
    Presence was showing while on Lync 2010 and Office 2010 but at some point we lost the jellybean presence.
    We recently upgraded to Lync 2013 and O365. Yet our SharePoint 2010 libraries are no longer showing the presence next to Modifiied By or Created By.
    I've checked CA and presence is enabled. AcriveX add-in ia as well.
    Thank you,
    Andrea

    Hi,
    Did the Lync Server 2013 install On-Premises or online?
    If it is On-Premises deployment, Presence is displayed by using an ActiveX® control and Lync APIs.
    Please check if the Office to be the Latest version, if not, update it and test again.
    If it is Lync online, you can also post a question on Office365 forum for assistance. Thank you for your understanding.
    http://community.office365.com/en-us/forums/163/categories.aspx
    Best Regards,
    Eason Huang
    Eason Huang
    TechNet Community Support

  • Language pack resource files in SharePoint 2010 and 2013

    Hi,
    We are translating the Language pack for SharePoint 2013 in Albanian language.
    Comparing to SharePoint 2010 resource files, there are less of them in SharePoint 2013 but they are bigger in size. Are they merged and in that case which of them are merged? Any other info relating to this issue would help
    me a lot.
    Thanks,

    Hi,
    Although the 2010 and 2013 are different versions, most of the files contain the same words. I just thought that maybe someone knows if and if yes, which of the files are joined together in 2013 since there are less files in 2013 but bigger in size. All
    this because that Albanian LP doesn't exist and we have to translate another LP. 
    If someone has had experience in translating Language Packs in SharePoint 2010 or 2013, any information would help me a lot.
    Thank you

  • Installed Sharepoint 2010 Server SP2 Update; PSConfig succeeds but CA still shows "Upgrade Available"

    I have installed SharePoint 2010 Server SP2.  Central Administration shows the configuration database is at 14.0.7015.1000.  I had to run PSConfig several times before it completed successfully due to missing features, setup files, etc.  But
    I got those cleaned up and finally got PSConfig to complete.
    However, when I go to Farm Information it still shows "Upgrade Available" for the single WFE server we have. 
    When I run stsadm.exe -o localupgradestatus it shows me the following:
    [2] content database(s) encountered.
    [0] content database(s) still need upgrade or cannot be upgraded.
    [23] site collection(s) are contained in the content databases.
    [0] site collection(s) still need upgrade.
    [53] other objects encountered, [12] of them still need upgrade or cannot be upgraded.
    The 12 objects that cannot be upgraded are ancillary databases like:
    StateService_[GUID]
    Secure_Store_Service_DB_[GUID]
    PerformancePoint Service Application_[GUID]
    They all show "Cannot Upgrade" for the status.
    Am I correct in thinking these are what's keeping the status at Upgrade Available?  And if so how can I resolve?
    If not, what else can be done to change that Upgrade Available status?
    My goal is to get SP2 and the latest CU applied before trying to reinstall the User Profile Service.
    Thank you.

    use psconfig via command line:
    > PSCONFIG.EXE -cmd upgrade -inplace b2b -wait
    Scott Brickey
    MCTS, MCPD, MCITP
    www.sbrickey.com
    Strategic Data Systems - for all your SharePoint needs

  • AD Security Group name change not showing in Sharepoint 2010

    Hi!
    We have a Sharepoint 2010 Standard enviroment and are heading for a role-based identity-managment in our company. That's why we find it better to use AD Groups instead of Sharepoint Groups.
    So we have over 1000 AD Security Groups groups that have been added to our Sharepoint Sites and our goal is to control every permission in Sharepoint from AD.
    I have done all this with the combination of Excel and Powershell and it have worked great.
    The problem i see in the long run is the name change of AD Security Groups. Sharepoint 2010 isn't showing the new name of the group.
    Does anyone know of any workaround that can solve this problem. It's a bit of a disappointment that Microsoft haven't fixed this. The only information i think they should store in Sharepoint is the SID of the groups.
    I was thinking of designing a powershell script that runs every night and updates the display name of the groups that do not match the AD display name.
    Is there any other way?

    As far as I know, and I'm not sure where to go from here without testing on my own...and I'm not sure when I'll be able to do that.  Perhaps a configuration issue.
    Have you tried removing the incorrectly named group and adding in the correctly named one?
    Read through this related post: 
    http://social.msdn.microsoft.com/Forums/en-US/sharepoint2010general/thread/49dc833f-4127-45ac-bd21-98b04d3632ef
    Looks like that can help you.  Let us know how things go.
    Colorless Green Ideas Sleep Furiously http://www.sharepointnerd.com

  • One calendar view does not show up when configure calendar overlay in sharepoint 2010

    I created 5 views for a calendar and wanted to create a calendar overlay to show all 5 views.
    Events 1
    Events 2
    Events 3
    Events 4
    Other events
    but one view named "Other events" is not showing up when selecting view from "calendar" list.. (only the other 4 views are shown)
    I checked that the view is created correctly and listed in views section in list settings.
    Don't know why ?
    Appreciate any advice

    Hi,
    According to your post, my understanding is that one of your calendar view didn’t display when configured the calendar overlay.
    Was the “other events” view created by the Calendar View format?     
    You can only select the view created by the Calendar view format when you configure the calendar overlay.
    I had tested with five view as your description, they are all the calendar views, and all the views could display when I configured the calendar overlay as below.
    You can recreate a new view or a new calendar, then check whether it works.
    There is an article about creating Calendar Overlay, you can check with it.
    http://deannaschneider.wordpress.com/2011/09/28/calendar-overlay-a-simple-sharepoint-2010-ootb-master-calendar/
    Thanks & Regards,
    Jason
    Jason Guo
    TechNet Community Support

  • SharePoint 2010 Central Admin to add users from AD from specific Department

    Dear All,
    I am working on SharePoint Foundation 2010. I have to add users from specific department to a particular site collection.
    Please let me know if there is a way to import users from Active Directory based on the 'Department' filed in
    SPCA.
    Thanks.

    Is that okay if I share the PowerShell code? Do you have access to Active Directory and can you query information?
    Refer this Link
    Code
    # set site collection owner for all sites...
    # 1-2012
    Add-PSSnapin Microsoft.SharePoint.PowerShell
    # $AccountList is an array of Windows Identities in the format of $AccountList = @("DOMAIN\USERID" , "DOMAIN\USERID2")
    $accountList = @(Get-ADUser -Filter {(Department -like '*Ur Needs*')})
    #$AccountList = @("LAB\Jack", "Lab\tom", "Lab\dick", "lab\harry")
    #this gets an array of objects representing the sites at the IIS level:
    $IISSites = Get-SPWebApplication
    Foreach($oneIISSite in $IISSites)
    #using .Sites, we can get a list of the site collections
    foreach ($SharepointSiteCollection in $oneIISSite.Sites)
    write-host $SharepointSiteCollection.url -ForegroundColor Cyan
    $spweb = Get-SPWeb $SharepointSiteCollection.url
    #now we have the website, so lets look at each account in our array
    foreach ($Account in $AccountList.samaccountname)
    #lets see if the user already exists
    Write-host "Looking to see if User " $account " is a member on " $SharepointSiteCollection.url -foregroundcolor Blue
    $user = Get-SPUSER -identity $Account -web $SharepointSiteCollection.url -ErrorAction SilentlyContinue #This will throw an error if the user does not exist
    if ($user -eq $null)
    #if the user did NOT exist, then we will add them here.
    $SPWeb.ALLUsers.ADD($Account, "", "", "Added by AdminScript")
    $user = Get-SPUSER -identity $Account -web $SharepointSiteCollection.url
    Write-host "Added user $Account to URL $SPWeb.URL" -Foregroundcolor Magenta
    else
    Write-host "user $Account was already in URL " $SPWeb.URL -Foregroundcolor DarkGreen
    if ($user.IsSiteAdmin -ne $true)
    $user.IsSiteAdmin = $true
    $user.Update()
    Write-host "$account has been made an admin on $SPWeb.URL" -Foregroundcolor Magenta
    else
    Write-host "$account was already an admin on $SPWeb.URL" -Foregroundcolor DarkGreen
    $SharePointSiteCollection.Dispose()
    Note:
    First uncomment the second $accountlist add the user manually to test
    If you have AD module installed in your SP server you can use
    $accountList = @(Get-ADUser -Filter {(Department -like '*Ur Needs*')})
    Regards Chen V [MCTS SharePoint 2010]

  • Exchange Server 2010 public folder - Events show in SharePoint 2010 Calendar

    I want to fetch items to SharePoint 2010 Calendar from Exchange Server 2010 Public Folder Calendar called Event. How can I achieve this ?

    May be you can directly fetch whole public folder in sharepoint server
    http://www.amrein.com/apps/page.asp?Q=5778
    If this helped you resolve your issue, please mark it Answered

  • Sharepoint 2010 Reporting Feature not showing up under "Site Collection Feaure"

    Hi
    I want to enable "Audit Log" to do this I need "Reporting" feature to be enabled first, which can be located as below located as in below picture.
    But I am not able to see "Reporting" feature itself .Can anyone please explain how to add Reporting feature
    Thanks,
    Meenakshi 

    Hi
    Can you please confirm if you are using SharePoint Foundation or SharePoint Server Enterprise version ?
    As with SharePoint Foundation Audit Log is not available, you can check below links -
    https://auditlogsp.codeplex.com/ - This post says -
    "In Sharepoint 2010 we have a feature called Site Collection Audit and Audit log. But this feature only
    on Sharepoint Enterprise, but on the Foundation we dont have that feature. With this application, we can enable audit feature on SP Foundation, see all the log. "
    Also check same discussion here -
    http://sharepoint.stackexchange.com/questions/13399/how-do-we-activate-auditing-in-sharepoint-foundation-2010
    Hope it helps.
    Thanks,
    Danny
    Please remember to mark as answer if it helps.

Maybe you are looking for