zzz projects Dapper Tutorial
Getting Started Documentation 3rd Party Libraries Knowledge Base Online Examples
  • Getting Started
  • Documentation
  • 3rd Party Libraries
  • Knowledge Base
  • Online Examples
  •   Download  

Dapper Tutorial - Knowledge Base (KB)

79 results for: in tag: dapper-extensions

Why can't I set "this" to a value in C#?

I am using Dapper.net Extensions and I would like to be able to retrieve a Photo object and set 'this' to it without having to set each property individually. What would be the best way to accomplish this? In the code below it says I cannot assign to 'th...
c# dapper dapper-extensions
asked by Greg Rogoszewski

How to ignore a class property using Dapper.net Extensions?

I am using Dapper.net Extensions and would like to ignore certain properties without having to write a complete custom mapper. As you can see in the ClassMapper below there is a lot of redundant code when all I really want to do is ignore one property. ...
c# dapper dapper-extensions
asked by Greg Rogoszewski

dapper map one to one in classmapper

I have 2 simple tables....create table Owner ( Id int primary key, Name nvarchar(100), ); create table Status ( Id int primary key, BrandName nvarchar(50) OwnerId int foreign key references Owner(Id), ); ...In app I map these tables t...
dapper dapper-extensions foreign-keys relation
asked by imodin

dapper GetList(predicate) vs Query(sql condition)

In ...dapper... I can get data with ...Query<Person>("sql condition"). ...and I can do with ...dapper extensions...GetList<Person>(predicate) ...Both return an IEnumerable ...Which approach should I choose for which situation?...As the extensions library...
dapper dapper-extensions
asked by Elisabeth

Ignore property on model property

How can I ignore a property on my model using dapper/dapper extensions/dapper rainbow or any ...of those dapper libraries?
dapper dapper-extensions dapper-rainbow
asked by Elisabeth

Do not update a certain property on Update method with dapper extensions

I know I can use the pure dapper to build my update string with only the properties I want to update (whitelist)....What I want is to keep the ORM style of dapper extensions:...con.Update<Person>(person); ...I want that some properties of person are not u...
dapper dapper-extensions
asked by Elisabeth

Dapper Extensions Change Schema

I am using Dapper Extensions to do some simple CRUD operations on a DB. My problem is that the tables I am using are held in a different schema to dbo. Is there a way to choose the schema at the dapper extensions level?...or...Should this be dealt with vi...
dapper dapper-extensions
asked by Mathew Padley

I needed to do Bulk insert with dapper rainbow

I am using the dapper rainbow database.cs extensions,...private void insertList(IEnumerable<myObject> list) { using (SqlConnection conn = new SqlConnection(connectionString)) { var db = myDB.Init(conn, commandTimeout: 100...
.net c# dapper dapper-extensions dapper-rainbow
asked by WingMan20-10

Map SQL columns in SqlMapper.Query<T1,T2,TReturn> to class properties

First I do not have much experience with dapper.net and maybe this problem has simple solution....I would like use multi mapping features....I simplified my problem....I have 2 tables....First table ...CARS...Columns:...CARD_ID (PK)...CAR_LOCATION...CAR_S...
dapper dapper-extensions join mapping
asked by trust in wpf

Dapper insert into table that has a composite PK

I have a table that has a primary key composed of two columns, neither of which are auto-incrementing, and my Dapper insert (part of Dapper Extensions) is failing on the insert saying that the first of the two columns does not allow a null, even tho the v...
c# dapper dapper-extensions primary-key
asked by Ian Davis

Dapper CRUD with GUID Ids

I'm pretty new to Dapper and Dapper.SimpleCRUD (...https://github.com/ericdc1/Dapper.SimpleCRUD...) so please excuse if I'm being a bit dense. I have an existing database that uses GUID Ids (primary keys) rather than auto incremented int Ids. It seems tha...
dapper dapper-extensions orm
asked by Mark Chidlow

Dapper.Contrib Generate Update Script With ROWLOCK

I am using Dapper as ORM and generating insert,update script by Dapper.Contrib extensions. I want to generate Update script include Rowlock. Is there any usage except changing generic code below in SqlMapperExtensions.... public static bool Update<T>(thi...
c# dapper dapper-extensions
asked by trcn

Using Dapper Extensions, can IDs be retrieved when inserting IEnumerable<T>

If an object is inserted 1 at a time, then the Id can be fetched from the object:...foreach (var object in objectList) { conn.Insert(object); int id = object.Id; // Returns Id as expected } ...However, if an IEnumerable of objects is inserted, the...
.net c# dapper dapper-extensions
asked by Kevin Crowell

Dapper.Net and the DataReader

I have a very strange error with dapper: ...there is already an open DataReader associated with this Command which must be closed first...But I don't use DataReader! I just call select query on my server application and take first result:... //How I ...
.net dapper dapper-extensions exception sql
asked by user3820606

How do you include an object that has a generic list property and a reference type property in dapper?

my class is:...public class Person { public int Id { get; set; } public string Name { get; set; } public List<Address> Addresses { get; set; } public BankAccount Account { get; set; } } public class Address { public string Street { g...
c# dapper dapper-extensions
asked by John Patrick Po

Dapper.Tvp Assembly is does not have a strong Name

Recently I was working with Dapper.Net and it is awesome so far for dynamic object manipulations with sql, Great work by Dapper team....But there is a need to have bulk insert and update and i used table valued parameter which is better in terms of perfor...
dapper dapper-extensions nuget sql table-valued-parameters
asked by Husni Jabir

Dapper QueryMultiple Stored Procedures w/o mapping to Objects

With dapper, I can do batch execute for Stored Procedures, something similar to:...connection.Execute(@" exec sp1 @i = @one, @y = @two exec sp2 @i = @three", new { one = 1, two = 2, three = 3 }); ...However, the only means of retrieving data that I...
dapper dapper-extensions tsql
asked by Bill

Dapper c# Inner join

Hi Im trying do that query in dapper, but the list contatos return with the values null for my class Client, i don't know what i doing wrong. my class Clt_cadCliente is one Client has several contact (clt_cadContatos). Help please....var lookup = new Dict...
c# dapper dapper-extensions
asked by Diego Germano

Dapper - Bulk insert of new items and get back new IDs

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. ...
bulkinsert c#-4.0 dapper dapper-extensions sql
asked by Yaron Levi

DapperExtensions produces "Invalid object name" on insert operation

I'm following the Simple Insert Operation example at ...https://github.com/tmsmith/Dapper-Extensions#simple-insert-operation...public class Org { public int Id { get; set; } public string Name { get; set; } } SqlConnection conn = new SqlConnectio...
c# dapper dapper-extensions entity-framework sql-server
asked by epalm

Page 1 of 4
  • 1
  • 2
  • 3
  • 4
  • ยป

Prime Library

Performance

  • Entity Framework Extensions
  • Entity Framework Classic
  • Bulk Operations
  • Dapper Plus

Expression Evaluator

  • C# Eval Expression
  • SQL Eval Function
More Projects...