locked
MULTILPLE DATABASE SUPPORT USING ENTITYFRAMEWORK RRS feed

  • Question

  • Dear Experts,

     

    Presently we are having an application(Asp.net ,c#) which is using sqlserver as backend.

    Now we want to migrate to another database (Eg: MYSQl,Oracle or someother).

    Is it possible to build application which supports multidatabase using EntityFrameWork.

    I Don't want the exisiting code to be changed , when i switch to other databases.

    Please , give your valuable suggestions.

     

     

     

     

    Monday, January 16, 2012 9:57 AM

Answers

  • On 1/16/2012 4:57 AM, GopiKrsna wrote:
    > Dear Experts,
    >
    > Presently we are having an application(Asp.net ,c#) which is using
    > sqlserver as backend.
    >
    > Now we want to migrate to another database (Eg: MYSQl,Oracle or someother).
     
    EF supports other database providers like MsSQL and Oracle
    >
    > Is it possible to build application which supports multidatabase using
    > EntityFrameWork.
    >
    > I Don't want the exisiting code to be changed , when i switch to other
    > databases.
     
    Then your existing code should be using Data Transfer Objects, which an
    abstraction away from the underlying ORM.  Layers above a Data Access
    Layer will be unaffected by a ORM change or database change in the DAL,
    because of the DTO usage.
     
     
    • Marked as answer by Allen_MSDN Thursday, January 19, 2012 2:06 AM
    Monday, January 16, 2012 10:57 AM

All replies

  • On 1/16/2012 4:57 AM, GopiKrsna wrote:
    > Dear Experts,
    >
    > Presently we are having an application(Asp.net ,c#) which is using
    > sqlserver as backend.
    >
    > Now we want to migrate to another database (Eg: MYSQl,Oracle or someother).
     
    EF supports other database providers like MsSQL and Oracle
    >
    > Is it possible to build application which supports multidatabase using
    > EntityFrameWork.
    >
    > I Don't want the exisiting code to be changed , when i switch to other
    > databases.
     
    Then your existing code should be using Data Transfer Objects, which an
    abstraction away from the underlying ORM.  Layers above a Data Access
    Layer will be unaffected by a ORM change or database change in the DAL,
    because of the DTO usage.
     
     
    • Marked as answer by Allen_MSDN Thursday, January 19, 2012 2:06 AM
    Monday, January 16, 2012 10:57 AM
  •  

    Thanks!Reply

    Monday, January 16, 2012 12:21 PM