-----Mensaje original-----
De: Dovalle Yankelovich [SMTP:[EMAIL PROTECTED]]
Enviado el: Martes, 21 de Mayo de 2002 11:04 a.m.
Para: Perl32 (E-mail)
Asunto: Opening MS-SQL DB with Perl
Hi,
I need some help...
I'm looking for perl script (example) which take data from MS-SQL (I need it to learn how it work, which modul is needed etc')
I use this on Win9x to a MsSQL Server on NT 4..., and it works.
use MSSQL::DBlib;
use MSSQL::DBlib::Const::General;
$dbh = MSSQL::DBlib->dblogin('Mi_login', '','Mi_server' );
if (!$dbh) {
Mensaje("Hooooops");
return;
}
$dbh->dbuse("Mi_db");
#
$sql = "INSERT Mi_table (Col_1,Col_2,Col_3)
VALUES(\'$val_1\',\'$val_2\',\'val_3\')";
$dbh->dbcmd($sql);
$dbh->dbsqlexec;
$dbh->dbresults;
$dbh = $dbh->dbclose;
(it is not a full script, just a few lines as example.)
Normann Muñoz Oyarzún.
Administrador de Sistemas
El Mercurtio de Valparaíso S.A.P.
264188 - 204189
[EMAIL PROTECTED]