Saturday, 31 December 2016
Tuesday, 20 December 2016
IQS
1. Difference between
Buld,Rebuild and Clean solution?
Ø Build: This will perform an incremental build. In other words it will
only build code files which have changed. If they have not changed those files
will not be touched.
Ø Re-Build:This will delete all currently compiled files
(i.e., exe and DLLs) and will build everything from scratch, irrespective of if
there is code change in the file or not.
Ø Clean Solution: This menu will delete
all compiled files (i.e., EXE’s and DLL’s) from the bin/obj directory.
Rebuild = Clean +
Build
2. Difference between debug
and realease?
Ø
Debug has extra checking,
extra initialisaton and other features which makes locating problems easier, it
is also not optimised to make debugging make more sense. Because of all of
these settings though, the debug mode version runs at a fraction of the speed
of the release mode.
Ø
Release mode has none of the
initialisation of released mode. Where debug mode allocates memory, sets it to
a value (which is never null, so it is always a good idea to initialise it
yourself anyway) and then gives it to you, release mode just allocates the
memory and gives it to you. Release mode also has none of the extra checking of
debug mode. Finally release mode is optimised. All of these added together
gives a large speed boost over debug mode.
3. Difference between View
data and View bag?
Data
|
ViewBag
|
TempData
|
It is Key-Value Dictionary collection
|
It is a type object
|
It is Key-Value Dictionary collection
|
ViewData is a dictionary object and it is property of
ControllerBase class
|
ViewBag is Dynamic property of ControllerBase class.
|
TempData is a dictionary object and it is property of
controllerBase class.
|
ViewData is Faster than ViewBag
|
ViewBag is slower than ViewData
|
NA
|
Type Conversion code is required while enumerating
|
In depth, ViewBag is used dynamic, so there is no need to type
conversion while enumerating.
|
Type Conversion code is required while enumerating
|
It value become null if redirection is occurred.
|
Same as ViewData
|
TempData is used to pass data between two consecutive requests.
|
It lies only during the current request.
|
Same as ViewData
|
TempData is only work during the current and subsequent
request
|
4. Difference between Throw
and Throw ex?
Ø Throw:
In Throw, the original exception stack trace will be retained. To
keep the original stack trace information, the correct syntax is 'throw'
without specifying an exception.
Ø Throw ex: In Throw ex, the original stack trace
information will get override and you will lose the original exception stack
trace. I.e. 'throw ex' resets the stack trace.
5. Difference between View
and Temptable?
Ø View is just a
definition, it is not storing any data. So every time it is used, it queries
data from the real source table. If the data in source table changes, you will
see the changes from the view as well. In terms of performance, it is not going
to help, maybe worse? BTW, a view exists after the session.
Ø Temp table is really storing the
data, so it faster the performance, but it only exist within the session. And
if the data in source table changes, you won't automatically see the changes
from the temp table unless you re-create it.
6. Difference between
Finalize and Dispose?
Dispose:
Ø It is used to free unmanaged resources like
files, database connections etc. at any time.
Ø Explicitly, it is called by user code and the
class which is implementing dispose method, must has to implement IDisposable
interface.
Ø It belongs to IDisposable interface.
Ø There is no performance costs associated with
Dispose method.
Finalize:
Ø It can be used to free unmanaged resources
(when you implement it) like files, database connections etc. held by an object
before that object is destroyed.
Ø Internally, it is called by Garbage Collector
and cannot be called by user code.
Ø It belongs to Object class.
Ø There is performance costs associated with
Finalize method since it doesn't clean the memory immediately and called by GC
automatically.
7. Page life cycle
8. In which event View
state load?
Ø It's loaded into memory between init and load.
9. What is Preinit?
10. Isolation levels in sql
Ø Following are the different types of
isolations available in SQL Server.
·
READ COMMITTED
·
READ UNCOMMITTED
·
REPEATABLE READ
·
SERIALIZABLE
·
SNAPSHOT
·
11.
CTS?
Thursday, 15 December 2016
iq
ASP.NET MVC
Controller & Actions
View
Razor View Engine
ViewModel & Strongly Typed View
Partial Views
Routes & URLs
HTML Helpers
AJAX Helpers
Data Passing Techniques
ViewModel & Validation
Custom Validation
Bootstrap
Introduction to Bootstrap
Bootstrap Development
LINQ
LINQPad
jQuery
jQuery Selectors
Interacting with DOM
Events Handling
AJAX
Data Modeling Approach
Code First Modeling
Database First Modeling
- Understanding ASP.NET MVC
- ASP.NET VS MVC VS ASP.NET Web Form VS ASP.NET MVC
- ASP.NET MVC Version History
- Understanding Model, View and Controller
- Advantages of ASP.NET MVC
- Design Pattern VS Architectural Pattern
- Layer VS Tier
- MVC pattern VS 3-Tier Architecture
- Understanding Visual Studio ASP.NET MVC Templates
- Creating an ASP.NET MVC project
- Understanding ASP.NET MVC project folder structure
- Understanding configuration files
Controller & Actions
- Understanding Controller
- Creating Controller
- Understanding Actions
- Actions and Non Actions Methods
- Understanding Action Results
View
- Types of Views
- Creating Standard View
- Creating Layout Page
- Communication between Controller and View
Razor View Engine
- Understanding Razor View Engine
- Razor View Engine VS Web Form Engine
- Razor Syntax
- Razor Statements, Loops etc.
ViewModel & Strongly Typed View
- Creating ViewModel
- Creating Strongly Typed View
Partial Views
- Static Partial View
- Dynamic Partial View
Routes & URLs
- Introduction to Routing
- Routing VS Url Rewriting
- Defining Routes
- Route Evaluation
- Attribute Routing
HTML Helpers
- Understanding Html Helpers
- Types of Html Helpers
- Built-In Html Helpers
- Inline Helpers
- Custom Helpers
- Url Helpers
AJAX Helpers
- Introduction to AJAX Helpers
- Using AJAX Helpers
Data Passing Techniques
- ViewData
- ViewBag
- TempData
- Session
- Query String
- Hidden Fields
- Cookies
ViewModel & Validation
- Creating ViewModel
- Understanding ASP.NET MVC Validation
- Need of Server Side and Client Side Validation
- Validation with Data Annotation
Custom Validation
- Custom client side Validation
- Custom Server side validation
Bootstrap
Introduction to Bootstrap
- Introduction to Responsive Design
- Need of Bootstrap
- Bootstrap Fundamentals
- Bootstrap Grid System
Bootstrap Development
- Bootstrap Components
- Header, Footer, Navigation Bar
- Bootstrap Modals
- Bootstrap Form Elements
- Bootstrap Icons
- Typography
- Customizing Bootstrap
- Panels, Sliders, Tooltips
LINQ
- Understanding LINQ
- LINQ - What, Why & When
- Flavors of LINQ
- Advantages of LINQ
- Var Type
- Anonymous Type
- Lambda Expression
- Query Based Syntax and Method Based Syntax
- Deferred Execution
- Immediate Execution
- Deferred/Lazy Loading
- Eager Loading
- LINQ Joins
LINQPad
- What is LINQPad
- Configuring LINQPad
- Querying database using LINQPad
- Testing LINQ query using LINQPad
jQuery
- Introduction to jQuery
- Understanding jQuery
- jQuery - What, Why & When
- JavaScript VS jQuery
- Advantage of jQuery
jQuery Selectors
- What are Selectors
- Types of Selectors
- Using Universal, Element, Class and Id Selectors
- Selecting & Manipulating Html elements
Interacting with DOM
- Get and Set Nodes value, html and text
- Adding and Removing Nodes
- Adding and Removing Classes
- Show, Hide and Empty
Events Handling
- Understanding jQuery Events Methods
- bind(), live(), delegate() and on()
- Choosing appropriate Event methods
AJAX
- Understanding jQuery Ajax
- Making GET and POST Request
- Introduction to Entity Framework
- What is ORM
- ORMs used with .NET
- Understanding Entity Framework
- Advantages of Entity Framework
Data Modeling Approach
- Entity Framework Data Modeling Approach
- Choosing DB First, Model First or Code First
Code First Modeling
- Defining Mapping using Data Annotation
- Defining Mapping using Fluent API
- Entity Framework Code First Migrations
- Updating Database when the Model Changes
- CRUD Operations
- Calling Stored Procedures
- Code First with existing Database
Database First Modeling
- Creating Model from Database
- CRUD Operations
- Updating Model when the Database Changes
- Changing and Updating Mapping
- Calling Stored Procedures
Wednesday, 7 December 2016
IQ
OOPS
- What is Polymorphism & Inheritance ?? where you have implemented in your project.
- Explanation about interfaces? Why do you use interface and what are the uses of interfaces?
- What is Encapsulation & Abstraction???
C#
- What is Generics, Index & garbage collection, explain with the real time scenarios of implementations?
- What are Delegates & Events
- What is memory management & what is memory leak?
- What is LINQ uses and where we can use LINQ.
- How optional parameters will work for you?
- How do you load memory in XML and C#?
- Exception handling
- What is the new version of C# you are working and what are the new features?
- In C# how many types of constructors?
- What is static class? – C#
- What is common type system? .net
Asp.net
·
How do we implement
authentication and authorization? - As.net
· What is meant by view
state? Tell me few scenarios where you used view state? What are the uses of
views?
· About asp.net and new features?
· Page Life Cycle
· State management & Session Management
· User Controls & Master Pages
· What are the Caching techniques in Asp.net???
· MVC life cycle. How MVC send request and
respond?
WCF
- What are the diff varieties of WCF and authentication of WCF?
- What are the different bindings in WCF ?·
Database
- When do we use stored procedures and when do we use functions?
- How we do performance optimization of a Query?
- Indexes, CTE,
- Different relationships
Design patterns
- What is dependency injection and interface injection? - Design Patterns
- What is factory pattern, where you have implemented in your project ??- Design patterns
- What are the different design patterns you have used and explain the same with an example?
Tuesday, 6 December 2016
Getting Hierarchical data
1) Hierarchical Query using a Recursive CTE
The basic syntax structure for a CTE is shown below:
WITH MyCTE AS
(SELECT EmpID, FirstName, LastName,ManagerID
FROM Employee
WHERE ManagerID IS NULL )
SELECT *FROM MyCTE
Using C#.Net
The basic syntax structure for a CTE is shown below:
WITH MyCTE AS
(SELECT EmpID, FirstName, LastName,ManagerID
FROM Employee
WHERE ManagerID IS NULL )
SELECT *FROM MyCTE
Building a Recursive CTE
WITH MyCTE AS
(
SELECT EmpID, FirstName, LastName, ManagerID FROM Employee
WHERE ManagerID IS NULL
UNION ALL
SELECT EmpID, FirstName, LastName, ManagerID
FROM Employee
INNER JOIN MyCTE ON Employee.ManagerID = MyCTE.EmpID WHERE Employee.ManagerID IS NOT NULL
)
SELECT *FROM MyCTE
Using C#.Net
IList<Employee> GetEmployees(Employee manager)
{
var result = new List<Employee>();
var employees = _employeeDb.Employees
.Where(e => e.ManagerEmployeeNumber == manager.EmployeeNumber)
.ToList();
foreach (var employee in employees)
{
result.Add(employee);
result.AddRange(GetEmployees(employee));
}
return result;
}
2) What is SOLID?
SOLID are five basic principles whichhelp to create good software architecture. SOLID is an acronym where:-
- S stands for SRP (Single responsibility principle
- O stands for OCP (Open closed principle)
- L stands for LSP (Liskov substitution principle)
- I stands for ISP ( Interface segregation principle)
- D stands for DIP ( Dependency inversion principle)
- S stands for SRP (Single responsibility principle):- A class should take care of only one responsibility.
- O stands for OCP (Open closed principle):- Extension should be preferred over modification.
- L stands for LSP (Liskov substitution principle):- A parent class object should be able to refer child objects seamlessly during runtime polymorphism.
- I stands for ISP (Interface segregation principle):- Client should not be forced to use a interface if it does not need it.
- D stands for DIP (Dependency inversion principle) :- High level modules should not depend on low level modules but should depend on abstraction.
2)
HTTP | HTTPS |
URL begins with “http://” | URL begins with “https://” |
It uses port 80 for communication | It uses port 443 for communication |
Unsecured | Secured |
Operates at Application Layer | Operates at Transport Layer |
No encryption | Encryption is present |
No certificates required | Certificates require |
Subscribe to:
Posts (Atom)