Thursday, January 27, 2011

SharePoint 2010 Enterprise Search

Although you can have the query component and the query processor on two separate machines, the "Did you mean?" functionality will not work since it only uses the local query component.

List of sites using Commerce Server 2007 or 2009

Here is a list of public sites using Commerce Server 2007 or 2009. As we do partner training, we have a section called "Notes from the field" where a partner presents some of their sites and the interesting facets of those projects. Let us know if you know of other sites and we will add them to the list.

http://www.20minutenmobile.ch/
http://www.360-5.com/
http://store.aigle.com/
http://www.amway.com/
http://www.apoteket.dk/
http://www.apoteket.se/
http://www.astleyclarke.com/
http://www.bd.dk/
http://www.bilka.dk/
http://www.bolia.com/
http://www.booksdirect.co.uk/
http://www.brandsource.com/
http://www.buylifetime.com/
http://www.bwt-filter.com/
http://www.bwt-group.com/
http://www.bygghemma.se/
http://www.camaieu.fr/
http://www.calphalon.com/
http://www.camaieu.fr/
http://www.chaparral-racing.com/
http://www.chem.agilent.com/
http://www.clarks.co.uk/
http://store.ctvolympics.ca/
https://www.dolce-gusto.de/
http://www.doubleday.com.au/
http://www.doubleday.co.nz/
http://www.douweegbertsenmeer.nl/
http://sites.dymo.com/Pages/home.aspx?locale=enUS
http://www.dynamicsexchange.com/
http://www.ebgames.com/
http://educacional.bmf.com.br/
http://www.extra.com.br/
http://www.festool.de/
http://www.gamestop.com/
http://www.gevalia.com/
http://www.gracobaby.com/
http://www.hanes.com/
http://www.hsslivehire.com/
http://www.jules.fr/
http://www.kalligo.fr/
http://www.ocean.slb.com/
http://rockshop.hardrock.com/
http://www.harrods.com/
http://www.mathon.fr/


Saturday, January 22, 2011

Sample credit card numbers for testing Commerce Server 2009

• American Express: 3400-0000-0000-009
• Visa: 4111-1111-1111-1111
• MasterCard: 5111-1111-1111-1118
• Discover: 6011-0000-0000-0004

Friday, January 7, 2011

Commerce Server Inventory System Part 2



Inventory Systems Features

The Inventory System in Commerce Server comes with many important features that aid in the real-time management of inventory for items in your catalog. These features allow you to do the following:
* Display real-time inventory conditions of your products and product variants, including in stock, out-of-stock, back-ordered, or pre-orderable.
* Filter products and product variants listings to show only those products that are currently available in stock.
* Decrement inventory levels when orders are processed.
* Receive notifications when inventory levels reach an out-of-stock threshold.
* Integrate inventory levels with LOB applications.
* Gain insight into how well products and product variants are selling.
As the Inventory System deals with physical items that can be sold, it is common to refer to items as a stock-keeping unit (SKU) rather than a product or product variant. A SKU is a unique identifier that enables a product to be tracked for inventory purposes.

Inventory Conditions

There are two primary inventory conditions that exist for your SKUs: in stock and out-of-stock. When a SKU is in stock your customers should be able to purchase it normally, with each processed order decrementing the inventory total for the SKU. When a product is out-of-stock, however, special handling conditions may apply.
The easiest way to handle out-of-stock inventory is to not show it on the Web site, thereby preventing customers from purchasing the SKU. While this is a simple way to handle out-of-stock inventory, it is probably not an acceptable solution for most online Web sites. Instead, many Web sites prefer to display out-of-stock inventory as back-ordered. Back-ordered indicates that the SKU is temporarily out-of-stock. Typically a back-order availability date is also displayed with the SKU, indicating the earliest date that the back-ordered SKU is available. It is possible to still allow the customer to purchase back-ordered SKUs and indicating to the customer that the order cannot be fulfilled until the inventory has been replenished.
In addition to the back-ordered inventory status, a SKU may be listed as pre-orderable. A Web site may want to list a SKU as pre-orderable, indicating that the SKU is not in stock and is not available until a future availability date. Marking SKUs as pre-orderable is a popular way to satisfy the demands of customers that want to purchase popular items before they are available. Allowing the pre-order of SKUs is quite popular in the book publishing industry, and is how many books end up as best sellers before they are even published.
If a SKU is both pre-orderable and back-ordered, the Inventory System first uses the associated pre-order limit to satisfy purchases. Once this limit has been exceeded, the back-order limit is then applied. Once both the pre-order and back-order limits have been exhausted, the SKU is then considered out-of-stock and no available for purchase.
Figure 4-2
Figure 4-2 shows the possible purchasing conditions that can exist for SKUs in the Inventory System. If an item is in stock, then it is available for purchase. If an item is out-of-stock, then it is either not available for purchase, back-orderable, or pre-orderable. It is important to recognize that while the Inventory System may have various conditions attached to SKUs (such as back-ordered or pre-orderable) the Web site itself must manage these conditions appropriately. Unless you use the Starter Site, your Web site will not automatically associate these purchasing states to the SKUs. You have to develop your Web site to respond in this fashion, through the Inventory APIs.

