SubSonic-2.0
SubSonic-2.0 copied to clipboard
Scaffold control broken for tables with GUID (uniqueidentifier) primary keys.
Environment:
- SubSonic 2.2
- Visual Studio .NET 2005
- SQL Server 2000
Sample Table (called 'Sample')
- SampleID, type=uniqueidentifier, Primary Key
- SampleName, type=varchar, size=25
Setup Scaffold Control:
- Create a new page (e.g. Sample.aspx).
- Add the scaffold control to the page. (e.g. <ss:Scaffold id="scaffold" runat="server"/>
- Set the Mode (ScaffoldMode?) property to 'Automatic'.
- Set the TableName property to 'Sample'.
Reproduce The Error:
- Open the page with the scaffold control.
- Select the sample table from the table list.
- Click the 'Add' button.
Note: The 'Add' screen only has a text box for the 'SampleName' field/column.
- Enter some text in the 'SampleName' text box.
- Click the 'Save' button.
- An exception is throw complaining about entering a NULL value into the 'SampleID' column.
When I Googled this issue I found references to a couple of 'resolved' work items, but all of the links to the original issues were broken - probably lost when subsonic was moved to github.
I would greatly appreciate any help with this problem.