Showing posts with label SharePoint. Show all posts
Showing posts with label SharePoint. Show all posts

12 May, 2013

Deletion of Subsite, Site Collection, Document Library, SharePoint List- SharePoint 2010

Most commonly used entities in SharePoint are Subsite, site collection, list and libraries. 

GUI mode will be the easiest mode to do any functional activities associated with them. In this article, i am more concentrating on the PowerShell mode because its very easy and efficient way to clean the activity directly from the database. 

Let's try to explore some deletion functionalities by means of PowerShell.

How to delete a site collection by using PowerShell?
Remove-SPSite [-Identity] <SPSitePipeBind> [-AssignmentCollection <SPAssignmentCollection>] [-Confirm [<SwitchParameter>]] [-DeleteADAccounts <SwitchParameter>] [-GradualDelete <SwitchParameter>] [-WhatIf [<SwitchParameter>]]

Example: Remove-SPSite -Identity http://SharePoint2010/sites/test2010

Where:
SharePoint2010: web application URL.
Sites: wildcard entry.
test2010: site collection that you want to delete.

Note: The above will completely deletes an existing site collection and all subsites. This operation cannot be undone.

How to delete a Subsite by using PowerShell?
Remove-SPWeb [-Identity] <SPWebPipeBind> [-AssignmentCollection <SPAssignmentCollection>] [-Confirm [<SwitchParameter>]] [-Recycle <SwitchParameter>] [-WhatIf [<SwitchParameter>]]

Example: Remove-SPWeb -Identity http://SharePoint2010/sites/test2010/subtest2010

Where:
SharePoint2010: web application URL.
Sites: wildcard entry.
test2010: site collection
subtest2010: Subsite that you want to delete.

If you want to delete multiple subsites in a single shot from a site collection then please refer the following site: http://get-spscripts.com/2010/10/delete-sharepoint-sub-sites-using.html

How to delete a Document Library by using PowerShell?
Please refer the following code by which you can delete a document library without any issues...

$web = Get-SPWeb urlofweb
$library = $web.lists["listname"]
$library.Delete()

How to delete a SharePoint List by using PowerShell?
Get-SPWeb “site collection link” | % {$_.Lists.Delete([System.Guid]$_.Lists["name of list"].ID)}

The above command will delete the mentioned list without any issues...

If you have any queries/questions regarding the above mentioned information then please let me know, Thank you. I would be more than happy to help you as well as resolves your issues...

03 May, 2013

Content databases contain orphaned items

Problem Description:
The SharePoint Health Analyzer detected an error.  Content databases contain orphaned items.

In some situations, a content database that is used by Microsoft SharePoint Foundation may become corrupted. The corrupted database may contain orphaned items. For example, a document may not have a parent document library or a list may not have a parent Microsoft SharePoint Foundation Web site.  Consequently, you may be unable to create new items with the same URL as the orphaned items, and space in the content database will be consumed unnecessarily.

Error Message:
Content databases contain orphaned items

Resolution:
Perfect article provided by Microsoft on this which helps me to resolve this issue:
http://technet.microsoft.com/en-in/library/ff805076(v=office.14).aspx

Product Applies To:
SharePoint Server 2010.
SharePoint Foundation 2010.

Redirect a SharePoint site by using the Content Editor Web Part - SP2010

Today one user came up with the requirements that he wanted to redirect his current site to different site collection. This seems to a normal requirement for everybody and can arise at any time.

I have resolved that issue with the use of metatag and thought to share with all of you as how I resolved it.

Please refer the following the following line of code that you need to use it for the redirection purpose.

<meta http-equiv="refresh" content="2;URL=http://sharepoint2007/sites/contentmodification">




Where you need to use it?
-Open the site where you need to set up the redirection
-site actions
-edit page
-add the content editor WebPart
-Give the reference of this file.

You must be wondering what is meant by reference?
-Created any document library or use the existing one
-Copy the redirection script/line in a notepad
-Upload this notepad in a document library
-click on the notepad direct and copy the link from the browser.
-Go back to the site where you have added the content editor WebPart
-Enter the link inside the WebPart which will take the reference of that notepad.

That’s it. You are done with redirection.

If you have any queries/questions based on the same then please let me know, Thank you.

27 April, 2013