Integration into the Orders System

The Inventory System is able to work directly with the Orders System so that inventory levels remain accurate and the customer’s orders are processed appropriately. The interaction between these two systems through the use of two pipeline components: CheckInventory and UpdateInventory.
The CheckInventory pipeline component is part of the Basket pipeline and checks the inventory status for SKUs in the customer’s basket. This component will return information to the Web site that indicates the current condition of the SKU. Based on the condition of the SKU, the Web site can then render the customer’s basket appropriately.
The UpdateInventory pipeline component is part of the Checkout pipeline, and checks the inventory status for SKUs and updates the SKU quantities in the Inventory System. In addition to updating inventory quantities for the SKUs, this component also handles out-of-stock conditions. If there are multiple SKUs currently being processed, and one is out-of-stock and is not back-orderable or pre-orderable, the other SKUs are not processed.
Both the CheckInventory and UpdateInventory pipeline components have the ability to return warnings and errors through the pipeline. The Web site can then respond to these warnings and errors appropriately.

Additional Inventory Features

The Inventory System also includes the following features:
* Inventory APIs. The Inventory APIs allow developers to directly interact with the Inventory System.
* Imports and exports of data. Inventory data can be imported and exported either using the Catalog Manager or by directly using the Inventory APIs.
* Bulk updates and deletions. With bulk updates and deletions, you have the ability to update or delete multiple SKUs in the inventory catalog from a single operation.
* Transactional operations. All operations performed during an import or an export can be run in a transaction, so that any errors that occur cause the entire operation to roll-back.
* Integration into LOB systems through BizTalk adapters. The Commerce Server BizTalk adapters allow you to integrate the Inventory System with other LOB systems.
* Full text search. All metadata associated with the Inventory System can be searched and queried along with metadata from the Catalog System.
While the Inventory System has a rich set of inventory management functions, it may not satisfy the inventory needs of all companies. The Inventory System for Commerce Server is an extension of the Catalog System designed to provide real-time management of inventory. Consequently, the Commerce Server Inventory System does not provide any warehousing, manufacturing, or logistical information about the inventory. If your company has these types of requirements you will need to weigh the benefits of using a third party application or extending and customizing the Inventory System. In some situations it may be best to purchase a 3rd party application to manage and control these processes, and utilize the BizTalk adapters to integrate it into Commerce Server.

Based on my book on Commerce Server. Part 3 is here.

Tuesday, December 7, 2010

Commerce Server Inventory System Part 1

Inventory management is a vital part of any retail business, whether it’s a traditional brick-and-mortar shop or an online Web site. Inventory management provides you with critical information about the condition of your products, such as whether you are low on stock and your inventory needs to be replenished. Inventory management also provides your customers with accurate information, letting them know when items are out-of-stock, back-ordered, or pre-orderable. Failure to provide your customers with this information puts you at risk of losing future business. Inventory management also gives you insight into which products are selling well and which products are not. This information allows you to make better business decisions on how to market your products, and whether or not to even carry them.

Previous versions of Commerce Server to 2007 did not have an out-of-the-box inventory system. Instead, developers were either required to customize and extend the catalog schema, as well as write custom processes to track inventory levels, or develop their own processes for integrating into a line-of-business (LOB) inventory system.

Commerce Server has made significant advances with regards to inventory management, and has an out-of-the-box Inventory System capable of providing the following functionality:

