Questions tagged as 'entity-framework'

1
answer

doubts with entity and limit

I need to search the last 100 records of the bank, I am using the following code, but it returns the first 100: dynamic data = null; try { data = limit == 0 ? (from p in contexto.Set<TEntity>(...
asked by 12.09.2016 / 17:16
0
answers

How to install Npgsql as a data provider for ADO.NET Entity Framework?

I've read everything you can imagine, but I'm out of luck. In Visual Studio 2015 Enterprise update 1, I followed exactly the steps as described in the tutorial on link : I downloaded and installed: Setup_NpgsqlDdexProvider; I added the p...
asked by 01.08.2016 / 01:51
1
answer

How to make a Label receive a text from the bank

Hello, I know the question is very simple, but I have a difficulty, I have a radio button and I would like the text to be received from a SQL Server database through a SELECT. I am using the Entity Framework. Please leave examples.     
asked by 09.08.2016 / 18:32
1
answer

How to convert this Sql to entity framework?

I'm having trouble passing this sql to Entity Framework I'm using mvc 4. select pc.Nome, pc.Endereco, pc.Bairro, pc.Numero, pc.Telefone, pc.Email, ma.descricao from PontoDeColeta pc Inner join Material ma on(pc.IDMaterial =...
asked by 05.06.2016 / 02:38
0
answers

Automapper with related entity

Good afternoon, Mapping the following entities public class Artista { public Artista() { ArtistaCategoria = new List<ArtistaCategoria>(); } public int ArtistaId { get; set; } p...
asked by 16.05.2016 / 21:33
0
answers

The transport-level error has occurred when receiving results from the server

I have a Asp.Net MVC 4 application (with Entity Framework and SQL Server) that works normally on my application server, but now I had to work with redundancy and load balance with two new servers for the application (discarding the old one). O...
asked by 11.05.2016 / 22:32
0
answers

Show results of a Stored Procedure

I want to show the result of the procedure in a List I added in the model and generated this code. public virtual ObjectResult<string> SP_ListaDadosCarteiraPGC(Nullable<int> ano, Nullable<int> mes, string codex, string ada...
asked by 20.04.2016 / 20:41
0
answers

Error in Enable-Migrations in EF5 with MySql

I have a problem in my project, when trying to enable Migrations in the project it generates an exception as below: > System.IO.FileLoadException: Could not load file or assembly 'MySql.Data.Entity.EF5, Version=6.9.8.0, Culture=neutral, Pub...
asked by 27.04.2016 / 20:55
1
answer

Doubt about entities asp.net mvc

I have 4 tables: T1 , T2 , T3 and T4 and the Customers table . What happens is that the tables T2 to T4 should "be one. But as part of the data would be like a table and its options, I preferred to break for easier maintenance ......
asked by 26.05.2016 / 21:45
1
answer

ENTITY FRAMEWORK - add-migration New Project without renaming old tables

I want to share a database with some projects. I've already done the first project with the bank and it's ok. I copied the project to create a similar one, changed the initial prefix of the Ex tables: project1_client, project2_client and so t...
asked by 30.03.2016 / 20:57