Wednesday, February 11, 2015

How to Connect MongoDB server with PHP

 Requirements :

  1. Basic Knowledge of MongoDB
  2. MongoDB Server
  3. PHP driver for MongoDB

Start the server:

1.In windows, go to cmd and navigate to bin folder in mongodb    
  installation location.
2.Execute " mongod " command to start the server.

      If you haven't installed mongodb server before.check my videos MongoDB installation in windows  and php driver setup for mongodb

code:

Explanation :

          $connection=new MongoClient();
                    MongoClient()  by default creats a connection to server at localhost:27017.If you want to create a connection to remote server then you can specify it as arguments.

     $db=$connection->university;
     This piece of code selects the database named university.If the database haven't created before,mongodb will automaticaly creates a databse. 


$student_collection= $db->student;
       same as above line,but this line creats (if first time ) and also selects collection(table in RDMS) named student.you dont have to specify any schema ,mongodb has dynamic schema feature.
  
     Finally,create an array with required fields.Insert created array (document) in to collection using insert() function.

Video Tutorial


Wednesday, February 4, 2015

How to Clear Written Exam for Interviews

                Without any doubt, Interview is an important aspect in each and every student life.Thorough preparation is must and should to clear an interview.But the point is how to prepare.? what to prepare..?.Well , Each and Every company has their own method of selection process. Some companies expect  you to write complex algorithms whereas some companies concentrate on your basic skills.No mater  which company you are attending,these are few concepts you must know (for IT companies).

                          
                               


1. Basic Arithmetic

                            You should revise your good old school days math problems.Concentrate more on basic skills like percentage,profit and loss, LCM and HCF , Problems on trains , Average ,simple and compound interest ,Logarithms etc. Have a basic knowledge on each and every above mentioned concepts.

    online preparation : IndianBix
   Ebook : Quantitative Aptitude By R.S Aggarwal

2.Verbal Ability         

                   Must necessary skill for every company. Don't confuse communicative skills with verbal ability. some people may be good at communication but they may not posses verbal skills. Though its not possible to learn vocabulary  with in weeks, you can still give it a try. If you have strong English background and if you are really good at grammar,vocabulary then you concentrate on other sections.

3.Logical Reasoning                     

                      Pretty much easy section if you are little bit intelligent. Relationships, Directions, Deductions, Series..etc  comes under this section. Key thing in this area is to answer as quickly as possible. Fastness and Accuracy comes with practice.So i suggest you to practice this section as much as you can.

4.Knowledge on Core Concepts

                                         Some companies may add core concepts question as last section. If you are attending IT companies then make sure you have sound knowledge on Pointers, Data Structures ,Data Base, Algorithms. Depth of preparation may depends on company you are attending. Some big companies like flipkart, eBay concentrates more on data structures and algorithms.I suggest you to go through previous papers of respective company before starting preparation.



Tips : 

  1. Do not neglect any section.Most of the companies maintain sectional cut-offs which means if you don't qualify in any single section then you wont qualify the written round.
  2. Take Mock online tests and track the performance.Concentrate more on areas you are lagging.
  3. Fastness and Accuracy is the key point rather than just answering.
  4. While writing exam don't just stick to a single question for longer time.If you feel particular question is killing time then better go for next question.
  5. ......... Practice Practice Practice...........

 

© 2013 YRR Help. All rights resevered. Designed by Templateism

Back To Top