All Questions
2,857
questions
0
votes
0
answers
23
views
Database does not exist docker image Npgsql.PostgresException (0x80004005): 3D000: database "CatalogDb" does not exist
I am trying to connect to postgres database running on docker container from visual studio, I am sure the DB exists and here is the logs:
docker ps:
docker ps
CONTAINER ID IMAGE COMMAND ...
-1
votes
0
answers
17
views
How can I show all results of an aspx table on one page or export to csv?
Currently I am manually copying and pasting the results from the following website into a spreadsheet on a daily basis:
https://registers.maryland.gov/RowNetWeb/Estates/frmEstateSearch2.aspx
Obviously,...
0
votes
0
answers
37
views
GridView`s SQL Data Source update
this is the aspx GridView
<asp:SqlDataSource ID="SqlDataSource2" runat="server" ConnectionString="<%$ ConnectionStrings:con %>" SelectCommand="SELECT [...
0
votes
1
answer
33
views
ContextDB Disposed Before Background task finish [duplicate]
I am trying to build a Http API By C#. After returning the HTTP Response, I need to do some works and then update the database in the background.
However, I guess the DBContext instance is disposed ...
0
votes
1
answer
96
views
Entity Framework Core problem: error within getting record: Unable to cast object of type
I have a problem that when I call multiple repository types in one class in one scope, I get an error:
System.InvalidCastException HResult=0x80004002 Message=Unable to cast object of type '...
0
votes
0
answers
26
views
Get From Session in .NET
This is my methods for get session and save in. I set session method in correct way and write service in IOC:
service.AddHttpContextAccessor();
public List<CartItemViewModel> GetFromSession()
...
0
votes
0
answers
44
views
How can I manage shopping card in client side in ASP.NET
This is my method in User panel after click on Card Icon in header: as you see I read from data base some data. But I Have a script to handle and manage shop card ,
[HttpGet("/UserPanel/...
0
votes
1
answer
40
views
I can not get FoodSelectedId in my Form in ASP.Net
This is my method for add food to my chef in my form: I want to add some food that was created before
[HttpGet]
[Route("CreateNewChefFood")]
public async Task<...
0
votes
1
answer
45
views
Error creating ASP.NET migration due to multiple foreign key constraints
I'm facing a problem creating the initial migration for my ASP.NET project. After defining models and data annotations, when trying to create the database, I encounter the following error in the NuGet ...
0
votes
0
answers
31
views
Error message 'Column '<columnname>' does not belong to table .' [duplicate]
I am working on an html site. I'm using an SQL database. I have a session 'user' that I am trying to add a value to from my table. Whenever I try to run the program it says the column does not exist, ...
1
vote
0
answers
45
views
Some PostgreSQL tables are not accessible from application using Npgsql, C#/ASP.NET
Background
I am currently writing the server-side application for an online turn-based in-browser game. I have set up a PostgreSQL database with a variety of tables within the default public schema ...
0
votes
1
answer
25
views
EF fails when Inserting only one out of two properties of the same type
I have this closure table that is supposed to make easier to get all replies of a comment, their replies, all replies to the comment ( even distant inheritants), but when I try to insert the parent - ...
0
votes
1
answer
49
views
How to Store 'Created By' and 'Updated By' with Current User ID in Database Transactions?
I'm trying to store all the transactions that occur in the database.
I have succeeded in storing 'created at' and 'updated at' by adding columns in the base
using Microsoft.AspNetCore.Identity;
using ...
2
votes
1
answer
68
views
Database error ; the value of the foreign key is unknown
These are the models
public class theTask
{
[Key]
public int TaskId { get; set; }
[MaxLength(50)]
[DisplayName("Tasks")]
public string Tasks { get; set; }
public ...
-2
votes
2
answers
81
views
How to avoid duplicate in database [closed]
Here my design database, I working on E-commerce project
So when the admin create a new product its have new Id and the user have to select the color and size for the product. The problem is when ...