I have a WPF application (using MVVM pattern) that allows users to perform a search for a record/records based on their selection choices and entries into the different UI controls (TextBox, CheckBox, RadioButton, DatePicker, TimerPicker,etc). It does this by retrieving information from an Acces...
The way I have it implemented now it takes on average 5 to 15 seconds (just like you said) to find the record.
See another problem is that new records come in all the time. It's not like I can just load in the data in the background as the program is starting up and then filter though it. Each time a user runs a query, there could be several new records added or deleted prior to the query.
if (!String.IsNullOrWhiteSpace(EmployeeId))
{
if (!String.IsNullOrWhiteSpace(query.ToString()))
{
query.Append(" AND ");
}
query.Append("Employee_ID LIKE '%" + EmployeeId + "%'");
}
in ur above code why don't u add "AND" with the condition
like this
if (!String.IsNullOrWhiteSpace(EmployeeId))
{
query.Append(" AND Employee_ID LIKE '%" + EmployeeId + "%'");
}
Tested out your suggestion. It works and it shortened my code. :)
Thank you.
Something I was told on another chat, though, which I have not considered, is SQL injections, so that'll be one of the things I'll have to adjust for. Almost considering learning Entity Framework..
Dynamically changing searches based on the given parameters is a complicated subject and doing it one way over another, even with only a very slight difference, can have massive performance implications. The key is to use an index, ignore compact code, ignore worrying about repeating code, you m...
I am using NPOI dll for genrating excel sheet in C#. When I apply formula on some cell programmatically and export excel then in protected mode of excel sheet all the cells having formula show '0' value. but when i edit this excel all formulas work properly on those cell.
Is there any solution f...
hello there, can any one tell me the solution for my problem?? my problem is i cant able to start cmd prompt in c# after i hosted on IIS. should it be any permission Issue??