<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://www.positive-change.co.uk/community/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Commerce Server</title><link>http://www.positive-change.co.uk/community/blogs/commerceserver/default.aspx</link><description>The Commerce Server 2007 Blog</description><dc:language>en-GB</dc:language><generator>CommunityServer 2.0 (Debug Build: 60217.2664)</generator><item><title>Changing the underlying transaction database tables</title><link>http://www.positive-change.co.uk/community/blogs/commerceserver/archive/2007/06/22/152.aspx</link><pubDate>Fri, 22 Jun 2007 09:21:00 GMT</pubDate><guid isPermaLink="false">ca834375-744d-47c4-8981-ce356ef0c621:152</guid><dc:creator>Simon</dc:creator><slash:comments>1</slash:comments><comments>http://www.positive-change.co.uk/community/blogs/commerceserver/comments/152.aspx</comments><wfw:commentRss>http://www.positive-change.co.uk/community/blogs/commerceserver/commentrss.aspx?PostID=152</wfw:commentRss><wfw:comment>http://www.positive-change.co.uk/community/blogs/rsscomments/152.aspx</wfw:comment><description>&lt;P&gt;One common error Ihave found which took ages to fix was:&lt;/P&gt;
&lt;P&gt;Microsoft.CommerceServer.ServerFaultException: Table PurchaseOrders contains 26 columns, expected 25 columns according to mapping definition &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;The numbers might change depending on how many columns you have or a expecting in the table you are accessing. This problem is not to do with the mapping xml files or any caching issues.&lt;BR&gt;The problem is that existing orders are summarises in the MarshalledData column and when you change the number of columns the existing orders wont work any more.&lt;BR&gt;Luckily we have only needed to change the column lengths during development and can delete all the orders we have so next time it works.&lt;BR&gt;&lt;BR&gt;I dont know what you would do if the live data was already populated and youneeded to extend the system. There might be a way to rewrite the correct marshalled data for the existing orders. Any ideas, feel free to post here.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://www.positive-change.co.uk/community/aggbug.aspx?PostID=152" width="1" height="1"&gt;</description></item><item><title>Changing values on a Purchase order once it has been created</title><link>http://www.positive-change.co.uk/community/blogs/commerceserver/archive/2007/05/08/120.aspx</link><pubDate>Tue, 08 May 2007 10:27:00 GMT</pubDate><guid isPermaLink="false">ca834375-744d-47c4-8981-ce356ef0c621:120</guid><dc:creator>Simon</dc:creator><slash:comments>1</slash:comments><comments>http://www.positive-change.co.uk/community/blogs/commerceserver/comments/120.aspx</comments><wfw:commentRss>http://www.positive-change.co.uk/community/blogs/commerceserver/commentrss.aspx?PostID=120</wfw:commentRss><wfw:comment>http://www.positive-change.co.uk/community/blogs/rsscomments/120.aspx</wfw:comment><description>&lt;P&gt;&lt;FONT face=Verdana&gt;Once a purchase order has been created, it is sometimes useful to change the values of that purchase order, values on the lineitems or the shipping address for each lineitem.&lt;BR&gt;An example of this might be where the delivery address changes at the point of delivery after the customer has placed the order. &lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana&gt;To change the values on an order, you must first get an OrderManagementContext object by either creating an OrderServiceAgent or an OrderSiteAgent.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;OrderSiteAgent ordersAgent = new OrderSiteAgent("mySiteId");&lt;BR&gt;OrderManagementContext oContext = OrderManagementContext.Create(ordersAgent);&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana&gt;Using the context it is possible to get a dataset which contains many tables of information relating to the order, the addresses and the lineitems.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana&gt;You can change the values of the datarows to reflect your changes and then update Commerce Server using the PurchaseOrderManager.UpdatePurchaseOrder method.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana&gt;This method accepts the dataset you have edited and an applicationId.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana&gt;The applicationId is one of the values found in the transactionConfig.StatusManager database table. The default values are Site and LOB Adapter.&lt;BR&gt;&lt;/FONT&gt;&lt;FONT face=Verdana&gt;&lt;BR&gt;If the purchase order is a new order, you can use the value "Site" in yor method. If the order is not, then you need to check the status of the purchase order. This will be one of the values in the table transactionConfig.AllowedStatus table.&lt;BR&gt;The ApplicationId you use in your method, must be one of the applicationId's in the StatusManager tables and that ApplicationId must has permission to update the status that the order form is currently in.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana&gt;If you are having problems updateing the dataset, this is most likely the reason. Add permissions for you applicationId to modify the Purchase order for the state the orderform is currently in.&lt;/FONT&gt;&lt;/P&gt;&lt;FONT color=#008080 size=2&gt;
&lt;P&gt;OrderServiceAgent&lt;/FONT&gt;&lt;FONT size=2&gt; agent = &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;new&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#008080 size=2&gt;OrderServiceAgent&lt;/FONT&gt;&lt;FONT size=2&gt;(&lt;/FONT&gt;&lt;FONT color=#008080 size=2&gt;ConfigurationManager&lt;/FONT&gt;&lt;FONT size=2&gt;.AppSettings[&lt;/FONT&gt;&lt;FONT color=#800000 size=2&gt;"ShopOrdersWebServiceURL"&lt;/FONT&gt;&lt;FONT size=2&gt;]);&lt;/P&gt;
&lt;P&gt;&lt;/FONT&gt;&lt;FONT color=#008080 size=2&gt;OrderManagementContext&lt;/FONT&gt;&lt;FONT size=2&gt; oContext = &lt;/FONT&gt;&lt;FONT color=#008080 size=2&gt;OrderManagementContext&lt;/FONT&gt;&lt;FONT size=2&gt;.Create(agent);&lt;/P&gt;
&lt;P&gt;&lt;/FONT&gt;&lt;FONT color=#008080 size=2&gt;PurchaseOrderManager&lt;/FONT&gt;&lt;FONT size=2&gt; poManager = oContext.PurchaseOrderManager;&lt;/P&gt;
&lt;P&gt;&lt;/FONT&gt;&lt;FONT color=#008080 size=2&gt;DataSet&lt;/FONT&gt;&lt;FONT size=2&gt; purchaseOrder = poManager.GetPurchaseOrderAsDataSet(&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;new&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#008080 size=2&gt;Guid&lt;/FONT&gt;&lt;FONT size=2&gt;(ViewState[&lt;/FONT&gt;&lt;FONT color=#800000 size=2&gt;"orderid"&lt;/FONT&gt;&lt;FONT size=2&gt;].ToString()));&lt;/P&gt;
&lt;P&gt;&lt;/FONT&gt;&lt;FONT color=#008080 size=2&gt;DataTable&lt;/FONT&gt;&lt;FONT size=2&gt; lineItems = purchaseOrder.Tables[&lt;/FONT&gt;&lt;FONT color=#800000 size=2&gt;"LineItems"&lt;/FONT&gt;&lt;FONT size=2&gt;];&lt;/P&gt;
&lt;P&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;foreach&lt;/FONT&gt;&lt;FONT size=2&gt; (&lt;/FONT&gt;&lt;FONT color=#008080 size=2&gt;DataRow&lt;/FONT&gt;&lt;FONT size=2&gt; drLineItem &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;in&lt;/FONT&gt;&lt;FONT size=2&gt; lineItems.Rows)&lt;BR&gt;{&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT color=#0000ff size=2&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;if&lt;/FONT&gt;&lt;FONT size=2&gt; (ViewState[&lt;/FONT&gt;&lt;FONT color=#800000 size=2&gt;"lineitemid"&lt;/FONT&gt;&lt;FONT size=2&gt;].ToString().ToLower() == drLineItem[&lt;/FONT&gt;&lt;FONT color=#800000 size=2&gt;"LineItemId"&lt;/FONT&gt;&lt;FONT size=2&gt;].ToString().ToLower())&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;string&lt;/FONT&gt;&lt;FONT size=2&gt; shippingAddressId = drLineItem[&lt;/FONT&gt;&lt;FONT color=#800000 size=2&gt;"ShippingAddressId"&lt;/FONT&gt;&lt;FONT size=2&gt;].ToString();&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;FONT color=#008080 size=2&gt;DataTable&lt;/FONT&gt;&lt;FONT size=2&gt; addresses = purchaseOrder.Tables[&lt;/FONT&gt;&lt;FONT color=#800000 size=2&gt;"Addresses"&lt;/FONT&gt;&lt;FONT size=2&gt;];&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;foreach&lt;/FONT&gt;&lt;FONT size=2&gt; (&lt;/FONT&gt;&lt;FONT color=#008080 size=2&gt;DataRow&lt;/FONT&gt;&lt;FONT size=2&gt; drAddress &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;in&lt;/FONT&gt;&lt;FONT size=2&gt; addresses.Rows)&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;if&lt;/FONT&gt;&lt;FONT size=2&gt; (drAddress[&lt;/FONT&gt;&lt;FONT color=#800000 size=2&gt;"orderAddressId"&lt;/FONT&gt;&lt;FONT size=2&gt;].ToString() == shippingAddressId)&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;FONT color=#008000 size=2&gt;//update the dataset&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;FONT size=2&gt;drAddress[&lt;/FONT&gt;&lt;FONT color=#800000 size=2&gt;"firstname"&lt;/FONT&gt;&lt;FONT size=2&gt;] = &lt;/FONT&gt;&lt;FONT color=#800000 size=2&gt;"Hello"&lt;/FONT&gt;&lt;FONT size=2&gt;;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;poManager.UpdatePurchaseOrder(purchaseOrder, &lt;/FONT&gt;&lt;FONT color=#800000 size=2&gt;"Site"&lt;/FONT&gt;&lt;FONT size=2&gt;);&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;break&lt;/FONT&gt;&lt;FONT size=2&gt;;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;break&lt;/FONT&gt;&lt;FONT size=2&gt;;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;BR&gt;}&lt;/P&gt;&lt;/FONT&gt;&lt;img src="http://www.positive-change.co.uk/community/aggbug.aspx?PostID=120" width="1" height="1"&gt;</description></item><item><title>Dynamically Loading Product property definitions including their data type information.</title><link>http://www.positive-change.co.uk/community/blogs/commerceserver/archive/2007/04/10/119.aspx</link><pubDate>Tue, 10 Apr 2007 14:14:00 GMT</pubDate><guid isPermaLink="false">ca834375-744d-47c4-8981-ce356ef0c621:119</guid><dc:creator>Simon</dc:creator><slash:comments>0</slash:comments><comments>http://www.positive-change.co.uk/community/blogs/commerceserver/comments/119.aspx</comments><wfw:commentRss>http://www.positive-change.co.uk/community/blogs/commerceserver/commentrss.aspx?PostID=119</wfw:commentRss><wfw:comment>http://www.positive-change.co.uk/community/blogs/rsscomments/119.aspx</wfw:comment><description>&lt;P&gt;Adding product definitions to Commerce Server is easy through the business tools. You can then add products that fit the product definitions. For example, if you create a product definition for a pair of jeans, then the product will have properties such as waist size, color and length. However, you would not want a wardrobe to have the same properties. You would create different definitions for each type of product and then match the product to the definition.&lt;/P&gt;
&lt;P&gt;If you need to get the defintions out of CS, you can use the method&lt;/P&gt;
&lt;P&gt;cContext.GetDefinitions()&lt;/P&gt;
&lt;P&gt;This method is called on the Catalog Context and returns a typed dataset of product defintion attributes. &lt;/P&gt;
&lt;P&gt;By using this method you can iterate through your product defintion attributes so you know what the attributes are called. &lt;/P&gt;
&lt;P&gt;I am building an administration area where clients will be able to choose a category to load their products and choose the correct defintion automatically based upon the category. This means that HQ can define the catalog and category structure of Commerce Server, decide what products can go into each category, and workers can add products to only certain categories and catalogs and can be restricted by other business logic through a custom website.&lt;BR&gt;This makes managing the site for large organisations much easier and more secure.&lt;/P&gt;
&lt;P&gt;I have created a .NET&amp;nbsp;user control that changes what .NET form control the user uses based upon the data type of the Product defintion property. For example a date time data type can display the calendar control, a text data type can display a text box etc.&lt;BR&gt;This allows me to show the correct fields for data entry for each product and product defintion. &lt;BR&gt;&lt;BR&gt;Unfortunately, the information returned in the dataset using the above method does not include the datatype of the properties. This means it is impossible to determine which type of control to display for each different data type.&lt;/P&gt;
&lt;P&gt;I have therefore created a Data Access Layer that gets the information directly from the _productCatalog database.&lt;/P&gt;
&lt;P&gt;I create the following stored proc:&lt;/P&gt;-------------------- 
&lt;P&gt;CREATE PROCEDURE [dbo].[getPropertyDefinitionsForSpecificProductDefinition] &lt;/P&gt;
&lt;P&gt;@definitionName nvarchar(128)&lt;/P&gt;
&lt;P&gt;AS&lt;/P&gt;
&lt;P&gt;BEGIN&lt;/P&gt;
&lt;P&gt;select &lt;/P&gt;
&lt;P&gt;ca.PropertyName,ca.DataType,ca.DisplayOnSite,ca.DisplayName,cdp.DefinitionId,cdp.PropertyOrder&lt;/P&gt;
&lt;P&gt;from &lt;/P&gt;
&lt;P&gt;CatalogAttributes ca &lt;/P&gt;
&lt;P&gt;join &lt;/P&gt;
&lt;P&gt;CatalogDefinitionProperties cdp &lt;/P&gt;
&lt;P&gt;on &lt;/P&gt;
&lt;P&gt;ca.PropertyName = cdp.PropertyName &lt;/P&gt;
&lt;P&gt;join &lt;/P&gt;
&lt;P&gt;catalogDefinitions cd &lt;/P&gt;
&lt;P&gt;on &lt;/P&gt;
&lt;P&gt;cd.DefinitionId = cdp.DefinitionId&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;where &lt;/P&gt;
&lt;P&gt;cd.DefinitionName = @definitionName&lt;/P&gt;------------------------ &lt;BR&gt;&lt;BR&gt;&lt;BR&gt;You can then retrieve the information you need from this and load the correct controls. 
&lt;P&gt;--&lt;/P&gt;
&lt;P&gt;I have linked a specific product definition to a category by a custom property in the category defintion. I only need to be able to define one product defintion per category so this works very well.&lt;/P&gt;
&lt;P&gt;The user chooses the category of product, the product defintion is loaded by using its name.&lt;BR&gt;The name is obtained from the custom property of the category the user has chosen.&lt;BR&gt;I then iterate through the dataset returned from this stored procedure and display the appropriate control.&lt;/P&gt;&lt;img src="http://www.positive-change.co.uk/community/aggbug.aspx?PostID=119" width="1" height="1"&gt;</description></item><item><title>Uploading Images into Commerce Server</title><link>http://www.positive-change.co.uk/community/blogs/commerceserver/archive/2007/04/04/116.aspx</link><pubDate>Wed, 04 Apr 2007 09:28:00 GMT</pubDate><guid isPermaLink="false">ca834375-744d-47c4-8981-ce356ef0c621:116</guid><dc:creator>Simon</dc:creator><slash:comments>0</slash:comments><comments>http://www.positive-change.co.uk/community/blogs/commerceserver/comments/116.aspx</comments><wfw:commentRss>http://www.positive-change.co.uk/community/blogs/commerceserver/commentrss.aspx?PostID=116</wfw:commentRss><wfw:comment>http://www.positive-change.co.uk/community/blogs/rsscomments/116.aspx</wfw:comment><description>&lt;P&gt;I was quite suprised to find that CS2007 does not support uploading images for products through the business tools. This is a basic requirement for all E-Commerce sites to display images of the products they are selling. I have thought about some possible solutions to this common problem and have briefly outlined some of them here:&lt;/P&gt;
&lt;P&gt;The solution seems to be to one of the following:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Use a custom property on the product to specify the image path and then upload the image via FTP. You could then get the image path for the product when it is loaded, and use this path to diaplay the appropriate image.&lt;BR&gt;&lt;BR&gt;This has major drawbacks in terms of scalability because you have to know how many images for each product you will need and extending the number means adding more custom properties and coding&amp;nbsp;on&amp;nbsp;the website.&lt;BR&gt;&lt;BR&gt;It also has the drawback of allowing the client FTP access to the server and making them use a seperate FTP client to load their images.&lt;BR&gt;&lt;BR&gt;Another drawback of this approach is that if the client types in the filename wrong then the image will not be loaded.&lt;BR&gt;&lt;BR&gt;When a site contains many thousands of products, the directory structure will become extremely untidy and images are not automatically removed when the product is sold or deleted.&lt;BR&gt;&lt;BR&gt;Database structure is also not optimised at their will be a lot of redundancy with regards to space as some of the custom properties will remain empty as&amp;nbsp;not every product will have the maximum number of allowed images.&lt;BR&gt;&lt;BR&gt;This solution might work for small sites with less then a 100 products and a client who does not mind using FTP.&lt;/LI&gt;
&lt;BR&gt;

&lt;LI&gt;Create a bespoke web page upload using HTTP File Upload that adds a single path to an image folder for each product.&lt;BR&gt;&lt;BR&gt;This solution mitigates against the problem of clients typing in the wrong filename and also allows better management of file structure.&lt;BR&gt;&lt;BR&gt;It also allows a random filename to be applied to the image which helps with Spoofing attacks and helps complience with PCI guidelines.&lt;BR&gt;&lt;BR&gt;By storing one path to a specific folder into commerce server, it also stops redundency in the database and allows scalability to allow as many images as is needed. Each product can have its own set of images in its own folder which will help with directory management.&lt;BR&gt;&lt;BR&gt;Another benefit of using this approach is that you can automatically resize the images using a .NET Bitmap object so that all images are the same size and quality.&lt;BR&gt;&lt;BR&gt;To manage multimple images for a single product with different sizes and different descriptions and alt tags for each one,&amp;nbsp;it is possible to&amp;nbsp;implemented an XML file for each folder (which in turn means each product) and store this in the folder with the images or in a custom property in CS.&lt;BR&gt;In this way we can keep track of all the images for each product and what size should be displayed where, in a relatively space friendly way.&lt;BR&gt;&lt;BR&gt;The images would still need to be manually deleted though when a product is removed from Commerce Server. This would be easier though because each set of images is in its own folder which could have the ProductId as its name.&lt;/li&gt;
&lt;br&gt;
&lt;LI&gt;The ultimate solution is to alter the business tools to allow image uploading and link in the products to the images so that when the product is removed, the image is also removed.&lt;BR&gt;This is by far the best solution for most projects, but does required quite an overhead in development time and means altering the underlying database structure of Commerce Server and the busienss tool UI.&lt;BR&gt;However, there is an excellent step by step approach given by Max in his blog here:&lt;BR&gt;&lt;A href="http://blogs.msdn.com/maxakbar/archive/2006/09/20/764026.aspx"&gt;http://blogs.msdn.com/maxakbar/archive/2006/09/20/764026.aspx&lt;/A&gt;&amp;nbsp;of how to do this.&lt;BR&gt;&lt;BR&gt;I have not followed his article yet, but intend to just to see how its done! I'll post any comments to this soluton here and on his blog when I get round to implementing the solution.&lt;BR&gt;Please note, there are several parts to his step by step so make sure you follow them all.&lt;/LI&gt;&lt;/UL&gt;&lt;img src="http://www.positive-change.co.uk/community/aggbug.aspx?PostID=116" width="1" height="1"&gt;</description></item><item><title>Extending Profiles in Commerce Server 2007</title><link>http://www.positive-change.co.uk/community/blogs/commerceserver/archive/2007/03/30/112.aspx</link><pubDate>Fri, 30 Mar 2007 13:43:00 GMT</pubDate><guid isPermaLink="false">ca834375-744d-47c4-8981-ce356ef0c621:112</guid><dc:creator>Simon</dc:creator><slash:comments>1</slash:comments><comments>http://www.positive-change.co.uk/community/blogs/commerceserver/comments/112.aspx</comments><wfw:commentRss>http://www.positive-change.co.uk/community/blogs/commerceserver/commentrss.aspx?PostID=112</wfw:commentRss><wfw:comment>http://www.positive-change.co.uk/community/blogs/rsscomments/112.aspx</wfw:comment><description>&lt;P&gt;&lt;FONT face=Verdana size=2&gt;We have been working on extending the profiles in CS 2007 to include some custom properties and have come across some interesting issues. I thought I'd add those here for anyone else who is extending the profile system.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;To add a custom profile property, you need to follow these steps:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;(Make sure you close the Customer and Profile Manager first as we found sometimes this locks records and you can find your profile properties disapearing after you add them!)&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;1. Add the column to the appropriate object table in the profiles database&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;2. Open CS Manager&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;3. Extend the Profiles node &amp;gt; Profile Catalog &amp;gt; DataSources node and all the way to the objects&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;4. Right click on the object you are extending and 'New Data Member'&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;5. Add the new member name and the display name and any description and map to the column in the database&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;6. Extend the Profiles node &amp;gt; Profile Catalog &amp;gt; Profile Definitions and click on the object type you are extending&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;7. Click onto a definition above where you want your new property to appear and click the 'Add' button at the bottom of the screen.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;8. Complete at least the Name, Display name and Type and open the Advanced Attributes tab.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;9. Click on the 'Map to Data' field and map to the column you added in step 5.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;10. You can set the max value to the length of the field if using a variable length data type in the Custom Attributes Tab.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;11. Click Apply&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;12. Click onto another object in the Profile Definitions tree. This is important as CS tools dont seem to save you changes until you do this. A box should now appear, asking if you wish to save changes.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;13. If you checked the searchable field in Advanced Attributes, you should now see the new field appear in the drop down box in the search field in the Customer and Profiles Manager.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;14. Do an iisreset and hopefully you should now be able to program against your new proprties.&lt;/FONT&gt;&lt;/P&gt;&lt;img src="http://www.positive-change.co.uk/community/aggbug.aspx?PostID=112" width="1" height="1"&gt;</description></item><item><title>Commerce Server 2007 Profiles</title><link>http://www.positive-change.co.uk/community/blogs/commerceserver/archive/2007/03/27/109.aspx</link><pubDate>Tue, 27 Mar 2007 10:53:00 GMT</pubDate><guid isPermaLink="false">ca834375-744d-47c4-8981-ce356ef0c621:109</guid><dc:creator>Simon</dc:creator><slash:comments>0</slash:comments><comments>http://www.positive-change.co.uk/community/blogs/commerceserver/comments/109.aspx</comments><wfw:commentRss>http://www.positive-change.co.uk/community/blogs/commerceserver/commentrss.aspx?PostID=109</wfw:commentRss><wfw:comment>http://www.positive-change.co.uk/community/blogs/rsscomments/109.aspx</wfw:comment><description>&lt;P&gt;&lt;STRONG&gt;&lt;FONT face=Verdana size=2&gt;Retrieving profiles from the database&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;We are creating a profile system whereby each UserObject profile belongs to an Organisation Profile object. I wanted to return all UserObjects for a specific OrganisationId but have found that you can only search profiles using the web services and not directly with the APIs.&lt;BR&gt;This is because the search object ProfileManagementContext, which is used for searching, can only be created with a web service url or reference in its constructor.&lt;BR&gt;Therefore I am having to use part API calls and part webservice calls to achieve my goal.&lt;/FONT&gt;&lt;FONT face=Verdana size=2&gt;&lt;BR&gt;&lt;BR&gt;The only other way to search using the CS Library API is to use the CommerceContext.Current.ProfileSystem.CommerceOleDbProvider and access the Sql tables through this.&lt;BR&gt;However, the provider does not allow 'and' or 'or' in the where clauses and does not allow joins. So returning UserObjects by GeneralInfo.UserId from the UserObject and GeneralInfo.Name from the Organisation object is not possible.&lt;BR&gt;&lt;BR&gt;The only way to implement this functionality is to create a new Data Access Layer (DAL) to access the database directly, which is not recommended by Microsoft for obvious reasons.&lt;BR&gt;&lt;BR&gt;See: &lt;A href="http://blogs.msdn.com/maxakbar/archive/2006/11/03/free-commerce-server-2007-sql-2005-visual-studio-web-and-c-express.aspx"&gt;http://blogs.msdn.com/maxakbar/archive/2006/11/03/free-commerce-server-2007-sql-2005-visual-studio-web-and-c-express.aspx&lt;/A&gt;&lt;/FONT&gt;&lt;FONT face=Verdana size=2&gt;&lt;BR&gt;----------------------------------------&lt;/FONT&gt;&lt;/P&gt;&lt;img src="http://www.positive-change.co.uk/community/aggbug.aspx?PostID=109" width="1" height="1"&gt;</description></item><item><title>PUP Viewer</title><link>http://www.positive-change.co.uk/community/blogs/commerceserver/archive/2007/03/12/97.aspx</link><pubDate>Mon, 12 Mar 2007 14:48:00 GMT</pubDate><guid isPermaLink="false">ca834375-744d-47c4-8981-ce356ef0c621:97</guid><dc:creator>Simon</dc:creator><slash:comments>0</slash:comments><comments>http://www.positive-change.co.uk/community/blogs/commerceserver/comments/97.aspx</comments><wfw:commentRss>http://www.positive-change.co.uk/community/blogs/commerceserver/commentrss.aspx?PostID=97</wfw:commentRss><wfw:comment>http://www.positive-change.co.uk/community/blogs/rsscomments/97.aspx</wfw:comment><description>&lt;P&gt;A useful PUP viewer that works with CS2007 - see attachments.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://www.positive-change.co.uk/community/aggbug.aspx?PostID=97" width="1" height="1"&gt;</description><enclosure url="http://www.positive-change.co.uk/community/blogs/commerceserver/attachment/97.ashx" length="63054" type="application/x-zip-compressed" /></item><item><title>Resources for Commerce Server 2007</title><link>http://www.positive-change.co.uk/community/blogs/commerceserver/archive/2007/03/06/88.aspx</link><pubDate>Tue, 06 Mar 2007 15:42:00 GMT</pubDate><guid isPermaLink="false">ca834375-744d-47c4-8981-ce356ef0c621:88</guid><dc:creator>Simon</dc:creator><slash:comments>12</slash:comments><comments>http://www.positive-change.co.uk/community/blogs/commerceserver/comments/88.aspx</comments><wfw:commentRss>http://www.positive-change.co.uk/community/blogs/commerceserver/commentrss.aspx?PostID=88</wfw:commentRss><wfw:comment>http://www.positive-change.co.uk/community/blogs/rsscomments/88.aspx</wfw:comment><description>&lt;FONT face=Verdana size=2&gt;Please add any useful URLS that you find for Commerce Server as comments to this post.&lt;/FONT&gt;&lt;img src="http://www.positive-change.co.uk/community/aggbug.aspx?PostID=88" width="1" height="1"&gt;</description></item><item><title>Installation of Commerce Server 2007</title><link>http://www.positive-change.co.uk/community/blogs/commerceserver/archive/2007/03/05/86.aspx</link><pubDate>Mon, 05 Mar 2007 15:29:00 GMT</pubDate><guid isPermaLink="false">ca834375-744d-47c4-8981-ce356ef0c621:86</guid><dc:creator>Simon</dc:creator><slash:comments>2</slash:comments><comments>http://www.positive-change.co.uk/community/blogs/commerceserver/comments/86.aspx</comments><wfw:commentRss>http://www.positive-change.co.uk/community/blogs/commerceserver/commentrss.aspx?PostID=86</wfw:commentRss><wfw:comment>http://www.positive-change.co.uk/community/blogs/rsscomments/86.aspx</wfw:comment><description>&lt;P&gt;&lt;FONT face=Verdana size=2&gt;------------------------&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;This is the list of steps that I took when installing commerce server, I have included the errors I got and how I overcame them.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;-----------------------&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;1. install windows 2003 web server edition&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;1a. install service packs and patches&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;2. configure for terminal services (optional)&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;3. add to iis asp.net 2.0 - intall the framework&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;4. add to iis - check web server extension 2.0 is activated&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;5. install sqlserver 2005&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;6. install patches etc&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;7. configure sqlserver 2005 for remote connections&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;8. install commerce server 2007&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;8a. Configure Commerce Server wizard - use Windows Authentication for database connections.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;9. install commerce server business parts (web services) This is done by re-rerunning the Commerce Server SetUp exe and installing Business Applications&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;10. install the&amp;nbsp;starter site application (Adventure Works)&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;10a Unzip the test site&lt;BR&gt;10b Copy the starter.pup file into C://Program Files/MS Commerce Server/PUP Packages&lt;BR&gt;10c Open Commerce Server Manager&lt;BR&gt;10d Right Click on the Commerce Sites Node in the tree and unpack the&amp;nbsp;starter.pup file&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;(at this point site not found 404 or permissions 403)&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;11. follow all of the steps in the installation guide for security &lt;/FONT&gt;&lt;A href="http://download.microsoft.com/download/d/b/e/dbe333fd-6cbe-4850-b24c-8da3704d6190/Commerce%20Server%202007%20Starter%20Site%20Installation%20Guide.htm" target=_blank&gt;&lt;FONT face=Verdana size=2&gt;http://download.microsoft.com/download/d/b/e/dbe333fd-6cbe-4850-b24c-8da3704d6190/Commerce%20Server%202007%20Starter%20Site%20Installation%20Guide.htm&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;12. biz talk error&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;EM&gt;&lt;FONT face=Verdana size=2&gt;The module 'CommerceProfileModule' depends on the site resource 'Biz Data Service' which does not exist in the Commerce Server administration database.&lt;/FONT&gt;&lt;/EM&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://groups.google.co.uk/group/microsoft.public.commerceserver.general/msg/bdf65887c9081811?dmode=source&amp;amp;hl=en" target=_blank&gt;&lt;FONT face=Verdana size=2&gt;http://groups.google.co.uk/group/microsoft.public.commerceserver.general/msg/bdf65887c9081811?dmode=source&amp;amp;hl=en&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;delete global resouce for profile and reload PUP for test site&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;13. cannot create file in C://temp - check permissions according to above document on the Temporary folder.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;14 any db permission errors check above document - this is mostly seen as the web services not running with 404 or 403 errors. They are actually security log in errors.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT face=Verdana size=2&gt;15. check event log for other errors&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;16. test each web service in browser&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;17. run cmd line test site creator - if red errors cant create class - check permissions on C://windows/temp - allow all web service users write access&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;This inputs all of the test data into the project - the exe is sampleDataImport.exe&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;18. You should now be able to run the admin and testsite to configure the adventureworks site.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;---&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Any other problems encountered, please add below...&lt;/FONT&gt;&lt;/P&gt;&lt;img src="http://www.positive-change.co.uk/community/aggbug.aspx?PostID=86" width="1" height="1"&gt;</description></item><item><title>Getting Started with Commerce Server 2007</title><link>http://www.positive-change.co.uk/community/blogs/commerceserver/archive/2007/03/05/85.aspx</link><pubDate>Mon, 05 Mar 2007 12:00:00 GMT</pubDate><guid isPermaLink="false">ca834375-744d-47c4-8981-ce356ef0c621:85</guid><dc:creator>Simon</dc:creator><slash:comments>0</slash:comments><comments>http://www.positive-change.co.uk/community/blogs/commerceserver/comments/85.aspx</comments><wfw:commentRss>http://www.positive-change.co.uk/community/blogs/commerceserver/commentrss.aspx?PostID=85</wfw:commentRss><wfw:comment>http://www.positive-change.co.uk/community/blogs/rsscomments/85.aspx</wfw:comment><description>&lt;P&gt;&lt;FONT face=Verdana size=2&gt;At the time of writing there are not many message boards or blogs about Commerce Server 2007 and other than the official documentation help can be hard to find.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;So&amp;nbsp;we have created this blog which covers some of the problems I and other developers on our team have come across and how we overcame them.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;The trial version of commerce server can be downloaded from Microsoft's Commerce Server website: &lt;/FONT&gt;&lt;A href="http://www.microsoft.com/commerceserver/default.mspx"&gt;&lt;FONT face=Verdana size=2&gt;http://www.microsoft.com/commerceserver/default.mspx&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT face=Verdana size=2&gt;Please do not post any company specific information here as this blog is available as read only to the public&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://www.positive-change.co.uk/community/aggbug.aspx?PostID=85" width="1" height="1"&gt;</description></item></channel></rss>