Page 1 of 1
Fetch default values from DB
Posted: Mon 24 Jul 2017 09:11
by figueiredorj
Hi,
I would like to fech default values from collumns in db and apply it to properties (constructor).
Is this possible? how?
Thanks
Re: Fetch default values from DB
Posted: Tue 25 Jul 2017 18:43
by Shalex
You are using Database First approach with Devart Entity Model (*.edml), aren't you?
When adding a table to the model, Default Value of StorageColumn in SSDL and Default Value of EntityProperty in CSDL are initialized with the default value of the column in database.
Re: Fetch default values from DB
Posted: Wed 26 Jul 2017 14:12
by figueiredorj
Hi,
yes.. I am using database first aproach with entity framework;
However when adding tables fro sql where some collumns have default values applied... it is not replicated on model side.
thanks
Re: Fetch default values from DB
Posted: Wed 26 Jul 2017 16:28
by Shalex
Please specify:
1) the name and version of your target database server
2) the DDL script of a sample table for reproducing the issue