Hi,
I am new to vbscript. I wanted to copy contents of a excel sheet into the body of any email. Is there a way to do it.
I know how to attach the excel file but wanted to copy some contents inside the excel worksheet directly into the email body. the reason being, very few people open the...
I have the following piece of code,
#!/usr/bin/perl
$txt = "xxx yys";
$txt =~ s/\b/\!/g;
print "$txt\n";
basically I want to substitute at a word boundary a '!' character but not on the first word of the string or line.
the output that I am currently getting is
!xxx! !yys!
I want it to...
I have a data set that looks something like this in a table
storeID DealerCD DealerName DealerPermit
------- -------- ---------- ----------
1111 980038 John PAC
1111 980041 Bill NAC
1111 980041...
I have a data set that looks something like this in a table
storeID DealerCD DealerName DealerPermit
------- -------- ---------- ----------
1111 980038 John PAC
1111 980041 Bill NAC
1111 980041...
Hi,
I want to write a script to import mappings and session automatically. I understand that this can be done using pmrep and the ObjectImport Method. What i am missing is the import control file. can someone please let me know if I can find a sample of it somewhere?
thanks
Hello,
I have a perl script in which i need run some other perl script.
The way I am doing this is through the system command i.e. something like this.
while(<read script names from a file>)
{
system("$script");
}
now, what I want to do is on the screen (STDOUT), I want to display something...
How do I write to the same line in a file after reading from the that line.
#!/usr/contrib/bin/perl
$i = "c.txt";
$flag = 0;
if (-e $i )
{
open(RW,"+<", $i);
}
else
{
open(RW,"+>", $i);
print RW "0";
$flag = 1;
}
if($flag == 0)
{
while(<RW>)
{
$tmp = $_;
}
$tmp=$tmp+1...
Hello,
I am trying to write a perl wrapper script that runs multiple other perl scripts. I want to get status of those perl scripts and status of those scripts on stdout.
Here is a brief explanation of what I want to do.
i have a script perl_wrapper.pl and three scripts perl_1.pl, perl_2.pl and...
I am running this query and basically I want to insert the row count values from diff_x and diff_y into tl_compare table. this query bombs on me.
UPDATE bi_stg_1.TL_COMPARE
from diff_x x, diff_y y
SET
count1 = ( select count(*) from x),
count2 = ( select count(*) from y)
WHERE...
Hi,
I have two arrays, for example,
@array = ("john","larry","kevin","peter","mike")
@exclude = ("john","kevin")
i want to delete from @array , values that exist in @exclude.
i.e. i want my @array to look like
@array("","larry","","peter","mike")
i have written this code but it doesnot seem...
i have a file with the following sample text
1 create table xyz
2 no before journal,
3 no after journal
4 (
5 col1 integer,
6 col2 integer,
7 ...
8 coln varchar(10)
9 )
10;
i want to use perl regex to search and replace text from the line that starts with 'create' word till the first opening...
i want to replace a line in a word document with a blank line.
I want to replace all the lines in the document that start with a particular word with a blank line.
for example. if the document has a line that starts with the following
drop xxx
drop yyy
then I want these two line to be...
I have a file that is generated in the following format fb.d.v6.fbp.200606131452.gz i.e. the current TIME is also attached to YYYYMMDD
my question is how do i build a IF condition in my ksh script so that I can get something like this below
if [[ -s $IN_DIR_Frd/fb.d.v6.fbp.${DT}*.gz ]]
the...
Currently I am running this query to get a sum for each day.
select Activity,
act_a = sum(case tintactivitytype when 3 then 1 else 0 end),
act_b = sum(case tintactivitytype when 4 then 1 else 0 end)
from dbo.tblpostpaid
group by activity
order by activity
the column activity is a 'datetime'...
I want to search for a particular string in a text file.
I was trying to open the file for read and use a while loop to search for the string line by line. I want to stop at the first match but I dont know how to exit from the while loop after the match.
could anybody help?
any other...
Hello,
i want to run one perl file from another and also want to pass parameters to it. how do it do that?
e.g.
lets say I have a file called parent.pl
in main.pl, i have two variables
$x = 'test1';
$y = 'test2';
i want to run a file , lets say child.pl, from main.pl
i did the following...
I want to run a perl file2 from a main perl file1. what function do I use?.. do .. require.. ???
Also, I want to check if the file2 ran successully or not and exit from the main perl file1 and report the error to a log if the execution of the file2 failed?
How do I capture that error message...
How do I find only specific word in a file using grep.
for eg.
I want to find the word 'PRODUCT' (case insenstive)
I used the -i switch to ignore case and -w to match the whole word 'product'.
But I find matches that are
product
PRODUCT
PRODUCT_..
I think the '_'(underscore character) is...
suppose I have a file called sample.sql which I open in a .pl file
the file is something like this when opened in VI (unix editor)
šæselect * from a
where tablename = 'x';<some white space characters>
šæselect * from b
where tablename = 'x';<some white space characters>
šæselect * from c
where...
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.