Perl Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming LanguagesPerl Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
1200+ fellow developers rate and compare features of the top IDEs, like Visual Studio, Eclipse, RAD, Delphi and others, across 13 categories. Enjoy this FREE Download of the IDE User Satisfaction Study by Evans Data Corporation. Download Now!
  #1  
Old February 27th, 2001, 06:54 PM
metric152 metric152 is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2001
Posts: 1 metric152 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Question

Does anyone know if it is possible to have perl connect to a mssql database. and if so how do you do it.

Reply With Quote
  #2  
Old February 28th, 2001, 01:00 AM
JonLed JonLed is offline
Contributing User
Dev Shed Novice (500 - 999 posts)
 
Join Date: Aug 2000
Location: Indiana
Posts: 614 JonLed User rank is Corporal (100 - 500 Reputation Level)JonLed User rank is Corporal (100 - 500 Reputation Level)JonLed User rank is Corporal (100 - 500 Reputation Level)JonLed User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 4 h 49 m 49 sec
Reputation Power: 9
You might look at the DBD module. I've personally never done it before, but I'm sure it's possiable somehow.

Reply With Quote
  #3  
Old February 28th, 2001, 06:43 AM
mickalo's Avatar
mickalo mickalo is offline
Ole` Timer
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2000
Location: N.W. Iowa
Posts: 469 mickalo User rank is Private First Class (20 - 50 Reputation Level)mickalo User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 5 h 19 sec
Reputation Power: 8
Send a message via AIM to mickalo Send a message via MSN to mickalo
Thumbs up

that should be the DBI module, DBD is the database driver, normally mysql.

Mickalo
__________________

Thunder Rain Internet Publishing

Custom Programming & Database development
Providing Personal/Business
Internet Solutions that work!

Reply With Quote
  #4  
Old February 28th, 2001, 09:02 AM
JonLed JonLed is offline
Contributing User
Dev Shed Novice (500 - 999 posts)
 
Join Date: Aug 2000
Location: Indiana
Posts: 614 JonLed User rank is Corporal (100 - 500 Reputation Level)JonLed User rank is Corporal (100 - 500 Reputation Level)JonLed User rank is Corporal (100 - 500 Reputation Level)JonLed User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 4 h 49 m 49 sec
Reputation Power: 9
Well I agree, except for the part it about it being normally for mysql. It is an ODBC driver, which is why I figured he'd have more luck with it. I'm not sure DBI supports msssql.

Reply With Quote
  #5  
Old February 28th, 2001, 09:06 AM
mickalo's Avatar
mickalo mickalo is offline
Ole` Timer
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 2000
Location: N.W. Iowa
Posts: 469 mickalo User rank is Private First Class (20 - 50 Reputation Level)mickalo User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 5 h 19 sec
Reputation Power: 8
Send a message via AIM to mickalo Send a message via MSN to mickalo
Quote:
Originally posted by JonLed
Well I agree, except for the part it about it being normally for mysql. It is an ODBC driver, which is why I figured he'd have more luck with it. I'm not sure DBI supports msssql.


I missed the mssql ! To used to seeing mysql

My mistake.

Mickalo

Reply With Quote
  #6  
Old February 28th, 2001, 09:07 AM
JonLed JonLed is offline
Contributing User
Dev Shed Novice (500 - 999 posts)
 
Join Date: Aug 2000
Location: Indiana
Posts: 614 JonLed User rank is Corporal (100 - 500 Reputation Level)JonLed User rank is Corporal (100 - 500 Reputation Level)JonLed User rank is Corporal (100 - 500 Reputation Level)JonLed User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 4 h 49 m 49 sec
Reputation Power: 9
Now that I read the docs, you can get a list of db drivers that dbi supports like this:
Code:
@ary = DBI->available_drivers;

You can just loop through that to print out a list and see if an mssql driver exists.

Reply With Quote
  #7  
Old February 28th, 2001, 11:58 AM
metric152 metric152 is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2001
Posts: 1 metric152 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Smile

Thanks alot guys. I checked it on our system but it doesnt look like it will allow it. They dont have a mssql driver installed for anything. I tried looking in php also and that was a no go. But it gave me what i need to know.

Reply With Quote
  #8  
Old February 28th, 2001, 08:58 PM
meeh82 meeh82 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2000
Location: Riverside, CA
Posts: 63 meeh82 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 8
You can access Oracle, flat files, MSSQL, MYSQL , etc. with perl and with PHP

If you go to http://www.zend.com you can look in the manual or go through the functions for PHP. You are going to need to use DBD::ODBC for perl to access a mssql database. You have to install DBI and in your connection string to the database you write

$db = DBI->connect('dbi:ODBC:$hostname:$dsn,$username,$password')

You can also access mysql through DBI. The package is called DBD::Mysql.


There is also a seperate package for mysql.
Mysql is the package name.

Jonathan Donaghe

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesPerl Programming > mssql and perl


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 6 hosted by Hostway