Hire me on UpWork
Showing posts with label 6i. Show all posts
Showing posts with label 6i. Show all posts

Sunday, August 23, 2020

REP-1060: Reports Builder database tables have not been installed.

 Greetings from Hamid Blog


Issue on: Oracle Forms 10g, 6i


After opening the report builder, when you try to open an existing reports, you will get bellow error message.


REP-1060: Report Builder database tables have not been installed.
ORA-00942: table or view does not exist.
Report Builder tables may not be installed in the database.


cause: Database access is chosen in Reports Builder Preferences

Solution:


1) Open Reports Builder

2) Choose Tools -> Preferences

3) Go to Access tab and make sure that the checkbox next to 
   Access -> File
   is checked

4) Ensure that Access -> Database
   or
   Access -> File/database is not checked

Finally, you will get,


Thanks for reading my blog!



Thursday, May 14, 2015

Forms And Reports 6i Crash When Connection with 11g XE Database !!!

As salamualikum (islamic greetings), brothers and sisters. :)

 Hope you are fine.. 

Not very useful for everybody but it's a solution if you need.

If you try to connect Oracle form & Reports 6i with Oracle Database 11g XE (Express Edition), every time, it will crash and you will not able to connect. 

But it will not happen with 11gR2 Enterprise or any other Edition.

>>?? Why this happen ?

Because, Database 11g XE use,

SQL> select * from v$nls_parameters where parameter like '%CHARACTERSET%';

PARAMETER                                                        VALUE                                                                                                                                                                                                                                                                                                                                                                                                                                             
---------------------------------------------------------------- ----------------------------------------------------------------                                                                                                                                                                                                                                                                                                                                                                                  
NLS_CHARACTERSET                                                 AL32UTF8                                                                                                                                                                                                                                                                                                                                                                                                                                          
NLS_NCHAR_CHARACTERSET                                           AL16UTF16                                                                                                                                                                                                                                                                                                                                                                                                                                         
 

you  need to set the database character set as UTF8.

To do so you need to follow the bellow steps..

1. connect as sysdba using SYSTEM not SYS.

Run the following command sequencially.

SQL>CONN SYSTEM/MANAGER AS SYSDBA

2. Shutdown the database if running:
SQL>SHUTDOWN IMMEDIATE

3. Start the database in restrict mode:
SQL>STARTUP RESTRICT

4. Change the databse charcter set to UTF8 as follows:
SQL>ALTER DATABASE CHARACTER SET INTERNAL_USE UTF8;

5. Shutdown the database:
SQL>SHUTDOWN IMMEDIATE

6. At last, start the database in normal mode:
SQL>STARTUP

After successfull of these steps, you can connect to the Oracle XE database through Forms 6i or Oracle Reports 6i


 Comments to share your thoughts..


End for the day....


Praise to Almighty Allah(swt).  :)


Fi amanillah

Tuesday, October 28, 2014

How to Read Image / Picture in Oracle Reports from File System ?

As salamualikum (islamic greetings), brothers and sisters. :)
Hope you are well with the grace of Almighty Allah (swt).

Today, i discuss an important issue, many of oracle developer spend hours and hours to make a reports to show image from file system, which is much complex.

From Now on, it will be easy and remain easy. :)

Follow the bellow steps.

  1. Take a Formula column
  2. Data Type Char
  3. Length 500
  4. Set READ FROM FILE property to YES
  5. Set File Format to Image
  6. Make the Image stored folder as Shared Folder

Example Code::

function CF_IMAGEFormula return Char is
  
  filename VARCHAR2(200);
  tiff_image_dir VARCHAR2(80) :='<PC_NAME>/emp_picture/'; --// Folder name should be shared for shared link.
    out_file Text_IO.File_Type;
BEGIN

out_file :=Text_IO.Fopen(tiff_image_dir||:EMP_CODE||'.jpg', 'r'); -- r is read only AND EMP_CODE is the name of image.

filename := tiff_image_dir||:EMP_CODE||'.jpg';
return filename;

exception
when no_data_found then
RETURN tiff_image_dir||'blank.jpg';

when others then
if sqlcode=-302000 then
RETURN tiff_image_dir||'blank.jpg';
end if; 

end;


 You are Done :)
Pray for me to Almighty Allah (swt) to keep it up and for my hereafter.

Friday, May 23, 2014

How to Connect Forms 6i With Database Version 10g XE / 11g XE ?

As salamualikum (islamic greetings), brothers and sisters. :)
Hope you are well with the grace of Almighty Allah (swt).


You just installed Oracle Database XE version (10g or 11g) and try to connect with forms 6i. When you put the connection string and hit ENTER to connect then Forms/Reports builder hang and "Forcefully Closed".

What happen ?

It's just about the CHARACTER SET mismatch.  Typically XE database version most surelly 
11g XE use Unicode CHARACTER SET, which is "AL32UTF8".

Forms/Reports 6i doesn't support this and supports ("UTF8","WE8MSWIN1252")

Moreover,


Oracle Database 11g Express Edition has no provisions to change/use other charactersets than AL32UTF8 as NLS_CHARACTERSET and AL16UTF16 as NLS_NCHAR_CHARACTERSET
The NLS_CHARACTERSET is used for CHAR, VARCHAR2, LONG and CLOB columns;
The NLS_NCHAR_CHARACTERSET is used for NCHAR, NVARCHAR2 and NCLOB columns.
So, if you migrate data from any previous version of Database like 10g with special character, you will see the bellow problem when importing.

SQL> create table t( c varchar2(3) );

SQL> insert into t values( 'abç' );
insert into t values( 'abç' )
*
ERROR at line 1:
ORA-12899: value too large for column "SCH"."T"."C" (actual: 4, maximum: 3)



