5 items found in the SQL Category

Finding Yesterday in SQL and C#

Monday, July 12, 2010 9:27 PM

C# SQL

Here's something that comes up often in forums - How To Find Yesterday in SQL or C#. Piece of cake, if you know how, but tricky if you don't. And especially tricky to get the right value if you are not clear on the requirement.

Click to read more about Finding Yesterday in SQL and C# ...

Viewed 14994 times

4 Comments for this item

Preventing SQL Injection in ASP.NET

Wednesday, August 19, 2009 7:28 AM

SQL ADO.NET ASP.NET 3.5

I, and many other contributors to the forums at www.asp.net find examples of code posted on a daily basis that are vulnerable to SQL Injection attacks. We continue to exhort beginners (and some more experienced programmers) to code against them. This article examines just how serious a flaw vulnerable coding can be, and what you should do about it.

Click to read more about Preventing SQL Injection in ASP.NET ...

Viewed 122626 times

26 Comments for this item

Sql JOINS and the Sql Server Management Studio Query Designer

Wednesday, November 28, 2007 1:19 PM

SQL SQL Server Express ADO.NET

There are a whole bunch of articles, blog entries and tutorials that seek to explain how SQL JOINS work. Some of them are excellent, and others are just confusing. The reason I am adding my go at trying to clarify JOINS to the mix is to highlight how proper use of the tools available to you can seriously reduce the chances of getting the JOIN syntax or type wrong. Since JOINS are all about how to relate data from one table to another, I thought it appropriate to illustrate the subject using Parents and Children (who may, or may not be related to eachother). So let's meet the families.

Click to read more about Sql JOINS and the Sql Server Management Studio Query Designer ...

Viewed 41136 times

7 Comments for this item

Getting the identity of the most recently added record

Tuesday, June 5, 2007 10:13 PM

SQL SQL Server Express MS Access ADO.NET

The built-in functions @@Identity and Scope_Identity() are designed to retrieve the most recently added record's autoincrement identity value from Access and Sql Server respectively. Here are some usage examples.

Click to read more about Getting the identity of the most recently added record ...

Viewed 286856 times

39 Comments for this item

Insert Single Value With Stored Procedure ASP.NET C#

Tuesday, April 3, 2007 2:16 PM

ASP.NET 2.0 SQL ADO.NET

Code for calling stored procedure in the Code-Behind to insert a single value from a text box.

Click to read more about Insert Single Value With Stored Procedure ASP.NET C# ...

Viewed 32800 times

3 Comments for this item

Recent Comments

Gautam 11/20/2014 8:01 AM
In response to I'm Writing A Book On WebMatrix
Hello Mike, I read your book, loved it! However, I have a few request/suggestions: 1) an example...

Bret Dev 11/19/2014 8:39 PM
In response to The Difference Between @Helpers and @Functions In WebMatrix
Excellent post! One concern - where can you place global @Functions code within an MVC project to Is...

Rob Farquharson 11/19/2014 4:28 PM
In response to iTextSharp - Links and Bookmarks
How can I place text at an absolute position on the page? Also, how can I rotate text?...

Andy 11/17/2014 8:08 PM
In response to MVC 5 with EF 6 in Visual Basic - Sorting, Filtering and Paging
Hello I'm testing your sorting instructions above. This is great and I was able to get it to work...

Gautam 11/17/2014 5:51 PM
In response to WebMatrix - Database Helpers for IN Clauses
Hi Mike, I am very new to programming: In the above example if I want to use a delete button the...

donramon 11/17/2014 3:22 PM
In response to Entity Framework 6 Recipe - Alphabetical Paging In ASP.NET MVC
Congratulations on your new website look and the excellent articles. Thank you!...

Gautam 11/17/2014 11:26 AM
In response to Looking At The WebMatrix WebGrid
Hi Mike, I add the jquery script at the end of my html file.. when ajax attribute is added to the be...

Chet Ripley 11/15/2014 6:57 PM
In response to Adding A New Field
It appears the command is case sensitive. I had the same issue as Cameron. When I changed the to it...

Alvin 11/14/2014 12:49 PM
In response to Razor Web Pages E-Commerce - Adding A Shopping Cart To The Bakery Template Site
Great article Mike! When do you plan to extend the bakery shopping cart beyond this point?...

Gautam 11/14/2014 10:16 AM
In response to Web Pages - Efficient Paging Without The WebGrid
to get the count can we use only the below sql, why to join category and author table var sql =...