BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
Bipasha
Obsidian | Level 7

Hi. I have a DI job which contains deployed BRM rule in it. I am trying to migrate this job to another environment having a similar structure. I am exporting this job with the rules associated with it from one environment and importing the same in the new environment. But jobs containing BRM rules are not working while other plain DI jobs are working properly.

 

Is there any specific process to export and import jobs with BRM rules?

If yes kindly provide the way.

1 ACCEPTED SOLUTION

Accepted Solutions
Bipasha
Obsidian | Level 7

Thank you for your suggestions.

It turns out that the user I was using was not a member of the SAS decision manager group. Once I corrected that other issues were easy to solve.

View solution in original post

4 REPLIES 4
RonAgresta
SAS Employee

Hi,

 

Have you ensured that the business rules are also available in that second environment? The DI Studio log may give you more information about where the process is failing.

 

Ron

Bipasha
Obsidian | Level 7

I am trying to export and import the rules using macros as mentioned in the BRM user guide. I am using the following macros:

%BRM_EXPORT_FOLDER

%BRM_EXPORT_LOOKUP

%BRM_EXPORT_RULE_FLOW

%BRM_EXPORT_RULESET

%BRM_EXPORT_VOCABULARY

%BRM_IMPORT_FOLDER

%BRM_IMPORT_LOOKUP

%BRM_IMPORT_RULE_FLOW

%BRM_IMPORT_RULESET

%BRM_IMPORT_VOCABULARY

 

There are two(%BRM_CREATE_TEMP_TERM, %BRM_LOAD_VOCABULARY) more macros mentioned which I am not using for now.

 

I can export the components properly, but cannot import it into the new environment. I am using the following codes to import:

%BRM_IMPORT_FOLDER (CSV=%STR(/SAS_IRM_DATA_1/PAKAGE/BRM/BRMFOLDER.CSV),REJECT=%STR(/SAS_IRM_DATA_1/PAKAGE/BRM/REJECT_FOLDER.CSV));
%BRM_IMPORT_LOOKUP (CSV=%STR(/SAS_IRM_DATA_1/PAKAGE/BRM/BRMLOOKUP.CSV),REJECT=%STR(/SAS_IRM_DATA_1/PAKAGE/BRM/REJECT_LOOKUP.CSV));
%BRM_IMPORT_RULE_FLOW (RULEFLOWS=ALL,CSV=%STR(/SAS_IRM_DATA_1/PAKAGE/BRM/BRMRULLFLOW.CSV),REJECT=%STR(/SAS_IRM_DATA_1/PAKAGE/BRM/REJECT_RULFLOW.CSV));
%BRM_IMPORT_RULESET (RULESETS=ALL,CSV=%STR(/SAS_IRM_DATA_1/PAKAGE/BRM/BRMRULESET.CSV),REJECT=%STR(/SAS_IRM_DATA_1/PAKAGE/BRM/REJECT_RULESET.CSV));
%BRM_IMPORT_VOCABULARY (VOCAB=ALL,CSV=%STR(/SAS_IRM_DATA_1/PAKAGE/BRM/BRVOCABULARY.CSV),REJECT=%STR(/SAS_IRM_DATA_1/PAKAGE/BRM/REJECT_VOCAB.CSV));

 

But this code throws the following error:

 

ERROR: Invalid connection options. Lack USER option.
ERROR: Error in the LIBNAME statement.

ERROR: Cannot access database.

 

I am not sure if these errors are for the BRM import process or something wrong in the configuration. I can run simple programs with the same server connection. 

 

Can any body point me where I am going wrong?

Patrick
Opal | Level 21

@Bipasha

The error pretty clearly indicates that you haven't been successful in migrating your rules yet.

 

The error is also pretty clear that something with your connetion option isn't working.

 

Have a chat with your SAS Admin/the person who's done the environment configuration.

 

Also: Run your code with option mprint set so you'll get a bit more log information.

 

Eventually also use options sastrace=',,,d' sastraceloc=saslog nostsuffix; to get a bit more log info how SAS interacts with the BRM database. Given your current error you're not even there yet as you can't establish a connection.

Bipasha
Obsidian | Level 7

Thank you for your suggestions.

It turns out that the user I was using was not a member of the SAS decision manager group. Once I corrected that other issues were easy to solve.

sas-innovate-2024.png

Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.

Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.

 

Register now!

How to connect to databases in SAS Viya

Need to connect to databases in SAS Viya? SAS’ David Ghan shows you two methods – via SAS/ACCESS LIBNAME and SAS Data Connector SASLIBS – in this video.

Find more tutorials on the SAS Users YouTube channel.

Discussion stats
  • 4 replies
  • 2024 views
  • 2 likes
  • 3 in conversation