List:General Discussion« Previous MessageNext Message »
From:Douglas Brantz Date:July 19 2000 2:13pm
Subject:Using arrays to grab data out of Mysql
View as plain text  
Is there a way that I can fill Mysql info into a Textarea in Perl-CGI

I am trying the following and can only print one line - but I know I
have  three lines of data:

my $sth4 = $dbh->prepare("select
sec,title,des,credit,schdays,timein,timeout from table where
done=\"No\" ") or bail_out("Cannot Connect");

my @arrinstr=();
while (@arrinstr = $sth4->fetchrow)
$list = "$csec   $ctitle  $cdes $ccredit  $cschdays
#push (@arrlist, $list);
print "<tr><td>";
print $query->textarea ({-name=>'INFO', -default=>@arrlist,-cols=>'35',

-------->  The output looks like this 006   Print Making  MC 3  W

Can anyone help shed light on this crazy array problem?  All I want is
to print this info in a textarea so that the user
can scroll up and down through the data.  I can get it to print to the
page fine but not in the textarea.?  Thought I could use
the push command to add the other lines of data but it didn't seem to


Question about permissions:  Is it true that when you create a user in
the mysql mysql database that you should set all
permission statements, such as select, update etc.  to "N"  and then in
the database table when you link the user to a database - this is where
you would allow the selected permissions for functions like select and
update?  Basically, we create a blank user with no username or password
and then set all permissions to "Y" in the user table of mysql.  Then we
linked that user to the test database.  So at the command line that user
could go into the database test, but could also go into all the other
To solve this we set all permission statement for the user with no
username or password to "N" in the user table.

Is this correct??




Douglas Brantz
Computer Consultant
Fine & Applied Arts
Appalachian State University
Boone, NC 28608

828-262-6312 FAX
828-262-6549 OFFICE

Using arrays to grab data out of MysqlDouglas Brantz19 Jul
  • Re: Using arrays to grab data out of MysqlChristopher R. Jones19 Jul