The access service requires certain files on the AS/400. ECDA for ODBC access service looks for these files in a collection called “SYBASE.” You must create this collection and name it “SYBASE” before installing the access service.
The owner of the SYBASE collection must have QSECOFR privileges.
The SYBASE collection contains a package for the DC DB2 UDB driver that is created when the drivers are installed. After you create the packages, you need to grant permissions to PUBLIC for the end users to access the Sybase collection located on the target AS/400. This can be done with isql (which comes with the ECDA installation), or entered directly on the AS/400 machine.
The ECDA service used to issue the GRANT EXECUTE command
must be in sybase mode for SQL transformation. (SQL
transformation is an access service property with one of two settings, passthrough or sybase.)
To ensure this, enter the following command in the isql session
before you issue the GRANT EXECUTE command:
set sqltransformation sybase
To grant permissions from isql
Issue this command:
GRANT EXECUTE ON PACKAGE SYBASE.DEF000x TO PUBLIC
Because the AS/400 allows you to change security levels and ownership of objects, you can use another user ID to create the SYBASE collection. For example, you can use one ID to create the SYBASE collection, then grant other users create and execute authorization for the collection and its objects.You can create the SYBASE collection one of two ways:
If you have DB2 (or DB2/400) Query Manager and SQL Development Kit (SDK) installed on the AS/400, you can run the SQL utility using a 5250 session.
If not, you need to use the AS/400 SEU utility program to create the SYBASE collection.
To grant permissions directly on the AS/400
Log in to the AS/400 from the main console, a 5250 terminal, or a 5250 terminal emulator, using the user ID that will be the owner of the SYBASE collection.
To display the Sybase packages, on the command line, enter:
WRKOBJOWN SYBASE
On the Work with Object by Owner window, locate and select a package from the attribute column and in the corresponding OPT column, enter:
2
On the Edit Object Authority window, in the User column, locate *PUBLIC, and in the corresponding Object Authority column, enter:
ALL
Press F12 to return to the Work with Object by Owner window, and repeat steps 2 and 3 until all packages are completed. To exit, press F3 repeatedly, followed by 90.