Hello,
I am a total noob to web development and am running into some problems. I am trying to search for a specific string, or records that contain a union of strings in a SQL Sever CE database using WebMatrix, and display the results. Ideally, I would like to have a webpage that contains forms where a user can input up to 3 different strings and click a submit button, and then have the results of the search displayed.
The other thing that I would like to do is have another webpage display records within a dynamic date range (i.e. today - 6 months) on load.
I am not even sure where to start with this. I am using the following code to display the columns that I want based on searching the database with a wild card.
@using WebMatrix.Data
@{
var db= Database.Open("Orientation");
var sqlQ = "SELECT * FROM Orientation";
var data = db.Query(sqlQ);
}
<div class="content-box-main">
<ol>
@foreach(var row in data){
<li>
@row.FirstName, @row.LastName, @row.Email
</li>
}
</ol>
</div>