perl-asp mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dariusz Pietrzak <dari...@ajax.umcs.lublin.pl>
Subject Re: Need info about odbc database handling in asp
Date Thu, 07 Jun 2001 11:13:28 GMT

> I've setup apache with asp. Works great! 
> Now i want to access a odbc database within my asp.

> I guess this should be done in perl, but can it be done in jscript too?
> I would like to make a perl based script, and a jscript.
You want your client's browser to connect to your dbase and not your
application?
That's a contradiction to 'Now i want to access a odbc database within my
asp'.

with perl you do sth like this:

<%
#my $DSN = 'driver=Microsoft Access Driver
#(*.mdb);dbq=C:\\path\\to\\mdb-file.mdb';
my $DSN = 'driver={SQL Server};Server=MSSQLServer1;
       database=mydatabase;uid=myid;pwd=mypass;';
my $dbh = DBI->connect("dbi:ODBC:$DSN", '','') 
                        or die "$DBI::errstr\n";

#and then standart..
$dbh->do(" update users set money = null");

%>

Source generally starts looking realy ugly when you mix asp with
javascript ( duh, when I recall how our code used to look like when we
wrote in javascript server side, mixed with standart js uaa ).
 And also javascript is not a fully functional language, I found then most
setup that tried to do sth like that end with java applet running on
clients browser. seriously consider that solution since AFAIK js has many
pitas and eats developer time.



---------------------------------------------------------------------
To unsubscribe, e-mail: asp-unsubscribe@perl.apache.org
For additional commands, e-mail: asp-help@perl.apache.org


Mime
View raw message