Skip to main content

Posts

Showing posts with the label QUESTIONS

What is the difference between Array and Array List ? Explain in brief with example.

Array contain a similar data type and array size is fixed i.e dynamically its size can't be changed. but arraylist can store more then one data type and its size can be changed dynamically. one major difference is that,array used to store primitive data type(i.e. int,char etc) while arraylist is used to store objects. rajesh saxena Mar 25, 2011 Array is fixed length,array-list is growing array(means they have no fixed length , if u add more the size arraylist size incress and vise versa) seond one: if add and remove the elements in the middle takes more time by using arrylist in that time use linkedlist arrylist is good for retiveing the elements in specific position arraylist is faster than linkedlist for random accesing of elemnets

What is the difference between UNION and UNION ALL?

UNION The UNION command is used to select related information from two tables, much like the JOIN command. However, when using the UNION command all selected columns need to be of the same data type. With UNION, only distinct values are selected. UNION ALL The UNION ALL command is equal to the UNION command, except that UNION ALL selects all values. The difference between Union and Union all is that Union all will not eliminate duplicate rows, instead it just pulls all rows from all tables fitting your query specifics and combines them into a table