"Kristin A. I." wrote:
>
> I am trying to indent a scroll-thru menu which has been made
> into a tree using the following database query:
> select dept_id, LPAD(' ',2*(Level-1))||dept_name dept_name
> from depts
> start with dept_id = 1
> connect by dept_parent = PRIOR dept_id;
> My probl
On Tuesday, April 9, 2002, at 09:39 AM, Kristin A. I. wrote:
> I am trying to indent a scroll-thru menu which has been made into a tree
> using the following database query:
> select dept_id, LPAD(' ',2*(Level-1))||dept_name dept_name
> from depts
> start with dept_id = 1
> connect by
I'm sure that this can be done is less steps, but it works...
#!/usr/bin/perl -w
use strict;
my $line = " stuff\n";
print chgSpace($line);
sub chgSpace {
my $line = shift;
my ( $spaces ) = $line =~ /^(\s+)/;
$spaces =~ s/ /_/g;
$line =~ s/^\s+/$spaces/;
return $line;
}