Baidu ASP.NET Interview Questions Answers

Baidu Most Frequently Asked Latest ASP.NET Interview Questions Answers

What Is Stored Procedure?

A stored procedure is a named group of SQL statements that have been previously created and stored in the server database. Stored procedures accept input parameters so that a single procedure can be used over the network by several clients using diferent input data and when the procedure is modified, all clients automatically get the new version. Stored procedures reduce network traffic and improve performance. Stored procedures can be used to help ensure the integrity of the database.

E.g: sp_helpdb,sp_renamedb,sp_depends etc.

What Is Trigger?

A trigger is a SQL procedure that initiates an action when an event (INSERT, DELETE or UPDATE) occurs. Triggers are stored in and managed by the DBMS. Triggers are used to maintain the referential integrity of data by changing the data in a systematic fashion. A trigger cannot be called or executed; DBMS automatically fires the trigger as a result of a data modification to the associated table. Triggers can be viewed as similar to stored procedures in that both consist of procedural logic that is stored at the database level. Stored procedures, however, are not event‐drive and are not attached to a specific table as triggers. Stored procedures are explicitly executed by invoking a CALL to the procedure while triggers are implicitly executed. In addition, triggers can also execute stored procedures.

Nested Trigger: A trigger can also contain INSERT, UPDATE and DELETE logic within itself, so when the trigger is fired because of data modification it can also cause another data modification, thereby firing another trigger. A trigger that contains data modification logic within itself is called a nested trigger.

What Is View?

A simple view can be thought of as a subset of a table. It can be used for retrieving data, as well as updating or deleting rows. Rows updated or deleted in the view are updated or deleted in the table  when the view was created. It should also be noted that as data in the original table changes, so does data in the view, as views are the way to look at part of the original table. The results of using a view are not permanently stored in the database. The data accessed through a view is actually constructed using standard T‐SQL select command and can come from one to many different base tables or even other views.
Baidu Most Frequently Asked Latest ASP.NET Interview Questions Answers
Baidu Most Frequently Asked Latest ASP.NET Interview Questions Answers

What Is Index?


An index is a physical structure containing pointers to the data. Indices are created in an existing table to locate rows more quickly and efficiently. It is possible to create an index on one or more columns of a table, and each index is given a name. The users cannot see the indexes; they are just used to speed up queries. Effective indexes are one of the best ways to improve performance in a database application. A table scan happens when there is no index available to help a query. In a table scan SQL Server examines every row in the table to satisfy the query results. Table scans are sometimes unavoidable, but on large tables, scans have a terrific impact on performance.

How Do You Create A Permanent Cookie?

If you are developing web services and the cookies need to be travelled across multiple requests, then it need to have permanent or persistant cookie. In order to do this, you have to set  your webserivce CookieContainer to a newly created Cookie Container, and set  its cookie to a session value and then store the cookie(s) into the Service CookieCollection from that cookie container if something is there otherwise add cookie to the container.

What Tag Do You Use To Add A Hyperlink Column To The Datagrid?

HyperLinkColumn.

What Is The Standard You Use To Wrap Up A Call To A Web Service?

SOAP.

Which Method Do You Use To Redirect The User To Another Page Without Performing A Round Trip To The Client?

Server.Transfer.

Response.Redirect also does that but it requires round trip between client and server.

A Web Service Can Only Be Written In .net?

False.

What Property Do You Have To Set To Tell The Grid Which Page To Go When Using The Pager Object?

CurrentPageIndex.

You need to set this one with the DataGridPageChangedEventArgs' NewPageIndex.

Why Would You Use An Array Vs Linked-list ?

Linked List

They allow a new element to be inserted or deleted at any position in a constant number of operations (changing some references) O(1).
Easy to delete a node (as it only has to rearrange the links to the different nodes)., O(1).
To find the nth node, will need to recurse through the list till it finds [linked lists allow only sequential access to elements. ], O(n)
Array

