What is normalization? What are different types of normalization?
Dec 9th
It is set of rules that have been established to aid in the design of tables that are meant to be connected through relationships. This set of rules is known as Normalization.
Benefits of normalizing your database will include:
- Avoiding repetitive entries
- Reducing required storage space
- Preventing the need to restructure existing tables to accommodate new data.
- Increased speed and flexibility of queries, sorts, and summaries.
Note :- During interview people are expect to answer maximum of three normal forms and that’s what is expected practically. Actually you can normalize database to fifth normal form. But believe this book will answer three normal forms that will More >
What is the difference between htmlentities() and htmlspecialchars()?
Dec 9th
htmlspecialchars() – Convert some special characters to HTML entities (Only the most widely used) htmlentities() – Convert ALL special characters to HTML entities
Will comparison of string “10″ and integer 11 work in PHP?
Dec 9th
Yes, internally PHP will cast everything to the integer type, so numbers 10 and 11 will be compared.
What is the difference between Stored Procedure (SP) and User Defined Function (UDF)?
Dec 9th
Following are some major differences between a stored procedure and user defined functions:-
- UDF can be executed using the “SELECT” clause while SP’s can not be.
- UDF can not be used in XML FOR clause but SP’s can be used.
- UDF does not return output parameters while SP’s return output parameters.
- If there is an error in UDF its stops executing. But in SP’s it just ignores the error and moves to the next statement.
- UDF can not make permanent changes to server environments while SP’s can change some of the server environment.
What is the main difference between MSML and .NET Framework XML classes?
Dec 9th
MSXML supports XMLDOM and SAX parsers while .NET framework XML classes support XML DOM and XML readers and writers.
MSXML supports asynchronous loading and validation while parsing. For instance you can send synchronous and asynchronous calls to a remote URL. But as such there is not direct support of synchronous and asynchronous calls in .NET framework XML. But same can be achieved by using “System.Net” namespaces.
The table tbl_sites contains the following data.
Dec 9th
Userid sitename country
1 sureshbabu indian
2 phpprogrammer andhra
3 php.net usa
4 phptalk.com germany
5 mysql.com usa
6 sureshbabu canada
7 phpbuddy.com pakistan
8. phptalk.com austria
9. phpfreaks.com sourthafrica
10. phpsupport.net russia
11. sureshbabu australia
12. sureshbabu nepal
13. phptalk.com italy
How can we know the number of days between two given dates using MySQL?
Dec 9th
Use DATEDIFF()
SELECT DATEDIFF(NOW(),’2006-07-01′);
What is a void pointer?
Dec 9th
A void pointer is a C convention for a raw address. The compiler has no idea what type of object a void Pointer really points to. If you write int *ip; ip points to an int. If you write void *p; p doesn’t point to a void! In C and C++, any time you need a void pointer, you can use another pointer type. For example, if you have a char*, you can pass it to a function that expects a void*. You don’t even need to cast it. In C (but not in C++), you can use a void* More >
What is a pointer?
Dec 9th
A pointer is a special variable in C language meant just to store address of any other variable or function. Pointer variables unlike ordinary variables cannot be operated with all the arithmetic operations such as ‘*’,'%’ operators. It follows a special arithmetic called as pointer arithmetic.
A pointer is declared as:
int *ap;
int a = 5;
In the above two statements an integer a was declared and initialized to 5. A pointer to an integer with name ap was declared.
Next before ap is used
ap=&a;
This operation would initialize the declared pointer to int. The pointer ap is now said to point to a.
Operations on More >
