Quantcast
Channel: ADO.NET, Entity Framework, LINQ to SQL, NHibernate
Browsing all 1698 articles
Browse latest View live

CRUD on Entity Framewok

I want to do crud operations on entititiy objects using a Gridviews events,.. Row Updating event, Row Deleting event etc, Thanks !!!

View Article


How to perform outer join in entity framework

How can I perform a left outer join on two tables using entity framework? Below I can easily perform an inner join. Yet I have not a clue how to perform an outer join?     IEnumerable<TheList>...

View Article


Why we do not have CommandType.UserDefinedFunction in ADO.NET?

Hi, Please can anybody have any idea why there is no CommandType.UserDefinedFunction in ADO.Net, though UDF's can be executed in other ways from .NET that is from SP or text. Thanks Vikas Khanna  

View Article

Gridview disappears on paging

I thought I would be worth a try to ask this one more time. Especially since my understanding of what is causing the problem has increased. Although I still dont have the solution. I am using the code...

View Article

Display all records before filtering from dropdown menu

I have a EntityDataSource object connected to a data source that displays all the records in a table when viewed in a browser. When I add a dropdownlist to the page and use the QueryExtender to connect...

View Article


How do I delete in entity framework, and also perform a rollback in case of a...

Using entity framework, I need to delete records from a single table based upon a unique column Id. I have alot of data which I need to update in a single database table. Really it makes more sense for...

View Article

Sum of values of datatable columns.

Hi Experts,Which is the best way to get sum of values in columns of a datatable, other than looping by each row? I need to get like this.. color          men       women red           10            15...

View Article

Connecting to a new connection string using entity framework dynamically.

Hi all, Does anyone knows how to connect to a new database connection for every user using entity framework? I've a one database whcih authenticates all the users to my application. After...

View Article


Compare a database field to today's date

var qryProjectsDueToday = from p in db.projects where p.need_date = ????? (I want today''s date) orderby p.project_id descending select p; it doesn't like anything I try to put in there! How do I...

View Article


Save only that field change (Code First)

Hi Please help. me, I have a MVC 3 application, this is the scenario Model Public Class Person { public string PersonID { get; set; } public string LastName { get; set; } public string FirstName { get;...

View Article

Sql to Linq - Is this possible?

I'm trying to convert this sql to a linq query: select SystemReleases.SystemReleasesID, SystemReleases.ReleaseTitle, SystemReleases.Created, SystemReleases.CreatedBy, statuss.ReleaseStageValue from...

View Article

Date comparison using dynamic linq

I have a generic method which takes the query (where clause) as string e.g.  user.AsQueryable().Where( " UserName == \"xx\" AND Age = 12  "  ); When i add datetime value to it the method fails. It...

View Article

Combine multiple column into one column

Hi, I am trying to display multiple column into single column as below: Name1 | Address1  Name2 | Address2 Name3 | Address3 Result: Name1 Address1 Name2 Address2 Name3 Address3 Any idea?

View Article


Linq to SQL query and SQL query return diffrent results

I try the same SQL question on two diffrent ways and I get diffrent results.The first way is SQL view in Visual Studio SELECT DISTINCT ruleValueFROM rulesWHERE (ruleValue LIKE '%ORG%') and the second...

View Article

NullReference Error in data acces

Hello, I'm trying to solve this problem for days but I can't figure out where i'm going wrong. I have written two classes to retrieve data from a SQL Server database; ContentDB.vb and...

View Article


Linked Server in SQL Server 2008?

How can you connect to a linked Server in SQL Server 2008?  I am able to connect to a SQLite and SQL Server database but in this instance I need to be able to connect to a Linked Server.  Is there any...

View Article

Insert values into two tables with identity

Hi all, I looked around the net for an example but I am not getting much.  What I need to do is insert into two different tables in my 2008 SQL databse. Insert 1 will save data into table #1 using...

View Article


Any way to set pluralization for a single table in Linq?

This is getting kind of irritating.  I have a table named "Status".  Every time I make a change to the dbml, I have to also go into the .designer.cs and make sure I manually update the name of the...

View Article

Image may be NSFW.
Clik here to view.

EF Code First generating duplicate index names for base class

PREFACE: I think this is a bug in the EF code base but I'm open to suggestions for a change in my model as well. The Error: When EF Code First attempts to build my model, I get the exception: The...

View Article

EF: Invalid object name 'dbo.Users'

Hi guys.  I'm having some trouble using the Entity Framework and was hoping someone has seen this.  I've been all over Google, but nothing has worked.  I feel like it must be some kind of configuration...

View Article
Browsing all 1698 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>