my $TSMBACKUPSTATEMENT="C:\\ProgramFiles\\Tivoli\\TSM\\TDPSql\\tdpsqlc\" backup $database FULL /sqlbuff=2 /strip=2 /SQLSERV=$servername";
system("start \"Title\" \"$TSMBACKUPSTATEMENT\"");
the above statement is executing fine but when i include one more line to store the output its not working...
#!/usr/bin/perl
#use warnings;
use strict;
use Getopt::Long;
my $level = 'full';
my $loc = 'disk';
my $disp ='bkp';
GetOptions( 'd=s' => \ my $database,
'i=s' => \ my $servername,
'level=s' => \$level,
'location=s' => \$loc...
his is second perl file code which i am calling first perl file
#!/usr/bin/perl
use warnings;
use strict;
use Getopt::Long;
use Win32::SqlServer qw(SCALAR);
GetOptions(
'i=s' => \ my $servername,
'c=s' => \ my $code,
);
system( "start perl $code -i $servername -d msdb ");
I am calling this...
ran well
can you please suggest about this.
GetOptions( 'd=s' => \my $database,
'i=s' => \my $servername,
'TYPE=s' => \my $type,
'LOCATION=s' => \my $loc,
If im not entering any values while executing this perl code,
how can i set any default valuyes...
my goal is to execute this .cmd file inside perl script
this is my .cmd file :
"D:\Program Files\Tivoli\TSM\TDPSql\tdpsqlc" backup master FULL /sqlbuff=2 /strip=2 /SQLSERV=test >> D:\logs\test.OUT 2>&1
this is my perl code:
#!/usr/bin/perl
use warnings;
use strict;
use Getopt::Long;
use...
my $cod="c:\\Program\\ Files";
system("start $cod");
when i am doing this it throws error
the error indicates its not accepting space between program and files
but my path is c:\program files, there is space between program and files
tried lot of ways
finally popsting here
please help
my $cod="c:\\Program\\ Files";
system("start $cod");
when i am doing this it throws error
the error indicates its not accepting space between program and files
but my path is c:\program files, there is space between program and files
tried lot of ways
finally popsting here
please help
I am new to perl
I need to call batch file inside perl script
I know how to call using system function
but the thing is i need to replace some characters in batch file before calling it.
please advise
I am new to perl
but after spending late nights for some days , i was able to generate code for database backup. the code will ask you enter servername , enter database name if i enter it will take backup
suppose my code is in backup.pl
now the thing is i need to get database backup by entering...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.