* Real-time inventory management for product catalogs

* Full integration into the Catalog System and Orders System

* Integration into LOB systems through the Commerce Server BizTalk adapters

Keeping track of inventory is vitally important for any successful retail enterprise. Inventory systems let you know when it is time to stock up on items that are running low and can also prevent you from over selling products and then having to inform customers that their items are either unavailable or must be backordered. Inventory systems can provide insight into which products are selling well and which products are selling poorly. With this information you can make intelligent decisions on how to maximize your sales and make your Web site more effective.

In previous versions of Commerce Server it was a challenge to incorporate real-time inventory management into your Web site. Keeping the inventory levels synchronized to the product catalog required a great deal of effort and custom software development. Many custom solutions require the product catalog schema to be extended so that it can accommodate inventory information and modifications to the basket pipeline to check the inventory levels of the product added to the basket. This in and of itself is a challenge; more complex tasks, such as configuring items as back-orderable or pre-orderable, are levels of magnitude more complex to develop.

Fortunately, the Inventory System available in Commerce Server is specifically designed to integrate with the Catalog System, and provides an excellent solution for all the stake holders of your Web site, including customers, business users, Web site administrators, and software developers. Customers benefit from a much richer integration into the product catalog, allowing them to know if items are in stock, pre-orderable, or back-orderable. Customers can also filter products by those in stock, allowing them to ignore items that are currently unavailable (assuming you have developed this capability through the Inventory APIs). Business users benefit by having a far more robust and reliable method of coupling the inventory and product catalogs, as well as gaining insight into inventory levels and trends. Web site administrators benefit by easy import and export functionality, as well as synchronization to external LOB applications. Software developers benefit from all of the above, as well as a rich API layer that has methods for searching, browsing, and viewing the details of the inventory catalog, as well as sophisticated search options.

It is important to fully understand the role that the Inventory System plays within Commerce Server, and how it works together with product catalog to allow you to manage your inventory.

The Relationship between the Inventory and Catalog Systems

Before diving into the features of the Inventory System, you should take the time to understand the relationship between the Inventory and Catalog Systems. The Inventory System consists of inventory catalogs, much as the Catalog System consists of product catalogs. These inventory catalogs contain information about products and product variants that are stored in the product catalogs. As such, inventory catalogs can store inventory information for one or more product catalogs. Moreover, these product catalogs can be both base and virtual catalogs. Consider the following examples in Figure 4-1.



Figure 4-1

Scenario A describes a straightforward relationship between an inventory catalog and a product catalog. In this scenario, an inventory catalog has been defined and one product catalog added to it. When a product catalog is added to an inventory catalog it is considered to be mapped to the inventory catalog. Scenario B is similar to Scenario A, except that two product catalogs are mapped to the inventory catalog. Consequently, the inventory catalog contains inventory information for product and product variants stored in both catalogs.

As previously mentioned, virtual catalogs can also be mapped to inventory catalogs. Consider scenario C, in which the virtual catalog is the aggregation of two base catalogs. In this scenario, the virtual catalog is mapped to the inventory catalog. Consequently, the two base catalogs do not contain any inventory information. Instead, the inventory information is specific to the virtual catalog. Mapping virtual catalogs to an inventory catalog is a very powerful way to manage the inventory for aggregated base catalogs with specific pricing rules. For example, you could create a virtual catalog that gave preferred customers 15% off of various products and map it to an inventory catalog that limits the total quantity of these discounted products to 50.

The final scenario shows a more advanced set of relationships. In scenario D there are two base catalogs and one virtual catalog. The virtual catalog aggregates the products and product variants in both of the base catalogs and may apply special pricing. The virtual catalog and one of the base catalogs are mapped to the inventory catalog, while the second base catalog is not mapped to the inventory catalog. As a result, the mapped base catalog has the ability to track its own inventory, while the non-mapped base catalog cannot. The virtual catalog is able to track its own inventory on the products and product variants aggregated from both of the base catalogs. These four scenarios demonstrate the flexibility of the Inventory System, and how it can be used for a number of different and unique situations.

Based on my book on Commerce Server. Part 2 is here.

Monday, November 8, 2010

Commerce Server Template Pack for SharePoint 2010

At our User Group meeting last week, I installed the Template Pack live on a SharePoint 2010 installation. Several asked to have the procedure I used, so here goes.