Microsoft SharePoint Designer 2010 Download

SharePoint Designer 2010 is the tool of choice for the rapid development of SharePoint applications. Using SharePoint Designer, advanced users and developers alike can rapidly create SharePoint solutions in response to business needs. Advanced users can compose no-code solutions that encompass a variety of common scenarios, from collaborative sites and web publishing to Line-Of-Business data integration, business intelligence solutions, and human workflows, leveraging the building blocks available in SharePoint in an easy to use environment. In addition, developers can use SharePoint Designer 2010 to get a quick start on SharePoint development projects.​

This is the 32-bit edition of SharePoint Designer 2010. It is the recommended configuration for most users

http://www.microsoft.com/en-in/download/details.aspx?id=16573


This download is the 64-bit edition of SharePoint Designer 2010. The 32-bit edition is suggested for most users

http://www.microsoft.com/en-in/download/details.aspx?id=24309

24 April, 2013

SharePoint 2010 - Browser Compatibility

This article explains known limitations of some browsers with SharePoint 2010.

For most interactions with SharePoint an internet browser is required and the choice of browser will affect the experience. Most functionality is available in all browsers, however there are exceptions where certain features require Active X technology which is only available in Internet Explorer and means that some of SharePoint's functionality is lost when using non-IE browsers.

Browser support for SharePoint Server 2010 can be divided into three different levels, as follows:
  • Supported - A supported Web browser is a Web browser that is supported to work with SharePoint Server 2010, and all features and functionality work.
  • Supported with known limitations - These are non-Internet Explorer browsers such as FireFox, Safari and Chrome. They are supported for use with SharePoint but some functionality is missing in these browsers such as opening documents directly in Office applications (although viewing and editing office documents within the browser is fully supported, as is downloading and editing). Documentation on how to resolve these issues is readily available from Microsoft.
  • Not tested - A Web browser that is not tested means that its compatibility with SharePoint Server 2010 is untested, and there may be issues with using the particular Web browser. SharePoint Server 2010 works best with up-to-date, standards-based Web browsers.



Thanks Brent for sharing this

URL path length restrictions in SharePoint 2010

There must always be a series of questions –

Is there any solution for URL maximum length restriction?

I am unable to create consecutive subfolders due to URL length exceeding 260 characters
Is there any proper fix to solve this issue?

Can I increase maximum allowed URL length that SharePoint can work with?

How exactly does that affect opening a nested-folder-document in say Word or Excel?

Is the limit also there for the explorer view? 255 chars isn't a whole lot for a directory and filename structure, so if it also affects the explorer view; is there a way around it?

Reason is pretty much simple: SharePoint limits URL length because all relative URL links are stored in the clear forms on the SharePoint content DB and often this links are used as primary keys to link one table with another. Fields which are used to store these links (for instance tp_DirName from the AllUserData table) allow storing only 256 characters.


If you have any questions/queries regarding the mentioned information then please let me know, Thank you.

18 April, 2013

Online interview SharePoint professional – 4 pragmatic questions I asked

Finding and getting right people to work for your company isn’t as easy as you think even you find many awesome things in resumes. To SharePoint field, the difficulty of recruitment becomes more true because of complexity of SharePoint platform and different uses of it. Have you ever been responsible for interviewing SharePoint professional working for your company? Which questions would you like to ask your candidates?

Recently, I’ve been assigned to be part of recruiting team in my company, responsible for online interviewing some candidates whose good-looking resumes on my table. I, although, did quick search on Google using keyword “SharePoint Job interview questions” but I never used any of them to ask the candidates. I didn’t ask something like “What is the X method?” or “Is there any difference between X and Y?” or “How does execution of X code impact on Y environment?” because I did know someone could readily put his fingers on the Google search box and then quickly found good results. So what did I ask when doing an online interview? In this post, I would like to share only 4 pragmatic questions I asked for SharePoint Solution Director candidates.

Can you tell me about two most favorite projects you have worked on?

A brilliant candidate should get started with brief introduction, his role and responsibilities, project size and duration. Through his answer, you probably know he has hands-on experience, especially his passion on those projects. Candidates can’t find the answer to my question on Google or another search engine.

