Posts

What is MappedSuperClass in hibernate ?

Image
MapperSuperClass ·         A mapped superclass has no separate table defined for it. ·         Designates a class whose mapping information is applied to the entities that inherit from it.  ·         A class designated with the  MappedSuperclass  annotation can be mapped in the same way as an entity except that the mappings will apply only to its subclasses since no table exists for the mapped superclass itself.  ·         When applied to the subclasses the inherited mappings will apply in the context of the subclass tables.  ·         Mapping information may be overridden in such subclasses by using the  AttributeOverride  and  AssociationOverride  annotations or corresponding XML elements. ·         It avoids the cod...

MongoDB basic Overview

Overview MongoDB is a cross-platform, documented oriented database and it is not based on schema like relational database. It uses dynamic schema and stores data in JSON format. It provides high performance, high availability, and easy scalability and it works on concept of collection and document. It is an open-source software. MongoDB is mainly written in C++, JavaScript and C. Download Please refer this link to setup MongoDB on your machine. Terminology ·          Document Document is similar to row/tuples in RDBMS, it is a set of key-value pairs and having dynamic schema i.e. the documents in the same collection do not need to have the same set of fields or structure and another document may hold different types of data. ·          Collection It is the equivalent to a TABLE in RDBMS and do not enforce a schema. It exists within a single database and each document wit...

How to install and verify MongoDB on Windows 7 ?

Image
Step by Step instructions: 1.       Download MongoDB Check MongoDB msi from Official website and download Windows Server 2008 R2 64-bit and later version. 2.       Install MongoDB Double click on downloaded MSI (mongodb-win32-x86_64-2008plus-ssl-3.2.11-signed.msi) file and follow the click on next button on wizard to complete the installation. 3.       Create Default Directory MongoDB requires a data directory to store all data and its default data directory path is \data\db. On Windows, By default it will always look for above directory under C:/ structure, Goto C: directory and create /data/db, So the full path of db folder will be C:\data\db 4.       Set environment variables Set MongoDB location to system's environment variables and give path till bin folder. 5.   5.       Start MongoDB To ...