Difference between MSDE and SQL Server 2000

MSDE(Microsoft Desktop Engine):

MSDE is a cut down version of the SQL SERVER database and free, redistributable software.

Differences:

A.Size:

In MSDE database size limited to 2GB.
In SQL Server database size limited to 1,048,516 TB1(1 Billion GB).

B.Performance:

Performance of MSDE degrades when maximum number of concurrent operations greater then or equal to 8. Performance degradation is implemented with the help of SQL SERVER 2000 workload governor.

In SQL SERVER 2000, possible number of concurrent connections are 32,767.

C.OLAP and Data warehousing:

MSDE does not provide OLAP and Data warehousing capabilities.

D.Mail:

MSDE does not have support facility for SQL mail.

E.Administrative Tools:

MSDE doesn't have its own administrative tools. There are many third party tools, which provide administrative capability GUI.

SQL Server have administrative tools such as enterprise manager, Query analyzer or Profiler.

Ref : www.codeproject.com/

How to Filter Window Message in .NET

Message Filter:

Message filter to prevent specific events from being raised to the control or Forms.

We can achieve the Message Filter through IMessageFilter Interface. It has overridable method name PreMessageFilter.Using this method we can customize our Message Filters.

Example : Filter/Restrict left mouse button down message

public class MyMsgFilter : IMessageFilter
{
public bool PreFilterMessage(ref Message m)
{
// Filter/Restrict left mouse button down message.
if (m.Msg == 513)
{
return true;
}
return false;
}
}

In order to monitor the Message Filter in our application you must register Filter class in your application.

public class mainForm : System.Windows.Forms.Form
{
private MyMsgFilter msgFilter = new MyMsgFilter();
public mainForm()
{
// Add message filter.
Application.AddMessageFilter(msgFilter);
}
}

Following way you can remove your Message Filter
Application.RemoveMessageFilter(msgFilter);

JavaScript document.getElementById

If you want to quickly access the value of an HTML input give it an id to make your life a lot easier.
This small script below will check to see if there is any text in the text field "myText". The argument that getElementById requires is the id of the HTML element you wish to utilize



<script defer="defer" type="text/javascript">

function notEmpty()

{

var myTextField = document.getElementById('myText');

if(myTextField.value != "")

alert("You entered: " + myTextField.value)

else

alert("Would you please enter some text?")

}

</script>

<input type='text' id='myText' />

<input type='button' onclick='notEmpty()' value='Form Checker' />





Difference between Abstraction and Encapsulation

Abstraction:

It is virtual class design.
Representation of data that how we represent it.
Before actually defining class developer will think about about the properties, methods and events will be there in class.

Encapsulation:

Hiding of unnecessary data.
At the time of class definition developers will think about which should display to end user and which should not.

Conclusion:
Abstraction is collection of data and Encapsulation is exposure of data in appropriate access specifier.

Difference between Rule and Check Constraint

Check Constraint:

Check constraint is associated with columns in a Table. So these can't be re-used.

Suppose if "Emp" table having the coulmn "Salary" then
alter table Emp add constraint ck_op Check (Salary between 15000 and 45000)

Rule:

Rules are defined with in a database and can be applied to any number of columns.
Creating Rule:
CREATE RULE SAL_RANGE
as
@Sal > 15000 and @Sal > 45000
Binding Rule to a Column:
SP_BINDRULE 'SAL_RANGE','Emp.Salary'