1. Explain How do we separate business logic while creating an ASP.NET application?
There are two level of asp.net debugging
1. Page level debugging
For this we have to edit the page level debugging enable the trace to true in the line in the html format of the page.
%@ Page Language="vb" trace="true" AutoEventWireup="false" Codebehind="WebForm1.aspx.vb" Inherits="WebApplication2.WebForm1">
2. You can enable the debugging in the application level for this
Edit the following trace value in web.config file
Enable trace enabled=true.
2. Explain What are good ADO.NET object(s) to replace the ADO Recordset object?
The differences includes
In ADO, the in-memory representation of data is the Recordset.
In ADO.net, it is the dataset
A recordset looks like a single table in ADO
In contrast, a dataset is a collection of one or more tables in ADO.net
ADO is designed primarily for connected access
ADO.net the disconnected access to the database is used
In ADO you communicate with the database by making calls to an OLE DB provider.
In ADO.NET you communicate with the database through a data adapter (an OleDbDataAdapter, SqlDataAdapter, OdbcDataAdapter, or OracleDataAdapter object), which makes calls to an OLE DB provider or the APIs provided by the underlying data source.
In ADO you cant update the database from the recordset. ADO.NET the data adapter allows you to control how the changes to the dataset are transmitted to the database
3. Explain What is the .NET datatype that allows the retrieval of data by a unique key?
.Net data type is a type of data. Which is use in query.
Data type as like interger, char, varchar, numeric, money, date etc.
4. Explain similarities and differences between the Java and .NET?
The difference is that java is fully platform independent but .net is not fully independent ant other difference id that some tools of java is more complex compare with .net like setup and deployment.
but java and .net also some similarities that both platform are deploy window and web application and both are use server like IIs and tomcat5.5 .
SELECT count( * ) as totalrecords FROM employee
This will display total records under the name totalrecords in the table employee
use COUNT_BIG
Returns the number of items in a group.
@@ROWCOUNT
Returns the number of rows affected by the last statement.
Use this statement after an SQL select * statement, to retrieve the total number of rows in the table
6. Explain the different types of replication? How are they used?
Replication is used for distributing data and the execution of stored procedures across an enterprise. The replication technology allows you to make duplicate copies of your data, move those copies to different locations, and synchronize the data automatically so that all copies have the same data values.
The different types of replications are
a) transactional replication
b) merge replication
7. Explain What is referential integrity and how can we achieve it?
Referential integrity preserves the defined relationships between tables when records are entered or deleted. In SQL Server, referential integrity is based on relationships between foreign keys and primary keys or between foreign keys and unique keys. Referential integrity ensures that key values are consistent across tables. Such consistency requires that there be no references to nonexistent values and that if a key value changes, all references to it change consistently throughout the database.
We can achieve this by using foreign key.
8. What is differences between ADO and DAO?
DAO- can access only access database
ADO- can access any databases
9. What is differences between Server.Transfer and server.execute method?
Execute method returns control to the page in which it is called once the page specified in the Execute method finishes processing, the Transfer method does not return control to the calling page.
10. Explain the use of trace utility?
Tracing is a very important monitoring and debugging tool for distributed, multitier applications. Such applications often contain problems that can only be observed when the application is under a heavy load and the inherent randomness of a real-life environment. Trace utility allows developers and administrators to monitor the health of applications running in real-life settings.
11. Explain What is the STUFF function and how does it differ from the REPLACE function?
STUFF - It deletes a specified length of characters and inserts another set of characters at a specified starting point. REPLACE -Replaces all occurrences of a specified string value with another string value.
12. Explain What are cursors? Name four type of cursors and when each one would be applied?
Opening a cursor on a result set allows processing the result set one row at a time.
The four API server cursor types supported by SQL Server are:
a) Static cursors
b) Dynamic cursors
c) Forward-only cursors
d) Keyset-driven cursors
13. Explain How many objects are there in ASP?
There are 6 objects in ASP.net
a) Server
b) Session
c) Application
d) ObjectContext
e) Response
f) Request
14. Explain atleast two methods of response object other than Transfer?
a) Response.ClearContent( )
Clears the content of the current output stream.
b) Response.ClearHeaders( )
Clears the HTTP headers from the current output stream.
15. Explain an execution plan? When would you use it? How would you view the execution plan?
The Query Analyzer has a feature called Show Execution Plan. This option allows you to view the execution plan used by SQL Servers Query Optimizer to actually execute the query. This option is available from the Query menu on the main menu of Query Analyzer, and must be turned on before the query is executed. Once the query is executed, the results of the execution plan are displayed in graphical format in a separate window, available from a tab that appears below the query results window on the screen.
16. Explain What is the maximum length of a varchar in SQL Server?
VARCHAR[(n)]
Null-terminated Unicode character string of length n,
with a maximum of 255 characters. If n is not supplied, then 1 is assumed.
17. How to deploy an asp.net application?
We can deploy an ASP.NET Web application using any one of the following three deployment options.
a) Deployment using VS.NET installer
b) Using the Copy Project option in VS .NET
c) XCOPY Deployment
18. Explain atleast three methods of response object other than Redirect?
a) Response.Clear( )
Clears the content of the current output stream.
b) Response.Close( )
Closes the network socket for the current response.
c) Response.End( )
Stops processing the current request and sends all buffered content to the client immediately.
An index
1. is sorted by key values, (that need not be the same as those of the table)
2. is small, has just a few columns of the table.
3. refers for a key value to the right block within the table.
4. speeds up reading a row, when you know the right search arguments.
Whenever you execute a program, the operating system creates a new task for it. The task is like an envelope for the program. It identifies the program with a task number and attaches other bookkeeping information to it.
21. Explain What are the types of cookies are there?
There are two types of cookies
1)Persistance
2)Impersistance
22. What is differences between framework 1.0 and framework 1.1?
1. Native Support for Developing Mobile Web Applications
2. Unified Programming Model for Smart Client Application Development
3. Enable Code Access Security for ASP.NET Applications
4. Native Support for Communicating with ODBC and Oracle Databases
5. Supports for IPv6
Four type of states are as under:
1.Application state
2.Session state
3.Cookie state
4.View state.