I am using Dapper to fetch a 2 column resultset into a dictionary.
I noticed that intellisense shows me a .ToDictionary() when I hover over the resultset but I cannot get it to work since dapper uses dynamic properties/expandoObject...Dictionary<string, s...
How do i make Dapper.NET to CRUD my Oracle DB?...I have table named: ...PLAYER_LOG... it's identity is done by trigger, here is the sql...SELECT SQ_MASTER_SEQUENCE.NEXTVAL INTO tmpVar FROM dual;
:NEW.ID := tmpVar;
...my Model is:...public class PlayerLogS...
Using Entity Framework I can create concrete classes from most of the sprocs in the database of a project I'm working on. However, some of the sprocs use dynamic SQL and as such no metadata is returned for the sproc....So for a that sproc, I manually cre...
I am retrieving profile details with the following:...var profiles = connection.Query<Models.PROFILE>(
"SELECT * FROM PROFILES WHERE ID=@ID",
new { ID = profileID }); // IEnumerable
var profile = profiles.First<Models.PROFILE>();
...The profile o...
Here is an example of one of our data calls in our DAL using Dapper.Net:... /// <summary>
/// Handles db connectivity as Dapper assumes an existing connection for all functions
/// Since the app uses three databases, pass in the connection stri...
I have simple SQL string like this:..."SELECT * FROM Office WHERE OfficeId IN @Ids"
...The thing is that the @Ids name is entered in an editor so it could be whatever, and my problem is that if I want to pass in, say an array of integers, it only works w...
Let's say I have a class (simplistic for example) and I want to ensure that the PersonId and Name field is ALWAYS populated....public class Person
{
int PersonId { get; set; }
string Name { get; set; }
string Address { get; set; }
}
...Current...
I'm using ...Dapper... mainly for calling ...stored procedures... in the database ...MSSQL 2008 R2....I do not have classes that map to database tables. Most of the data ends up in ...IEnumerable <Dynamic>... and is transmitted to the grid on the screen..
I have a class:... public class Member
{
#region public property
public int Id { get; set; }
public string LastName { get; set; }
public string FirstName { get; set; }
public string Email { get; set; }
public string Password { g...
I have several kind of a ...Dapper... queries like this below, with several different types as result. This is one specific from these, which produce e.g. List<ClassA> :...string anSql = GetSqlQueryText("query_name");
SqlConnection connection = GetSqlConn...
I was trying dapper orm and recently they added asyncquery support. I googled it about that. It is wonderful if you have heavy traffic on your site. I was trying that with postgressql and dapper. Now, in connection if I am passing simple connection string...
I use ...VS2012... and ...SQL Server 2012...I add ...Dapper... to my ...VS2012... like this...I have one class like this :... public class DomainClass
{
public SexEnum sex { get; set; }
public int Id { get; set; }
public str...
I'm looking to swap some EF code-first db requests for Dapper to speed up some sluggish parts of our Web site. I've only just started experimenting, and Dapper seems fine....I've successfully converted some code to use the .Query extension. But now I'm tr...
I am using dapper to add multiple new students in one db hit using this method:...db.ExecuteAsync(@"INSERT Student(Name,Age) values (@Name,@Age)",
students.Select(s => new { Name = s.Name, Age = s.Age })
);
...But the problem I don't have the new ids. ...
I have a Dapper query as follows...Public void GetAllCusomers(string CustmoerId, StringFirstName, String LastName, String Gender)
{
TblCustomer tblCustomer = new TblCustomer();
using (var sqlConnection = new SqlConnection(“Database...
I need to upload ecommerce catalog data by reading data from multiple tabs And insert those data in SQL server tables....Whats best way to implement the same using c# and dapper .net and SQL server....Thanks
Rakesh
I need to import millions of records in multiple sql server relational tables....TableA(Aid(pk),Name,Color)----return id using scope identity
TableB(Bid,Aid(fk),Name)---Here we need to insert Aid(pk) which we got using scocpe Identity
...How I can do bul...
As we know Ms Sql 2000 does not support MultipleActiveResultSets....Can i use Dapper with async Task without exceptions :..."There is already an open DataReader associated with this Command which must be closed first."...My code example...private async vo...