Nullable Types in Sprocs Aren't Nullable After Rev Engineering

Thread is closed for posting
2 posts, 0 answers
  1. Michael Luna
    Michael Luna avatar
    9 posts
    Member since:
    May 2007

    Posted 25 Sep 2009 Link to this post

    I have several stored procedures whose parameters have " = NULL" or " = 0" or some such thing after them in the sproc declaration.  Yet when OpenAccess reverse-engineers the stored procedures into a calling method, it does not use nullable types to represent those parameters (such as short? or int?).  It instead uses non-nullable types (e.g. short or int) and then I'm faced with having to go through and correct them all, or set and cast them in the caller, etc.  Why can't OpenAccess see that they're nullable and represent them accurately?

    There also seems to be an issue with mapping the CHAR(1) data type, which OA maps as "string" and again I have to manually fix it or cast it.
  2. Ady
    Ady avatar
    589 posts

    Posted 30 Sep 2009 Link to this post

    Hello Michael Luna,

     Which backend are you using? I did refer to some previous posts from you and noticed MS SQL Server.
    The Reverse mapping wizard does map nullable procedure parameters to .NET nullable types.
    Also a CHAR(1) data type is mapped to a 'char' type.

    Can you provide us with the procedure declaration and the backend?

    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Watch a video on how to optimize your support resource searches and check out more tips on the blogs.
Back to Top