Microsoft.SqlServer.TransactSql.ScriptDom Serialization bug - not all members are serializable - by DomF

Status : 


Sign in
to vote
ID 836372 Comments
Status Active Workarounds
Type Bug Repros 0
Opened 3/18/2014 2:42:41 PM
Access Restriction Public


The Microsoft.SqlServer.TransactSql.ScriptDom.dll (part of the SDK) holds the Microsoft.SqlServer.TransactSql.ScriptDom namesspace,. Most every class in the namespace is marked Serializable. Here's the CreateViewStatement class, for instance:

However, the TSqlParserToken class is *not* marked Serializable. This means that, practically speaking, *nothing* is serializable, since almost every useful class has parser token members or properties.  For instance, the TSqlFragment class has a ScriptTokenStream property (an IList of TSqlParserTokens) so it and anything deriving from it - any parsed result - is affected.
Sign in to post a comment.