Let’s see a sample answer: “One of the most favorite projects done was to build a logistic management application built on top of SharePoint platform. I worked as Lead Architect, responsible for planning and designing architecture covering infrastructure, capacity, storage, security and development. We had 6 team members working within 4 months to complete the project.”
After getting such a clear answer, you can possibly have a few extra questions such as:
  • Can you concisely describe features of the logistic management you completed developing? Using this question, you can figure out how complex this project is.
  • How many roles in this project? Which was the most important role you think? I know this question should be focused for SharePoint project manager but if he actually has good mindset, he should probably get to overall picture of the project.
  • Can you describe a little bit of the environment? You may get an overview of SharePoint farm maybe with a staging farm. It looks really cool, isn’t it?
Which challenges/issues did you get in the two projects?

A real experienced SharePoint professional has to note challenges and issues or at least remember during his project. The reason I ask is to know how he solves problem if occurred, and more details in solution architecture and probably soft-skill he has. Sometimes you expect to see soft-skill a candidate has rather than technical skill used to solve complexity of SharePoint project. That said, when asking an Indian candidate, I was expecting to get more of X management challenge such as risk management, change management or so on. However, he mostly focused on answering code stuffs, e.g, “They didn’t have the latest code available for the custom code solutions deployed in SharePoint 2007”, or “We had to update the existing code and then build it on x64 platform before upgrading to SharePoint 2010.” At this point, you can see this guy can fit developer role rather.
I know code related issue is one of the most common challenges in SharePoint project but I need to know if there is something else that keeps me asking in more details because of my curiousness.

Let’s see a sample answer: “Although we used Microsoft Solution Framework to manage SharePoint project, we still had problem with customer requirement that were changes of functionality. We had to deal with that, and built a SharePoint site collection used to track changes and manage the problem. Another issue was that we didn’t have a Team Foundation Server professional so our collaboration process got some times delayed.“

The Indian guy I interviewed worked with a customer that had SAP system and they wanted to pull data from it to push to SharePoint. He had to write a custom web service. I know he is really good at customization but what I was expecting to see from his answer should be like: “The customer had SAP system and they wanted to pull data from it and then push to SharePoint. We knew that Duet enterprise was an epic but the customer didn’t have enough budget so we had to customize web service to meet the business requirement and fit the budget.” Duet Enterprise was my focused point that would denote his breadth knowledge.

What are different/same things between any two projects you have done?

I don’t need candidates to elaborate differences, or list all different/same things. What I expect is to see if candidates have good brain to remember what they have done, and how they response in systematic way, and their brain be organized logically.

Let’s see a sample answer:  “We had two SharePoint document management projects (A and B) but A had document processing workflow but B didn’t. Conversely, B required digital signature issued by a PKI (Public-key Infrastructure) but A didn’t. One of the same things were the functionality of search based managed metadata.”

What do you think about the concept of SharePoint Out-of-the-box (OOTB)?

There are many .NET geeks turned SharePoint developers often do many customization on SharePoint-based application because they think they can do everything on such a platform built .NET framework. I really expect to see how much candidates are familiar with SharePoint OOTB in order to reduce effort of customization. There are many business solutions that can be done very quickly by using OOTB but folks often go with really hard ways. Workflow that has multiple approval processes is an example. Building dashboard by Dashboard Designer and PerformancePoint without writing code is another one. I’m not talking about complex dashboard. By the way, I strongly recommend reading “Microsoft SharePoint 2010 – Creating and Implementing Real-World Projects” book and “Professional Workflow in SharePoint 2010 Real World Business Workflow Solutions” and “Beginning SharePoint 2010: Building Business Solutions with SharePoint“. The books cover real-world no-code business solutions.

When having a blueprint in your hand, take a glance at SharePoint OOTB to see if it can meet business needs without code, or write a little code putting in Content Query web part to trigger something, for example.  At this point, you can supposedly bring out a scenario, e.g., ABC is the marketing company that helps customer in promotion of products and services by organizing conference. Each conference has its own a set of documents that likely consists of marketing plan, budget plan, program plan and other documents related to the conference. ABC is using SharePoint and wonder if it can help manage such a set effectively. As an experienced SharePoint professional, what would you like to suggest them? I’m guessing many of you immediately propose Document Set feature that actually addresses to the concern. Ironically, you might forget asking which SharePoint version the marketing company is using, right?

Conclusion

