17 Temmuz 2014 Perşembe

LISTENER CONFIGURATION

To able to create a database and to able to use it in your localhost you need to create firstly listener which comes with default values. This is step by step configuration of a listener. It is not possible to have a database either local or not without listener. What is listener? We will examine this question later on but here we have how to configure it simply

1-)
2-)

3-) you can give any name in here to a listener that you are about to create.I used the default one.

 4-)
5-)

6-)

7-)

8-)



Error while trying to retrieve text for error ORA-01019

My manager wanted me to check out this error which occured at a remote computer trying to connect our oracle database.
After a google operation and i came to a quick result.

There were more than one ORACLE_HOME path inside system variables.
So to overcome it. Check out the paths that are in system variables.

In my case there were more than one path as shown below in an order;
C:\oracle\BIToolsHome_1;C:\app\HAMDI\product\11.2.0\dbhome_1\bin;C:\oracle\BIToolsHome_1

So i remove the paths written repeatedly. Then we were able to make it connecting to our database.



The source that guided me to solve this issue;

http://stackoverflow.com/questions/12560925/error-while-trying-to-retrieve-text-for-error-ora-01019



DIM - 00019 : Create Service Error O/S Error : (OS 1703) ORACLE DATABASE

When i try to create a database, i had this error.
The reason that causes this error is simple.

I had created once a database with HAMDI name and after removing database i did not remove all regedit registries completely and there were some services running related to this database name. So whilts creating a new database with same name,it inevitably had shown me an error.





So be careful about removing database completely without even missing any file running with system.






12 Temmuz 2014 Cumartesi

ORA-00911 invalid character (Database Configuration Assistant)

I had an error as written at title while creating a database from Database Configuration Asisstant at last step when it is being created.

I tried changing the Database Name and SID and data file name that i created for my database.

My database name was DBHAMDI and i changed it to HAMDI
My database's data folder's name which i created under my ORACLE_HOME was 'data_DBHAMDI'
and i used lower case to guarentee it. 
I did not get why i had this error because there was not any wrong definition like using Non-English Character or something like this but googling showed me some sort of way like i did and It worked.


No more error :)

'sqlplus' is not recognized as an internal or external command, operable program or batch file. (COMMAND PROMPT)

I had started to use my home-Laptop as a lab pc which i use seperately than one i use in my company.
The reason is to experiment oracle cases to experience the warnings,responds,results and to see how to overcome them.Shortly my pc is my cavy in my lab;)




If you had the same problem,the solution is simple. Just add your ORACLE_HOME path to your
Environment Variables. For instance;
To find ORACLE_HOME path. Look it up from registry;

Windows --->Run--->regedit--->HKEY_LOCAL_MACHINE
CTRL + F 
type ------>ORACLE_HOME 
Press----->Find

C:\oracle\BIToolsHome_1; 

Right Click Computer--> Advanced System Settings-->Advanced


                                          
Click Edit----- Add your ORACLE_HOME path to the very begining of line. Do not forget to put semi colon to separate it from other path and then click OK.






ORA-12154: TNS:could not resolve the connect identifier specified

My colleague in my company had a problem to connect to database server due to a change inside TNS file. He requested my help to solve it. After searching oracle's origin sources, i encountered many causes. One of them was ours.The alteration in TNS file that causes this issue in our case has shown with yellow colour.Here what i have googled and found out;

ORA-12154: TNS:could not resolve the connect identifier specified


Cause: A connection to a database or other service was requested using a connect identifier, and the connect identifier specified could not be resolved into a connect descriptor using one of the naming methods configured. For example, if the type of connect identifier used was a net service name then the net service name could not be found in a naming method repository, or the repository could not be located or reached.
Action:
- If you are using local naming (TNSNAMES.ORA file):

- Make sure that "TNSNAMES" is listed as one of the values of the NAMES.DIRECTORY_PATH parameter in the Oracle Net profile (SQLNET.ORA)

- Verify that a TNSNAMES.ORA file exists and is in the proper directory and is accessible.

- Check that the net service name used as the connect identifier exists in the TNSNAMES.ORA file.

- Make sure there are no syntax errors anywhere in the TNSNAMES.ORA file. Look for unmatched parentheses or stray characters. Errors in a TNSNAMES.ORA file may make it unusable.

- If you are using directory naming:

- Verify that "LDAP" is listed as one of the values of the NAMES.DIRETORY_PATH parameter in the Oracle Net profile (SQLNET.ORA).

- Verify that the LDAP directory server is up and that it is accessible.

- Verify that the net service name or database name used as the connect identifier is configured in the directory.

