Menu

#162 Provides support for the uniqueidentifer column type...

closed-accepted
None
5
2011-04-11
2011-02-02
No

The attached patch provides support for the uniqueidentifier type in Microsoft SQLServer. The commit message is:

Provides support for the uniqueidentifier column type in SQLServer.

The column type is handled via the UniqueIdentierType provided by the
patch. This type marshalls a UUID value into a uniqueidentifier column
and back.

Modified the MsSqlDataTypeFactory to correctly return this new type when
it detects a UUID.

Also included are unit tests to verify all new code.

Discussion

  • Jeff Jensen

    Jeff Jensen - 2011-02-22

    Darryl, I'm using Eclipse apply patch feature and the patch is not lining up. Perhaps you need to gen the patch without the git syntax option? Do you have other suggestion?

     
  • Darryl Pierce

    Darryl Pierce - 2011-03-01

    I've added a newer version of the patch generated using svn diff.

     
  • Jeff Jensen

    Jeff Jensen - 2011-03-12
    • assigned_to: nobody --> jeffjensen
     
  • Jeff Jensen

    Jeff Jensen - 2011-03-12

    Thanks for redoing the patch with svn diff.

    The simple issue with applying the patch is with UniqueIdentifierTypeTest: tearDown() has statement.verify(), and statement is never initialized; therefore a NPE.

    That's a pretty simple thing (you would have definitely encountered it running the test) which leads me to think something is incomplete/erroneous with the patch. So regretfully I need to ask you to fix and regen a patch. :-/

    One minor improvement: "uniqueidentifier" is hardcoded in a few places and I would appreciate if you extracted a "type name" public constant on the new UniqueIdentifierType class for it.

     
  • Darryl Pierce

    Darryl Pierce - 2011-03-23

    I've attached an updated patch. Fixed the NPE error and moved "uniqueidentifier" to a public constant on UniqueIdentifierType. Tests all pass.

     
  • Darryl Pierce

    Darryl Pierce - 2011-03-23

    SVN DIFF generated patch

     
  • Jeff Jensen

    Jeff Jensen - 2011-04-11
    • status: open --> closed-accepted
     
  • Jeff Jensen

    Jeff Jensen - 2011-04-11

    Committed revision 1217 (svn).

    Thanks for the patch.

     

Log in to post a comment.

MongoDB Logo MongoDB