entity-framework-6

The input string had an invalid format. Entity Framework 6

Good day to all, I have been trying to solve this problem for a long time, I do not understand what the problem is. I use ORM ... = 8, FK_User = user }; context.WorkerCards.Add(card1); context.SaveChanges(); } } }

Error running update-database migration

I'm trying to run my database creation, but I'm getting this error below and I'm not understanding the reason: The type ... )); modelBuilder.Configurations.Add(new EnderecoConfiguration()); base.OnModelCreating(modelBuilder); }

MVC 5 and EF 6 Put form from another view

Keeps giving the comment error null in this line: ViewBag.PostId = new SelectList(db.Posts, "PostId", "Titulo", comentari ... .. }. Then when it goes to the line of ViewBag it gives the error. I noticed that model Comentario is not being instantiated.

Mapping relationships with Fluent API

I have three simple classes of city, state and country. I realized that simply declaring a property of type Estado in class C ... I did not realize if there is a difference from the state to the city and vice versa. I don't know if I'm doing things right.

How to create a login and password page in ASP.NET?

I'm trying to create a login control for my application but I'm not finding a way to do this. I would like it to be a complet ... one give me a tip how to do this? I know Visual Studio has the tools but I've never messed with it and would like to learn.

What can cause the EF performance drop in this scenario?

I've been doing a data import for a project in ASP.NET MVC 5 with EF 6.1 and SQL Server 2008 where the import data source w ... d; } else { profissao_id = profissaoTemp.Id; } } return profissao_id; }

Problem returning Entity models: "the entity or complex type ... cannot be constructed in a LINQ to Entities query"

I am trying to return a list of the objects generated by Entity Framework DataBase first but I get this error: The entit ... ength(100)] public string nome { get; set; } public virtual ICollection<TB_LEMBRETES> TB_LEMBRETES { get; set; } }

Doubt whether to use composite primary key or not in associative table

I'm making a relationship where the same is N: N... Example: Project X Official In this relationship I create an ass ... project id, idFunc , hourly load) Note: the employee cannot work on the same project more than once, only a single time.

How to create a non-repeating sequential number, per user

Work on a bill issuance project, in this project there is the entity Emissor. my database Sql-Server can have multiple is ... nce I can't keep a sequence separated by emitter. I Use Entity Framework 6 . Would anyone have any idea how to solve this?

Best practices when modularizing an application with EF and multi-bank

Let's say I want to model an application in .NET using EntityFramework as ORM and use one of its advantages, be "generic" for ... or rather, what are the best practices to be adopted in this scenario? How to deal with references / dependencies of dlls ?

Problem with Mysql net connector and Entity Framework

When I install the mysql connector in version 6.9.11, I can see the driver for the ADO.Net until then, it's fine. But whe ... 11 Visual Studio 2017 = > 15.5.4 Obs. I have already tried using Mysql for Visual Studio 1.2.7 and also get no results.

Form ASP.NET MVC 5 cannot access model properties

I'm starting on ASP.NET MVC, following tutorials and handouts on the internet I created a study project and I am having some ... the entity-framework. I even tried to create a Migration and give update-Database, but it did not have an effect on the bank.

Error running Entity Framework

I'm starting my study in EF, following this tutorial , I made up to 22 min of the video, hence when I will run bursts this er ... <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1" /> </startup> </configuration>

Code First One to Many can be null

My scenario: public class AlunoAvaliacao { public int AlunoAvaliacaoID { get; set; } public DateTime I ... erence of type 'Application.Color.Domain.Evaluate the question. I've tried modelBuilder... And nothing. Why this mistake?

Code First generating a foreign key

I have the following classes public class ControleDeVisitas { public virtual ICollection<TipoDeSistemas> TipoDeSi ... ControleDeVisitas"); HasKey(c => c.ControleDeVisitasId); HasMany(c => c.TipoDeSistemas); }

Error fetching record with FirstOrDefaultAsync ASP.NET CORE 3.0

I have a method to search the client in the database by the number of the CPF (no points, only the numbers), but in the datab ... err =>{ console.log(err); this.router.navigate(['', 'acesso-negado']); } ) } }

Which is the opposite of.equals in C#?

I'm doing a left Join where I want to take only what has in the left table and does not have in the right one. I'm using LI ... and Entity. I wanted a method that would necessarily do the opposite of equals. Note: the operator != did not work Vlww

Ternary relationship of entities in a relational schema would be counter-normative, and how to do this mapping in entity framework 6?

Taking as an example: We can abstract the relationship in several ways, one of them would be putting n p/ N relationship ... rojectEmployee' with table 'EMP_SKILL_PROJ' was already defined. Each EntitySet must refer to a unique schema and table.