The main point with the template pack is that it works with CS2009, you do not have to wait for R2.

1. First you will need a functioning SharePoint 2010 installation. This has quite a high Hardware Spec, with 64 bit and 8 GB. I did my Hyper V installation with 4 GB, but I am not recommending this. If you are using virtual images you will need a separate machine as a domain controller. Yes, I know you there are other options, hacking SharePoint (for local accounts) or hacking Commerce Server (so that you can install on a domain controller) but the whole point is to have a supported installation.

2. Second you will need to go through the usual fun process: Install Commerce Server 2007, Configure, Install Commerce Server 2009, Configure. Make sure you have everything you need (eg. Business Tools) otherwise you will have to uninstall CS2009, to get these. I usually unpup rather than use a CS project, so I have no VS2005/2008/2010 problems here. You of course will need the 64 bit version of the cab file:
CSRedistW2k3EN64.cab
If you are installing on W2008 R2 as I was you will get an error that Net 3.5 SP1 is not installed, even if it is automatically installed as part of W2008 R2. Installing will of course give the error that it is already installed. The only way out of this infinite loop is hotfix KB 975567, the hotfix was filed under Vista, but worked fine.

3. Now is a good time to switch User Account Control off. I have my reservations about this step, but it is in black and white in the Template Pack installation instructions. I leave it to you if you do it with the UI or Group Policy, I preferred the registry entry setting key HKLM\Software\Microsoft\Windows\ CurrentVersion\Policies\System\
EnableLUA to 0
Then install the Template Pack.

4. Next you should create your web app and extend it. You can use the SharePoint Commerce Services Wizard for this, I preferred to do this with SharePoint central admin. Add your host headers to DNS.

5. Now create your Commerce Server site. I unpacked the DefaultSiteWithData and made sure I named the site ContemporarySite. The reasons for doing this step manually are because of the next step. Make sure that all accounts have the rights in SQL they need.

6. If you run the SharePoint Commerce Services Wizard now (with Windows 2008 R2), the Wizard will fail with an error creating the Profile encryption key. I suspect this is because Windows 2008 R2 restricts Registry entries, perhaps things will be better after W2008R2 Sp1.
So with thanks to Ravi Kanth's blog, you will have to run
ProfileKeyManager.exe /kn /O (Note: Ravi has a typo here, it should not be a zero.)
ProfileKeyManager /ke /kf "NewKeyPair_2010_9_15_20_46_14_35.xml" /reg "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Commerce Server 2007 Keys\ContemporarySite"
(you will have to adjust the key file name to match the autogenerated name from the first command.)

7. Now you can run the SharePoint Commerce Services Wizard and select the web app you have created and the Commerce Server site you created. Press View Site and ....

8. You should have the Contemporary Site coming up, obviously the Channel needs to be set.
Careful, you cannot run the Wizard twice, without getting an DLL open error. The product team says that you can fix this by retracting and removing the solution before running again, makes sense to me. But some claim the only way to fix this is to run reflector and skip one line.
According to the product team there is another known issue on CS default zone with SP2010 if an IIS Hotfix (KB979917) is installed (which is recommended by SP2010). The workaround is to change the AllowAnonymousImpersonation value from default value “true” to “false”
Don't forget, there is a new extensibility kit that comes with the template pack, you will need to use this one if you are changing web parts.

9. If you open the Forms authenticated site in your browser you will get the unusually helpful message in your error log:
Object Cache: The super reader account utilized by the cache does not have sufficient permissions to SharePoint databases.
To configure the account use the following command 'stsadm -o setproperty -propertyname portalsuperreaderaccount -propertyvalue account -url webappurl'. It should be configured to be an account that has Read access to the SharePoint databases.
Additional Data:
Current default super reader account: NT AUTHORITY\LOCAL SERVICE

This is because this claims authentication does not resolve this account. To fix, use the stsadm command as they suggest to set the portalsuperreaderaccount to an appropriate domain account

Caveat: Obviously you should read and follow the entire Template pack installation instructions, especially if doing a production installation. There are more hotfixes needed for production, but this quick guide should get you going with a working installation. As with any technical procedure, there are bound to be mistakes in my write up, please let me know, so I can correct them.

Monday, August 30, 2010

