|
-
Apr 19th, 2016, 10:24 AM
#1
Thread Starter
Fanatic Member
Create entity model in C# from database, but changing object names
I was considering creating a basic object model in my new C# MVC project by importing all of the database tables using the entity framework. However, our database standards mean that all tables are prefixed with tbl; e.g. the table for client details is called tblClient.
Is there a way to import all of the tables into the C# application while applying a conversion filter to remove that tbl from the front of every object, so that my client object is created with the name Client rather than tblClient?
Thanks...
-
Apr 19th, 2016, 04:48 PM
#2
Re: Create entity model in C# from database, but changing object names
I think that the content of the generated model (.edmx file) is XML so you can edit it after you have imported the model from the database as such and then generate your classes from that?
-
Apr 20th, 2016, 03:39 AM
#3
Thread Starter
Fanatic Member
Re: Create entity model in C# from database, but changing object names
That's a good idea - I'll give it a whirl.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|