The first time you log on to OEM it automatically creates the repository based on the existing DB.
A repository is nothing but a collection of tables consisting details of the DB for the reference of OEM tools to run.
Before Oracle Enterprise Manager is used, you must create a
set of base tables that contain environment information for the managed databases-this is the Repository. You create the necessary tables in the Repository by using the SMPCRE.SQL and XPOCR.SQL scripts found in the $ORACLE_HOME/ rdbms/admin directory.
An Oracle user must be created with appropriate permissions to access the Repository before the scripts are run. For each user that needs to access the console, a separate Repository must be created and setup scripts must be run.
The Oracle Enterprise Manager lets DBAs manage one or more databases on one or more platforms in one or more locations — all from the same console. You can easily view all of the objects associated with a particular database or group of databases, and you can perform day-to-day tasks from the central console screen.
The Repository must be compatible with the version of the Oracle Enterprise Manager. If the Repository version is older or newer than the console version, you must install a more recent compatible version of Enterprise Manager.
Attitude:Attack every problem with enthusiasam ...as if your survival depends upon it
Can you explain this part of your explanation once more in another way:
"The Repository must be compatible with the version of the Oracle Enterprise Manager. If the Repository version is older or newer than the console version, you must install a more recent compatible version of Enterprise Manager."
For example the scripts what i say create the repository belong to oracle 8.0.5 then if the OEM of that version will be compatible.
think about the features incorporated in to each and every new versions of OEM .many tool have new features like buttons--which may fetch some record to display etc.Now you have OEM TOOL of 8.1.6 but a script of 8.0.5 what will happen.It would have collected informations required to dispalay compatible to all features of 8.0.5 but not for new tool.
kindly go in to the 2 links of you can
Manually Creating, Dropping, or Upgrading the Repository also.
As far as the OEM is concerned, the version of OEM should be the same as that of the OMS. It has nothing to do with the database version. Say for example you have a management serer (OMS) repository of 2.1 and you are trying to use the OEM of 2.2, it wouldn't work, as there is a compatibility issue. The java script for OEM 2.2 are advanced than that of the OEM 2.1. That is why this problem.
So oracle advices, that you have the OEM and OMS of the same version. If you have an older OMS repository, you can upgrade it using the Oem configuration assistant.