Posted on 2000-03-28
Last Modified: 2013-12-25
I need to design some password protected form, which will communicate with database, find/present/save data, make some calculations, present data dynamically, etc.... What would be more suitable for this task - CGI (using Perl) or ASP? Genarally speaking, I also would like to know, what are the differences between Perl and ASP; what are their advantages/disadvantages, etc...
Question by:henefeld
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
  • 2

Accepted Solution

Jerf earned 100 total points
ID: 2674157
My experiences with CGI-programming and databases have been extrememly positive when using ASP.
I found the Perl DBI libraries very lacking and didn't hold a candle in comparison to ASP.
I would never deal with files in ASP, however, or do any tricky regular expressions (ASP's regular expressions are terrible.)
Another consideration is what kind of web server are you running?  If it's IIS (Microsoft) I'd definitly lean towards ASP over Perl...For ASP it's a simple matter of setting up a database through ODBC, hooking your Database up and dishing out information.  Perl needs the correct libraries installed (they usualy are) and a bit trickier code.
If, however, you're dealing with an Apache server (of any kind) then I'd go with Perl.  Perl and Apache have grown up together and they work very well with one another.
Both scripting languages have the same amount of development time but, if you've never dealt with Perl before, I would definitly go with ASP.  You can use VBScript or Javascript with ASP and they both have reasonably shallow learning curves.
Perl on the other hand...I've been working with it for a few years now and I still havent learned all its tricks :)
Both Perl and ASP have their uses, but their uses differ enough that they don't overlap as much as you might think.


Author Comment

ID: 2677440
OK, first of all, thanks, it was very interesting.

Now, in the last sentance you say that Perl and ASP don't overlap too much. That's exactly the thing I need to know: what can you do with Perl, that you can't with ASP, and v. versa. I was pretty much under impression that everything you can do with Perl, you can eventually achieve with ASP.

My boss pushes me towards ASP, claiming that Microsoft always wins eventually; and the tendention to use Microsoft servers is growing. Personally, I like the power of Perl, and don't enjoy VB at all.

I didn't find any serious article on the Internet, comparing ASP and CGI (perl). If you know any, please, let me know.

Thanks in advance.

Expert Comment

ID: 2678315
I can only advise AGAINST ASP - I have written some relatively large applications using various data-bases and providing web interfaces.  My objection to APS is that you are tyoing yourself to one, non-open-license, vendor.  To me this is a BIG MISTAKE.

As to getting the job done.  I think there is little difference.  As to maintaining it in the future and having flexibility then ASP is NOT a good choice.
MIM Survival Guide for Service Desk Managers

Major incidents can send mastered service desk processes into disorder. Systems and tools produce the data needed to resolve these incidents, but your challenge is getting that information to the right people fast. Check out the Survival Guide and begin bringing order to chaos.


Expert Comment

ID: 2678349
I really should have said that ASP and Perl will do the same thing, the real differences are under the hood.
I've had some bad luck with the Perl DBI and I'd really reccommend ASP for any database work.  There are alot of problems with the Perl DBI (such as calling the entire record set into memory, instead of just a section of it like ASP does).
Perl OTOH is much much much better at handling strings and doing regular expressions.  If you're planning n doing much string work, then I'd seriously look at Perl, but if, as you said, are just using your app to access a database and spit out the results, ASP is the easiest and more maintainable for this sort of work.
I've really never not been able to do something in ASP that I couldn't do in Perl and vice versa.  They're comperable languages in that they'll do the same things.  Some things are just easier and more developed in one language than the other.
Let me know if you have any other questions.

Expert Comment

ID: 2678366
I largely agree with jerf in terms of features.  I especially agree with his fear of tring to pull in the whole data-base.  If it gets big this is not a good idea in any language.  This is why perl has the each() and the various other ways of getting things without getting them all.  But his warning is legitimate.  I have seen people test data-base apps on small data-sets, then the world falls about when the data-set grows and the data-base will no longer fit in memory.  This is not a language problem though, this is just bad code and can be done badly in any language.


Author Comment

ID: 2679209
Thanks guys. It was very enlightening.

I understand the problem with DBI.

On the other hand, I've heard, is that Perl would be a better option for savvy DB, like Oracle, etc...

What about PerlScript? Would it be something in between? I heard that one can embed it just like VB Script. Would PerlScript be a better choice? Or the DBI strikes again?


Expert Comment

ID: 2679858
PerlScript is just another language that ASP can use to execute the server side code, like Javascript or VBScript.  PerlScript *is* Perl, only imbedded in an ASP.
ASP is kinda handy because you can use many different languages with it.
The only time I've ever used PerlScript was to write a specific function that parsed a string and returned an array.
Use the language for it's strengths.

Author Comment

ID: 2679871
Perl is kinda handy too, I understand. You can use C programs with it.

Expert Comment

ID: 2679955
Yep - I've never done it tho, but you can embed perl into C and vice versa.  Handy if you don't want to give away your source code.

Author Comment

ID: 2680283
I accept the answer. Thanks, guys. Jerf was a little more helpful.

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Active Directory replication delay is the cause to many problems.  Here is a super easy script to force Active Directory replication to all sites with by using an elevated PowerShell command prompt, and a tool to verify your changes.
The Windows functions GetTickCount and timeGetTime retrieve the number of milliseconds since the system was started. However, the value is stored in a DWORD, which means that it wraps around to zero every 49.7 days. This article shows how to solve t…
Learn the basics of if, else, and elif statements in Python 2.7. Use "if" statements to test a specified condition.: The structure of an if statement is as follows: (CODE) Use "else" statements to allow the execution of an alternative, if the …
In a recent question ( here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

756 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question