Purpose of Query
This page provides a query to ignore or validate the Dynamic Links based on rules. In the current case, the rule is based on the object full name. The object full name is usually filtered by regular expression.
Applicable CAST Version
Release | Yes/No |
---|---|
8.3.x | |
8.2.x | |
8.1.x | |
8.0.x |
Applicable RDBMS
RDBMS | Yes/No |
---|---|
Oracle Server | |
Microsoft SQL Server | |
CSS2 |
Query for CSS
1- First we check if the query returns the links that we expect.
SELECT t1.typnam AS "CALLER TYPE", k1.idkey AS "CALLER ID", K1.keynam AS "CALLER NAME", ofn.fullname AS "CALLER FULL NAME", t2.typnam AS "CALLEE TYPE", k2.idkey AS "CALLEE ID", K2.keynam AS "CALLEE NAME", ofn2.fullname AS "CALLEE FULL NAME", ac.prop AS "PROP ID", CASE WHEN ac.prop = 1 THEN 'TO BE REVIEWED' WHEN ac.prop = 65537 THEN 'IGNORED' WHEN ac.prop = 32769 THEN 'VALIDATED' END AS "TYPE OF LINK" FROM acc ac join keys k1 ON k1.idkey = ac.idclr join objfulnam ofn ON ofn.idobj = k1.idkey AND ofn.fullname ~ '[YOUR REGULAR EXPRESSION]' join typ t1 ON t1.idtyp = k1.objtyp -- If the Type of the caller is requested uncomment the next line -- AND t1.typnam = 'JV_METHOD' join keys k2 ON k2.idkey = ac.idcle join objfulnam ofn2 ON ofn2.idobj = k2.idkey AND ofn2.fullname ~ '[YOUR REGULAR EXPRESSION]' join typ t2 ON t2.idtyp = k2.objtyp -- If the Type of the callee is requested uncomment the next line -- AND t2.typnam = 'CAST_Oracle_RelationalTable' WHERE prop = 1; -- 1 is for unreviewed DLM, 65537 for ignored and 32769 for validated
Results from the query will look like the following showing details on the caller and callee - review the results and make sure that these are the links you want to modify:
Query result example
"JV_FIELD";34542;"INCLUDE_PROFILES_PROPERTY";"org.springframework.boot.context.config.ConfigFileApplicationListener.INCLUDE_PROFILES_PROPERTY";"JSP_PROPERTY_MAPPING";4511;"spring.profiles.include";"[C:\CASTMS\Deploy\test835\mongo_java\Mongo\spring-boot-project\spring-boot\src\test\resources\application-morespecific.properties].spring.profiles.include";1;"TO BE REVIEWED"
"JV_METHOD";6356;"determineProjectType";"org.springframework.boot.cli.command.init.ProjectGenerationRequest.determineProjectType";"JSP_PROPERTY_MAPPING";4497;"value";"[C:\CASTMS\Deploy\test835\mongo_java\Mongo\spring-boot-project\spring-boot\src\test\resources\application.properties].value";1;"TO BE REVIEWED"
"JV_METHOD";6356;"determineProjectType";"org.springframework.boot.cli.command.init.ProjectGenerationRequest.determineProjectType";"JSP_PROPERTY_MAPPING";4497;"value";"[C:\CASTMS\Deploy\test835\mongo_java\Mongo\spring-boot-project\spring-boot\src\test\resources\application.properties].value";1;"TO BE REVIEWED"
2- Once you have checked the result, you can ignore or validate the dynamic links
UPDATE acc SET prop = [VALUE] -- VALUE is 65537 for ignored dynamic links and 32769 for validated dynamic links WHERE idacc IN (SELECT idacc FROM acc ac join keys k1 ON k1.idkey = ac.idclr join objfulnam ofn ON ofn.idobj = k1.idkey AND ofn.fullname ~ '[YOUR REGULAR EXPRESSION]' join typ t1 ON t1.idtyp = k1.objtyp -- If the Type of the caller is requested uncomment the next line -- AND t1.typnam = 'JV_METHOD' join keys k2 ON k2.idkey = ac.idcle join objfulnam ofn2 ON ofn2.idobj = k2.idkey AND ofn2.fullname ~ '[YOUR REGULAR EXPRESSION]' join typ t2 ON t2.idtyp = k2.objtyp -- If the Type of the callee is requested uncomment the next line -- AND t2.typnam = 'CAST_Oracle_RelationalTable' WHERE prop = 1); -- 1 is for unreviewed DLM, 65537 for ignored and 32769 for validated
This query will just return with an indication of the number of rows modified.
Notes/comments
Related Pages