Questions tagged as 'entity-framework'

1
answer

Error with relationship 1 for many, Power Tools does not generate model

I want to do one-to-many relationship in EF where one and only Territory has multiple regions, but when I parse the model in Power Tools it does not recognize it. Region [Table("Regiao")] public class Regiao { [Key] [DisplayFormat...
asked by 23.09.2015 / 22:32
1
answer

C # put a condition for a column value in a DataGridView with DataSource

I'm using VS2013 Entity 5. The situation is as follows: In a Children table, there is a SexString attribute that receives the value 0, 1. 0 for male and 1 for female. (could use "m" or "f", but it is a learning situation) In my DataGridVie...
asked by 18.09.2015 / 22:03
1
answer

Problem in MySQL Connector

I'm using MVC 3, EntityFrameWork 4 and MySQL database. I hosted my application on Locaweb. Unfortunately I can not do the same connect to the database. Running the application on my local machine and connecting to the bank hosted on Locaweb work...
asked by 14.07.2015 / 19:12
1
answer

Problem loading data with Entity Framework using Include

I'm using the Entity Framework with MySql on my system and I need to do a specific query that includes a list of a Model ( ApplicationUser ), in this list each returned object has in its properties another Model . That is, each...
asked by 06.06.2015 / 01:40
1
answer

@ Html.Dropdownlist returns null value

ASP.NET MVC4 I have a data dropdown problem of a dropdownlist where the same list correctly the values, but when choosing some value and posting on the page the value arrives as null in the controller. My Domain is like this: Table of Cont...
asked by 06.06.2015 / 02:52
1
answer

SQL database for multiple users [closed]

Well, I have a question. I'm developing a web application that will serve more than one user, however each user has different data recorded in the database, and this volume will be great since the system is for sales management. I would like...
asked by 03.06.2015 / 19:47
1
answer

Is it really necessary to create a property that indicates the foreign-key of a One-To-Many relationship?

I would like to know if the information I found after searching, which briefly is in the link below, proceeds: link Question: In a hypothetical situation, if we have the Car class and the Tag class, where Car has a tag > and...
asked by 17.07.2015 / 21:55
1
answer

Is it possible to use copyBulk with datatable to load data into DBMS?

I went through an experience of loading large data from a text file, which needed to be criticized before writing to BD. I used DataTable with copybulk. I realized that loading data into DataTable and later into DB was fast. I have received crit...
asked by 14.04.2015 / 23:47
1
answer

How popular is a TreeView with a list of the bank?

I have a% static% representing folders and files in this template: <asp:TreeView ID="TreeView1" runat="server"> <Nodes> <asp:TreeNode Text="Diretorio1" Target="_blank"> <asp:TreeNode Text="arquivo1 " Target=...
asked by 13.02.2015 / 01:50
2
answers

How to return all records in a table

In my context I have a File table, and another version of the file, so I did with the entity to return a file, and only one version of the file: internal Arquivo GetArquivo(string termo) { using (var ctx = new GEDEntities())...
asked by 05.02.2015 / 13:26