The Microsoft Certified Master program

I just added the MCM logo to my blog. Why? Just another certification from Microsoft? Last time I looked on my transcript, I had the following, MCT, MCSD, MCDST, MCAD, MCDBA, MCSA, 2 MCITPs, 19 MCTSs, 5 MCPDs and 3 MCSEs. Each of those certifications took a lot of work and study and I consider each a good proof of competence in a technical area. Why am so excited about 3 more unpronounceable letters? ( so much so that when the email came late at night on Friday, our whole family was dancing around our home).

The key lies with the difficulty of the Master certification. The Master certification in effect certifies that one is an expert in a particular area, in my case SharePoint 2007. When I came to the three weeks of intensive course in Redmond in March 2009, I considered myself very competent in SharePoint, I had worked with SharePoint from the early beginnings of Digital Dashboard, all though the incarnations 2001, 2003 and 2007. I had gained a lot of experience, coaching a consultancy to become a SharePoint consultancy, retraining their consultants and developers to become SharePoint consultants and developers and fielding all the more difficult problems that came up. However, coming to Redmond I was a Commerce Server expert, not a SharePoint expert and to obtain the Masters certification I had to become an SharePoint expert. The 3 written exams are difficult enough, but it is the lab exam that is the real monster. 8 and a half hours of real world tasks that would usually take 8 and a half days in the real world. Because of the time difference between Europe and the US, by the end of my retake it was after midnight and I was so exhausted I would have had difficulty spelling SharePoint let alone doing any tasks. It took me more than a year after the Redmond training to reach the level of expertise required. Some of the recipes on this blog are the product of that preparation. Does that mean that I now think I know everything about SharePoint? No, it means that I have to continue learning constantly just to keep up. Being a master requires clearly identifying what you do not know and constantly filling in the gaps.

What advice do I have to others considering the same path? Firstly, I would advise you to be sure you are an expert before you get to Redmond. You will get much more out of the class. The experience is unique, you are sitting with a class with vast experience and the program tries to get the instructors who have the best knowledge in the world. Not all of them are natural teachers, so you also have to be able to draw the information out of them. It is also much easier if you can concentrate just on one product, my life is made a lot more difficult in effect trying to be a master of both SharePoint and Commerce Server, (even though there is no master program for Commerce Server).

Now that I have joined an small group of MCMs, (I calculate that I am the 18th outside Microsoft to obtain this qualification for SharePoint), do I think that we know SharePoint better than anyone else? No, I am very conscious that there are doubtless many good SharePoint experts who will not get this opportunity. (Having my own company meant that it was easier to convince my boss.) What about MVP's? I realize that MVP is an award given in recognition of services to the community, it does not in itself certify that one is an expert in that area. That said, we had 2 MVPs in our class and they were among the best in the class. The Master certification however, certifies that one is an expert right across SharePoint not just one particular area. Thus it is especially the case that although there is a focus on the architecture of large farms, since this is where you especially need a Master, a Master also has to know the development side well also. While there can always be gaps in a Masters knowledge, the breadth and depth of the exams sure tries to make sure that those gaps are small.

What is the Return On Investment from the Masters program? The jury is still out on that one. It would help us if Microsoft would require (or strongly recommend) having an MCM on board for large installations. It would help if a Gold Partnership received an advantage in competencies for having a Master involved. Unfortunately, they have recently gone the other way, and the Partner program no longer counts an MCM as counting as two MCPs.

What is my next step? I need to first make sure that my understanding of Commerce Server and SharePoint 2010 is at the same level as my understanding of SharePoint 2007. And that is a challenge enough for today.

Here are some of my classmates blogging about their experience:
http://www.houberg.net/archive/2009/04/06/master-training_are-you-ready.aspx
http://www.sharepointchick.com/archive/2009/04/08/the-microsoft-certified-master-experience.aspx
http://harbar.net/archive/2009/04/28/certified-master-for-sharepoint-2007-ldquor2rdquo.aspx
http://www.bluedoglimited.com/SharePointThoughts/ViewPost.aspx?ID=301
http://www.sharepointbits.com/blog/2009/10/31/freshly-minted-microsoft-certified-sharepoint-master.html
http://blogs.msdn.com/b/ramg/archive/2009/05/16/my-mcm-experience.aspx