What to do ?
Simply alter the CHARACTER SET to previously supported one.

[Script]

Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

C:\Windows\system32>CD C:\oraclexe\app\oracle\product\11.2.0\server\bin

C:\oraclexe\app\oracle\product\11.2.0\server\bin>SET ORACLE_HOME=C:\oraclexe\app
\oracle\product\11.2.0\server

C:\oraclexe\app\oracle\product\11.2.0\server\bin>SET ORACLE_SID=XE

C:\oraclexe\app\oracle\product\11.2.0\server\bin>echo %ORACLE_SID%
XE

C:\oraclexe\app\oracle\product\11.2.0\server\bin>SQLPLUS/NOLOG

SQL*Plus: Release 11.2.0.2.0 Production on Fri May 23 19:53:42 2014

Copyright (c) 1982, 2010, Oracle.  All rights reserved.

SQL> CONN SYS/SYSTEM11g AS SYSDBA
Connected.
SQL> SHUTDOWN IMMEDIATE
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL>
SQL>
SQL>
SQL> STARTUP RESTRICT
ORACLE instance started.

Total System Global Area  535662592 bytes
Fixed Size                  1384760 bytes
Variable Size             272633544 bytes
Database Buffers          255852544 bytes
Redo Buffers                5791744 bytes
Database mounted.
Database opened.
SQL>
SQL>
SQL> ALTER DATABASE CHARACTER SET INTERNAL_USE WE8MSWIN1252;

Database altered.

SQL>
SQL>
SQL> SHUTDOWN IMMEDIATE
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL>
SQL>
SQL> STARTUP
ORACLE instance started.

Total System Global Area  535662592 bytes
Fixed Size                  1384760 bytes
Variable Size             272633544 bytes
Database Buffers          255852544 bytes
Redo Buffers                5791744 bytes
Database mounted.
Database opened.
SQL>
SQL> select * from v$nls_parameters where parameter like '%CHARACTERSET%';

PARAMETER
----------------------------------------------------------------
VALUE
----------------------------------------------------------------
NLS_CHARACTERSET
WE8MSWIN1252

NLS_NCHAR_CHARACTERSET
AL16UTF16


You are Done :)

BUT ORACLE & I DON'T ENCOURAGE THIS, AS

Oracle recommends Unicode AL32UTF8 as the database character set. Unicode is the universal character set that supports most of the currently spoken languages of the world. It also supports many historical scripts (alphabets). Unicode is the native encoding of many technologies, including Java, XML, XHTML, ECMAScript, LDAP. Unicode is ideally suited for databases supporting the Internet and the global economy.

Praise to Almighty Allah(swt). 
Fi amanillah

Monday, November 26, 2012

How to Add or Remove List Text Anywhere from List Item?

Dear Mates,
Hope your are fine. Here we will talk a trick of Oracle List Item for Forms Version 10g and 6i.

If you want to remove list text and values from a oracle forms list item. How will you do this ? When there is no remove icons and Backspace and Delete key doesn't work, both just lest blank spaces.

Don't worry. I'm here for your help. Try the following shortcut key..

  • "Ctrl + Shift + >" - add list element.
  • "Ctrl + Shift + <" - remove list element.


  • Leave comment and SMILTE :)

    Wednesday, April 11, 2012

    How to Spell Check in Oracle Forms 6i ?

    How will you feel if you able to check spelling in oracle forms?

    Yea! Surely great…
    Let’s try how we can do that.
    This code uses the Microsoft Office spell checker, so you have installed Microsoft office suite. Now, create a procedure in forms under program units with the following code.

    PROCEDURE spell_check (item_name IN VARCHAR2)
    IS
       my_application   ole2.obj_type;
       my_documents     ole2.obj_type;
       my_document      ole2.obj_type;
       my_selection     ole2.obj_type;
       get_spell        ole2.obj_type;
       my_spell         ole2.obj_type;
       args             ole2.list_type;
       spell_checked    VARCHAR2 (4000);
       orig_text        VARCHAR2 (4000);
    BEGIN
       orig_text := NAME_IN (item_name);
       my_application := ole2.create_obj ('WORD.APPLICATION');
       ole2.set_property (my_application, 'VISIBLE', FALSE);
       my_documents := ole2.get_obj_property (my_application, 'DOCUMENTS');
       my_document := ole2.invoke_obj (my_documents, 'ADD');
       my_selection := ole2.get_obj_property (my_application, 'SELECTION');
       ole2.set_property (my_selection, 'TEXT', orig_text);
       get_spell :=ole2.get_obj_property (my_application, 'ACTIVEDOCUMENT');
       ole2.invoke (get_spell, 'CHECKSPELLING');
       ole2.invoke (my_selection, 'WholeStory');
       ole2.invoke (my_selection, 'Copy');
       spell_checked := ole2.get_char_property (my_selection, 'TEXT');
       spell_checked :=SUBSTR (REPLACE (spell_checked, CHR (13), CHR (10)),1,LENGTH (spell_checked));
       COPY (spell_checked, item_name);
       args := ole2.create_arglist;
       ole2.add_arg (args, 0);
       ole2.invoke (my_document, 'CLOSE', args);
       ole2.destroy_arglist (args);
       ole2.RELEASE_OBJ (my_selection);
       ole2.RELEASE_OBJ (get_spell);
       ole2.RELEASE_OBJ (my_document);
       ole2.RELEASE_OBJ (my_documents);
       ole2.invoke (my_application, 'QUIT');
       ole2.RELEASE_OBJ (my_application);
    END;

    Now call the procedure in a Button passing the column name. Like
    spell_check(‘Block_Name.Item_Name’);

    Now all is yours…  :)

    Say thanks, if it helps.