In my opinion, these questions do qualify someone who indeed has much experience on SharePoint platform and he has done many real-world SharePoint projects whether those are big or not. These questions are connected logically so if you don’t really have much SharePoint experience, you could get stuck at any of the questions. Besides, candidates can’t find good answers from Google or even they refer to friends of theirs.
When you do an online interview, try to avoid your candidates doing search by asking intelligent questions. You shouldn’t ask kind of “How-To” question or technique focused. Having good technical skills is really good these days but it’s not enough for working in the harsh world.

Thuan Nguyen - SharePoint MVP

17 April, 2013

Migrate managed metadata from one environment to another in SharePoint 2010

What will be the requirement?
Your user will be raising a ticket for to create a replica of the production site in development environment.

Quite easy - correct? You can easily implement this by using PowerShell but now the problem starts from here. If your site collection admin has created a term store in production site then you will not get those in development environment. Hmm- seems to be difficult now, isn’t it?

Reason: Managed metadata terms and term sets each have a unique guid and the guids don't match up

Nothing to worry about as we have a solution for that :)

Let me brief some details as local terms can be created by 2 ways:
-centrally i.e. @Central Administration Level
-Locally i.e. @site collection level

Let me talk about ‘Centrally’ first: There are some ways by which you can implement this.
-By using Export and Import
-By using Database method

Let’s discuss about the first method i.e. Export and Import

Export Example:
$mmsAppId= "e1c96163-7767-4497-8e92-51eb154f0c70"
$mmsproxy = Get-SPServiceApplicationProxy -Identity "4d4b3094-a9ad-4cee-99f4-392d489a1657"
Export-SPMetadataWebServicePartitionData -Identity $mmsAppId -ServiceProxy $mmsproxy -Path "E:\backups\SP2010_Backups\mms.bak"
You must be wondering as how to get this App ID Guid Placeholder and Proxy ID Guid Placeholder. It’s very easy-please refer the following steps:
How to get App ID Guid:
-Central Administration
-Application Management
-Manage Service Applications
-Managed Metadata Service Application
-refer the browser now and copy the guid which is after tsid=

How to get Proxy ID Guid:
-Open the PowerShell console
-execute this command-  Get-SPServiceApplicationProxy
-You will see a list of proxy id’s and you need to copy ID that belongs to managed metadata.

Follow the same process in Import also and get the guids. Obviously they will be different as they belongs to different farm i.e. target farm.
Import Example:
$mmsAppId= "d7b7b20c-aed1-4cag-ba6a-45baa9d6adf2"
$mmsproxy = Get-SPServiceApplicationProxy -Identity "df8606f1-cfca-4283-89db-9270e0a5adec"
Import-SPMetadataWebServicePartitionData -Identity $mmsAppId -ServiceProxy $mmsproxy -Path "\\SP2010_SQL\SP2010\mms.bak" –OverwriteExisting
Database approach:
-Backup the managed metadata database in your source farm
-Delete the MMS service in your target farm
-Restore the managed metadata database to your target farm
-Create a new MMS service in your target farm
-Ensure correct service accounts have full control of MMS

How to move local term stores?
We can easily move the local term stores by using the following tool:
Documentation is already provided on the above site only so I will not go much deeper in reference to this tool but it’s very easy and user friendly too.
If you have any queries/questions regarding the above mentioned information then please let me know, thank you.

Error in creating a SharePoint Wiki site in SharePoint 2010

Problem Description: Error in creating a SharePoint Wiki site in SharePoint 2010

Creating a subsite underneath site collection by using ‘enterprisewiki’ throws an exceptions.

Please refer the following exceptions which is a series of error messages and helpful to understand the cause behind it.

Error Messages:
Error#1: Failed to activate site-scoped features for template 'ENTERWIKI#0' in site ‘http://sharepoint2007/sites/SP2010Projects’.    a41b91e6-385b-42a9-a10f-c69e15de613a

Error#2: Failed to activate web features when provisioning site at url " http://sharepoint2007/sites/SP2010Projects" with site definition "ENTERWIKI#0"
               
Error#3: Failed to apply template "ENTERWIKI#0" to web at URL " http://sharepoint2007/sites/SP2010Projects".  a41b91e6-385b-42a9-a10f-c69e15de613a

