When an xsd is constructed by XMLSpy (and possibly
other tools), a text type is represented (under certain
options) as xs:string with a maxlen of 2147483647.
GetForType does not catch this, and when the syntax
string is executed, an error occurs since varchars are not
supposed to be over 8000.
Recommend changing (in SqlDataSchemaAdapter,
protected override string GetTypeFor(DataColumn
column) ):
if ((column.DataType == typeof (String)) &&
((column.MaxLength < 0))
to:
if ((column.DataType == typeof (String)) &&
((column.MaxLength < 0) || (column.MaxLength >8000)) )
this will ensure that the type text will catch anything over
8000.
Please see attached file, line 121
Wiebe Tijsma
None
None
Public
| Filename | Description | Download |
|---|---|---|
| SqlDataSchemaAdapter.cs | SqlDataSchemaAdapter.cs with proposed changes | Download |
| Field | Old Value | Date | By |
|---|---|---|---|
| assigned_to | nobody | 2005-12-01 09:22 | uritsukidoji |
| File Added | 132674: SqlDataSchemaAdapter.cs | 2005-05-02 18:38 | scporich |
Copyright © 2009 Geeknet, Inc. All rights reserved. Terms of Use