Transferring ownership of queries, forms, and procedures

Use the queries shown in Figure 105 to transfer QMF objects from one user to another. Make sure that you run all three queries.

Note: First make sure that the new owner has no objects saved with the name of the object you are transferring, or QMF will replace the existing object with the object that you transfer.

Figure 105. Transferring QMF objects to another user
UPDATE Q.OBJECT_DIRECTORY      UPDATE Q.OBJECT_REMARKS        UPDATE Q.OBJECT_DATA
SET OWNER = 'newuserid'        SET OWNER = 'newuserid'        SET OWNER = 'newuserid'
WHERE OWNER = 'olduserid'      WHERE OWNER = 'olduserid'      WHERE OWNER = 'olduserid'
AND NAME IN namelist           AND NAME IN namelist           AND NAME IN namelist

In the queries shown in Figure 105, namelist is a list of the object names to be transferred; the list must be set off by parentheses, with each name separated by a comma and surrounded by single quotes. For example:

('QUERY1','QUERY2','FORMA','PROCB')

For queries or procedures that name objects qualified with the old SQL authorization ID, be sure to change the qualifier. For example, if you transfer MYQUERY from BAXTER to JONES, change the name from BAXTER.MYQUERY to JONES.MYQUERY.

Use an SQL query like the one in Figure 104 to change the RESTRICTED column value to Y if you decide you want to share the object after transferring it.

[ Previous Page | Next Page | Contents | Index ]