Error#4: SPContentTypeBindingElement.ElementActivated(). ContentType '0x010100C568DB52D9D0A14D9B2FDCC96666E9F2007948130EC3DB064584E219954237AF39004C1F8B46085B4D22B1CDC3DE08CFFB9C' not found on web ' http://sharepoint2007/sites/SP2010Projects'.              a41b91e6-385b-42a9-a10f-c69e15de613a

Error#5: specified argument was out of the range of valid values. Parameter name:content type not found(‘0x010100C568DB52D9D0A14D9B2FDCC96666E9F2007948130EC3DB064584E219954237AF39004C1F8B46085B4D22B1CDC3DE08CFFB9C’).

Analysis:
Wiki template is a dependency section of Publishing Infrastructure as per the following articles:


Resolution:
Activate publishing infrastructure at the site collection level as well as at the site level.

How to do this:
Activate Publishing Infrastructure @site collection level:   
-Open the site
-site actions
-Site settings
-site collection Administration
-activate “SharePoint Server Publishing Infrastructure”

Activate Publishing Infrastructure @site level:   
-Open the site
-site actions
-Site settings
-site actions
-manage site features
-activate “SharePoint Server Publishing Infrastructure”

That’s it; your issue will be resolved.

If you have any queries regarding the above mentioned information then please let me know.

I would be more than happy to help you as well as resolves your issues, Thank you.

Product Applies To:
SharePoint Server 2010
SharePoint Foundation 2010

16 April, 2013

The Managed Metadata Service or Connection is currently not available. The Application Pool or Managed Metadata Web Service may not have been started. Please Contact your Administrator

We have created a new UAT environment for the deployment purposes and everything is new. Suddenly the requirement comes up for managed metadata. As this environment is newly built so we have not created all the service applications and work/create as per the requirement arises.

Note:
If you find a different solution, please report it as a comment to this post. Be sure to double-verify it: undo your solution and verify that the problem comes back, then redo it and verify that the problem goes away.

Problem Description:
Creation of new service application named as ‘managed metadata’

I have created a new service application by providing the following data:
1.   Name of the service application Example. Managedmetedata_DEVSP
2.   Name of the application pool
3.   Selecting the appropriate service account from the dropdown which has sufficient privileges to create the SA.
4.   Click OK

Now the service application is created without any issues.

As soon as I clicked on it then I got the following ERROR MESSAGE:
The Managed Metadata Service or Connection is currently not available. The Application Pool or Managed Metadata Web Service may not have been started. Please Contact your Administrator.

Resolution:
Make sure the managed metadata service is already started.
How to check this:
a)   Central Administration
b)   Manage services on server
c)   Managed metadata service
d)   Start

Once the service is in started mode then check the results again by clicking on the managed metadata service application, it has to open the page without any errors\exceptions.

If you face the same error message as mentioned above then please execute IISRESET once and that’s it.

If you have any queries/questions regarding the above mentioned information then please let me know, Thank you.

15 April, 2013

Your backup is from a different version of Microsoft SharePoint Foundation and cannot be restored to a server running the current version

Problem Description:
Requirement comes up to transfer the backup of one site collection from production to development environment.

-          Took the backup of the site collection by using PowerShell command without any issues
-          As soon as I tried restoring the backup then I faced the following error message

Error Message:
Your backup is from a different version of Microsoft SharePoint Foundation and cannot be restored to a server running the current version. The backup file should be restored to a server with version '14.0.0.6134' or later.

Checkpoints:
-Compare the development SP version with the production version and found out the following info:
Development- 14.0.6123.5006
Production- 14.0.6120.5006

-it’s quite obvious from the above versions that it’s not going to work L and we should be ready to hear the answer “It seems that you need to update your development server with the same patch which is running in production and then you can restore the backup” / upgrade your destination farm to the same version of the source farm, After your farms are at the same product version, the restore will succeed.

Resolution:
You must be wondering as How exactly I have achieved this resolution?

Here are the details:
-Restored Production backup to staging application but in a separate database

-Took that database and restored to development environment – which automatically place that DB to the same version

-Attached the database to default application, that’s it- issue resolved J

Site is up and running, easily restored to the development environment without any waiting time.

If you have any queries/questions regarding the above mentioned information then please let me know, thank you.