Loading ...
Sorry, an error occurred while loading the content.

Re: Perl & SQL...

Expand Messages
  • coo_t2
    I recommend going to http://www.phpgeek.com and downloading phpTriad. Even though php is in the name it s still good for doing perl/mysql development. It
    Message 1 of 2 , Mar 31, 2002
      I recommend going to http://www.phpgeek.com and downloading phpTriad.
      Even though php is in the name it's still good for doing perl/mysql
      development. It comes with apache, php, mysql, phpMyAdmin, and perl.
      The distribution of perl that comes with it is lightweight though,
      but you can
      always link to other distributions with the shebang line, by putting
      the full path
      to the perl exe like so, #!c:\perl\bin\perl.exe .
      phpMyAdmin is a really good tool to adminster a mysql database.
      It's also a good tool to learn sql from because any time you do
      with phpMyAdmin that interacts with the mysql database, it prints out
      the sql
      statement that it used to talk to the database.
      You don't have to switch to php to use phpMyAdmin!
      phpMyAdmin is just an interface to mysql written in the php
      So don't get scared thinking that because you use it,
      you'll have to give up perl, and use php instead.
      There's no php programming involved.
      Although I think php is a pretty cool language also.

      This is how I start up apache on win9x.
      I open up a dos box and go to the directory that apache is in
      prompt>cd c:\apache
      Then I type the command 'apache' to fire up the web server.

      Then I open up another dos box and go the directory that
      the mysql exe file is in.
      prompt>cd c:\apache\mysql\bin
      Then I type the command to turn on mysql

      Now that apache and mysql are running you can go to the homepage
      at http://localhost , you can get to phpMyAdmin at
      http://localhost/phpmyadmin .

      To turn off apache you can just hit CTRL+C in the dos box that apache
      is running in.

      To turn off mysql type this at the prompt:
      c:\apache\mysql\bin>mysqladmin shutdown

      Of course you don't need to do any of this if you already have mysql
      But installing this and using phpMyAdmin will help ease you in to
      managing a
      mysql database.

      To talk to the mysql database with perl, you need to use the DBI.pm
      and in turn, DBI.pm needs mysql.pm . I installed the mysql driver
      easily using
      activestates ppm tool.
      Rich Taylor done showed you the basics of using DBI. DBI is pretty
      easy to use.

      Here's a tutorial on the SQL language http://www.sqlcourse.com/ ..

      If you can write perl, learning SQL shouldn't be that difficult,
      SQL seems to read more like English to me.
      The important thing is to make sure your database is
      designed well.
      Deciding what tables need to be linked to each other and how, etc..


      --- In perl-beginner@y..., Gordon Stewart <gordon52@s...> wrote:
      > Hi, I'm doing a crash course in SQL databases..
      > About 4-5 hours ago I knew NOTHING about SQL.. - Ive now
      > installed it on my system, & have done a "few" useful commands...
      > BUT :-
      > I have the SQL tutorial
      > However the commands are listed all over the place & chop-n-change
      > Windows, Unix, More Unix, Windows, Unix, Windows More Windows &
      Unix.. -
      > all-over the place & no summary /list (that i can find) of useful
      > Has anyone got any BASIC / Crash-course on useful SQL/Perl commands
      to do
      > via Perl from a Perl/Windows perspective ?
      > EG :-
      > Command 1 - Logging in as a user
      > Command 2 - Logging in as administrator
      > Command 3 - Create / edit a user
      > Just a brief summary of the command - & then a link to the 3-4
      pages of
      > HTML text explaining it all
      > (if / when i want to delve into it..)
      > If no site exists like that, I'll start typing / creating my own
      > document - with a summary of the commands...
      > PS - I know how to do some / a few commands via DOS/the command
      > - How is it done from within a Perl script ?
      > Hmm - Might go to bed soon - Almost 8 a.m. - Got 3 days to learn
      SQL - long
      > weekend...
      > G.
    Your message has been successfully submitted and would be delivered to recipients shortly.