- Verify that the default context being used is correct by specifying a fully qualified net service name or a full LDAP DN as the connect identifier

- If you are using easy connect naming:

- Verify that "EZCONNECT" is listed as one of the values of the NAMES.DIRETORY_PATH parameter in the Oracle Net profile (SQLNET.ORA).

- Make sure the host, port and service name specified are correct.

- Try enclosing the connect identifier in quote marks. See the Oracle Net Services Administrators Guide or the Oracle operating system specific guide for more information on naming.





8 Temmuz 2014 Salı

REP-0495 UNABLE TO TOKENIZE THE QUERY


10.1.6 Opening / Running an encoded JSP report

If your JSP report's character encoding (for example, EUC-JP) differs from the character set portion of the NLS_LANG environment variable (for example, JA16SJIS), then you will get the following errors:
  • when running the JSP file:
    REP-6106 or 6104 with javax.servlet.jsp.JspException  (multibyte)
    REP-0495 Unable to tokenize the query (singlebyte)
    
    
  • when opening the JSP file using Reports Builder:
    REP-0069 Internal Error or REP-6106
Workaround
To work around this issue, you must ensure that your JSP report's character encoding matches the IANA encoding corresponding to Reports Builder's character set portion of the NLS_LANG variable.
For example, the JSP report encoding
<%@ page contentType="text/html;charset=EUC-JP" %>
<META http-equiv="Content-Type" content="text/html;charset=EUC-JP">

uses the IANA character encoding EUC-JP. For this report, you should use the NLS_LANG setting
NLS_LANG=JAPANESE_JAPAN.JA16EUC.
The JSP report's encoding (EUC-JP) will then correspond to the character encoding part of the NLS_LANG environment variable (JA16EUC).

10.1.7 Dynamically Embedding a Character Set in a JSP file

In Oracle Reports, Web-report templates are configured by default for Western European character encoding. For other languages, you must specify the character encoding for a JSP file by using both the charsetattribute of the <meta> tag and the <%@page%> page directive.
To dynamically associate the appropriate character encoding with the JSP file, you can make the following modifications:
  1. In the directory oracle_home/reports/templates/, edit the files rw*.html and blank_template.jsp:
    1. Modify the page directive to read
      <%@ page contentType="text/html;charset=yourIANAencoding" %>
      
      
      where
      yourIANAencoding is the IANA character encoding that corresponds to the character encoding part of your NLS_LANG environment variable.
    2. Modify the <meta> tag inside the <head> tag to read:
      <meta http-equiv="Content-Type"
      content="text/html;charset=yourIANAencoding" />
      
      
  2. In the directory oracle_home/reports/templates/, edit the file template.xsl:
    1. Modify the <xsl:output> tag to read:
      <xsl:output
           method="jsp"
           indent="yes"
           encoding="yourIANAencoding"
         />
      
      
      where
      yourIANAencoding is the IANA encoding that corresponds to the character encoding part of your NLS_LANG environment variable.
    2. Add the following page directive:
      <%@ page contentType="text/html;charset=yourIANAencoding" %>
      
      
    3. Add or modify the <meta> tag inside the <head> tag:
      <meta http-equiv="Content-Type"
      content="text/html;charset=yourIANAencoding" />
      
      
      where
      yourIANAencoding is the IANA encoding that corresponds to the character encoding part of your NLS_LANG environment variable.

There was an explanation in oracle documentation website about the error written in title and it helped me out a lot to overcome it.
As much as i analyzed i came up with a result showing me that one file which is necessary to call IANA Encoding to match with NLS_LANG variable was not even able to be found at remote computer. I did the same search for these files on my own computer. I found them out. 

You have to look at your own oracle files path first. Here mine was;

C:\oracle\BIToolsHome_1\reports\

Template.xsl file path;

C:\oracle\BIToolsHome_1\reports\templates.xsl

blank_template.jsp

C:\oracle\BIToolsHome_1\reports\blank_template.jsp


HERE THE PICTURES ARE AND THE DETAILS WHICH HAS TO BE CHECKED OUT
                                                                blank_template.jsp




template.xsl



TO SOLVE IT FOR REMOTE COMPUTER I TRIED MORE THEN ONE NLS_LANG VARIABLES FROM REGISTRY. IT IS IN 

HKEY_LOCAL_MACHINE/SOFTWARE 
LOOK IT UP BY CTRL+F TYPE NLS_LANG 

I TRIED TWO OF THEM. IT ALL WORKED

1-AMERICAN_AMERICA.UTF8

AND

2-TURKISH_TURKEY.TR8MSWIN1254 



THERE YOU GO!