Insertion or deletion of element at any position require a linear (O(n)) number of operations.
Poor at deleting nodes (or elements) as it cannot remove one node without individually shifting all the elements up the list by one., O(n)
Poor at inserting as an array will eventually either fill up or need to be resized, an expensive operation that may not even be possible if memory is fragmented. Similarly, an array from which many elements are removed may become wastefully empty or need to be made smaller, O(n)
easy to find the nth element in the array by directly referencing them by their position in the array.[ arrays allow random access ] , O(1)

What I Need To Create And Run An Asp.net Application?

Windows 2000, Windows Server 2003 or Windows XP.

ASP.NET, which can be either the redistributable (included in the .NET SDK) or Visual Studio .NET.

Are There Any Free Ides For The .net Sdk?

Microsoft provides Visual Studio 2005 Express Edition Beta for free. Of particular interest to the ASP.NET developers would be the Visual Web Developer 2005 Express Edition Beta 2 available as a free download.

The ASP.NET Web Matrix Project (supported by Microsoft) is a free IDE for developing ASP.NET applications and is available here.

There is also a free open-source UNIX version of the Microsoft .NET development platform called Mono available for download here.

Another increasingly popular Open Source Development Environment for .NET is the #develop (short for SharpDevelop) available for download here.

Where Can I Download The .net Sdk?

.NET SDK can be obtained here.

(You have to install the Microsoft .NET Framework Version 1.1 Redistributable Package before installing the .NET SDK.)

When Was Asp.net Released?

ASP.NET is a part of the .NET framework which was released as a software platform in 2002.

Is A New Version Coming Up?

ASP.NET 2.0, Visual Studio 2005 (Whidbey), Visual Web Developer 2005 Express Edition are the next releases of Microsoft's Web platform and tools. They have already been released as Beta versions. They are scheduled to be released in the week of November 7, 2005.

Explain Namespace?

Namespaces are logical groupings of names used within a program. There may be multiple namespaces in a single application code, grouped based on the identifier's use. The name of any given identifier must appear only once in its namespace.

List The Types Of Authentication Supported By Asp.net?

Windows(default),
Forms,
Passport,
None(Security disabled).

What Is Clr?

Common Language Runtime (CLR) is a run-time environment that manages the execution of .NET code and provides services like memory management, debugging, security, etc. The CLR is also known as Virtual Execution System (VES).

What Is Cli?

The CLI is a set of specifications for a runtime environment, including a common type system, base class library, and a machine-independent intermediate code known as the Common Intermediate Language (CIL). (Source: Wikipedia).

List The Various Stages Of Page-load Lifecycle?

Init(),
Load(),
PreRender(),
Unload().

Explain Assembly And Manifest?

An assembly is a collection of one or more files and one of them (DLL or EXE) contains a special metadata called Assembly Manifest. The manifest is stored as binary data and contains details like versioning requirements for the assembly, the author, security permissions, and list of files forming the assembly. An assembly is created whenever a DLL is built. The manifest can be viewed programmatically by making use of classes from the System. Reflection namespace. The tool Intermediate Language Disassembler (ILDASM) can be used for this purpose. It can be launched from the command prompt or via Start> Run.

What Is Shadow Copy?

In order to replace a COM component on a live dedicated server, it was necessary to stop the entire website, copy the new files and then restart the website. This is not feasible for the web servers that need to be always running. .NET components are different. They can be overwritten at any time using a mechanism called Shadow Copy. It prevents the Portable Executable (PE) files like DLLs and EXE's from being locked. Whenever new versions of the PE's are released, they are automatically detected by the CLR and the changed components will be automatically loaded. They will be used to process all new requests not currently executing, while the older version still runs the currently executing requests. By bleeding out the older version, the update is completed.

What Is Dll Hell?

DLL hell is the problem that occurs when an installation of a newer application might break or hinder other applications as newer DLLs are copied into the system and the older applications do not support or are not compatible with them, .NET overcomes this problem by supporting multiple versions of an assembly at any given time. This is also called side-by-side component versioning.

Explain Web Services?

Web services are programmable business logic components that provide access to functionality through the Internet. Standard protocols like HTTP can be used to access them. Web services are based on the Simple Object Access Protocol (SOAP), which is an application of XML. Web services are given the .asmx extension.

Post a Comment

Previous Post Next Post