APEXtras

a development team dedicated to Oracle APEX

APEX deployment PERL script to replace security_group_id

leave a comment »

#This script is called as rep.pl from the export batch file
($fin,$fout1,$s1,$s2) = @ARGV;

open (IN,"<".$fin)     || die;
open (OUT1,">".$fout1) || die;

if ($s2 eq ""){
  $s1 = "\twwv_flow_api.set_security_group_id(".
    "p_security_group_id=>apex_UTIL.FIND_SECURITY_GROUP_ID('".$s1."'))";
  $s2 = "^\\s*wwv_flow_api\.set_security_group_id\\(p_security_group_id\=\>\\d*\\)";
}

while (<IN>) {
  my $T = $_;
#  if ($T =~ m/$s2/i) {
#    print $T;
#  }
  $T =~ s/$s2/$s1/;
  print OUT1 $T;

}

__END__

Back to Apex deployment script

Written by Roger

11 February, 2009 at 5:16 pm

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: