Questions tagged [simple.data]

Simple.Data is a lightweight framework that uses the dynamic features of .NET 4 to provide an expressive, ORM-ish way of accessing and manipulating data without any of the code pre-generation and boilerplate required by other frameworks.

Simple.Data is a lightweight framework that uses the dynamic features of .NET 4 to provide an expressive, ORM-ish way of accessing and manipulating data without any of the code pre-generation and boilerplate required by other frameworks. Instead, it interprets method and property names at runtime and maps them to your underlying data-store using a convention-based approach.

128 questions
0
votes
1 answer

Simple.data and Connection closing

I am using simple.data with oracle managed data access . https://github.com/SimonH/Simple.Data.Oracle Currently there are too many connections are open and it is not closed properly in the server. Would like to how to close the same .
satish
  • 2,425
  • 3
  • 23
  • 40
0
votes
2 answers

Filter by column from joined table

I've recently started using Simple.Data as my ORM. i've approached a problem with filtering by column from joined table. My query looks like this: var candidates = db.dbo.Candidates .FindAllBy(CommonOfferId: commonOfferId, CandidateId:…
Paweł Reszka
  • 1,557
  • 4
  • 20
  • 41
0
votes
1 answer

Simulate Subquery in Simple.Data?

It is my understanding after extensive research that you cannot do sub-queries in Simple.Data. However, with enough joins and sorts, I have occasionally seen a CTE pop out, which would serve my purposes. I have created a fiddle to demonstrate what…
Jaime Torres
  • 10,365
  • 1
  • 48
  • 56
0
votes
1 answer

Simple.Data Eager Load SimpleQuery object

It appears that Simple.Data will lazy load by default. I simply want Simple.Data to query the database and put the results in an object. For example, as soon as this piece of code is executed the results from the database should be stored in…
MrWhippy
  • 15
  • 4
0
votes
1 answer

Simple.Data System Stored Procedure does not execute

I have a simple Simple.Data connection to my database on which I want to execute the System Stored Procedure named sys.sp_MSforeachtable. (I am connecting as the database 'sa' user) My code looks like the following: var emx =…
Redeemed1
  • 3,953
  • 8
  • 38
  • 63
0
votes
1 answer

Problems with connection pool using Simple Data

I'm facing a very difficult problem with a web a application that I'am implementing with a group of developers. We are using Simple Data to connect to a Oracle database but after several connection or when we have a lot of users the connection pool…
user2773247
  • 13
  • 1
  • 4
0
votes
1 answer

Simple.Data - Primary Key Mapping

i'm using Simple.Data and I have a question about. I have the following classes: public abstract class User { public int Id { get; set; } public string Username { get; set; } public string Password { get; set; } public string Salt {…
0
votes
1 answer

Delete From Table Where Column "In" range - Simple.Data

I'm using Simple.Data as my Micro-ORM and I want to achieve something which may or may not be possible.. I want to do a delete on a table where one of the columns matches a list of variables, so effectively the SQL would be something like: DELETE…
MartinM
  • 1,736
  • 5
  • 20
  • 33
0
votes
1 answer

Pass table parameter to stored procedure with Simple.Data

I want to pass a list of Ids to a stored procedure using Simple.Data. My stored procedure is... CREATE TYPE IntValue AS TABLE (Value INT) GO CREATE PROCEDURE testTableSproc @items IntValue READONLY AS SELECT * FROM @items So far I've…
perfectionist
  • 4,256
  • 1
  • 23
  • 34
0
votes
1 answer

How eagerload Multilevel hierarchy with Simple.Data?

I was wondering if it was possible to select/build a multilevel object hierarchy in one single query? As I'm not sure about the terminology, I'll give an example: Let's say we have a Product, which has one Subrange, which has one Range, which has…
IronSlug
  • 492
  • 3
  • 15
0
votes
3 answers

Is it possible to invoke a SQL function like GETDATE() when inserting or updating via Simple.Data?

For overall data consistency, I generally I prefer storing the current datetime for new/updated records with the current time on the database server, as it may not be in sync with the invoking server (and if using multiple web servers, they may also…
pdwetz
  • 841
  • 1
  • 9
  • 19
0
votes
0 answers

Having dictionary as property in POCO throws a casting error in Simple.Data. Does not get initialized as null

When a POCO has a dictionary a casting error will be thrown. Lists and other scalar properties not contained in the query will be initialized with their defaults values (Lists are correctly initialized as null) but Dictionaries…
Diego
  • 998
  • 1
  • 11
  • 20
0
votes
1 answer

Simple.data how to get the last id in a record

I have to check a set of records with an id structure using simple.data. is there a way where i can find the last id entered? in reg sql i would do something like select top 1 of something desc but i am unsure of how to do it with…
ghostfly
  • 3
  • 3
0
votes
1 answer

MiniProfiler with Simple.Data and SQLServer Database

I am working on a project which use miniprofiler (3.0.10) with Simple.Data and SqlServer database. Please could anyone point me to use miniprofiler to log sql query details by amending below code sample which used with MySql. var db =…
DSR
  • 4,588
  • 29
  • 28
0
votes
0 answers

How can i check if a record exists using simple.data and c#

Problem: I have to check whether or not a record exists in a join and if not ignore that user but still load all the other information for that user var db = Simple.Data.Database.OpenNamedConnection("sqlConn"); 02 03 var expr1 =…
ghostfly
  • 3
  • 3
1 2 3
8 9