Re: [PHP-DB] Does PHP5 support querying an MS Access MDE file?

2009-11-03 Thread Richard Quadling
2009/11/2 Timothy Legg php_l...@timothylegg.com:
 Hello,

 I have PHP Version 5.2.6-1+lenny3

 I have been having difficulty using odbc_connect with an MS Access MDE
 database.  I do have php5-mysql and php5-odbc installed on this server.

 Due to the rather poor search results regarding the topic of querying MDE
 files with PHP, I am becoming increasingly concerned that this file type
 is not supported.

 Is it possible to query an MDE file via PHP5 or should I try different
 approach to querying the database from our linux server?  I am interested
 in your thoughts.

 Thanks for your help.

 Tim Legg


 --
 PHP Database Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php



If you have the MS Access ODBC driver installed, then have you tried
accessing the MDE as an MDB?



-- 
-
Richard Quadling
Standing on the shoulders of some very clever giants!
EE : http://www.experts-exchange.com/M_248814.html
Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498r=213474731
ZOPA : http://uk.zopa.com/member/RQuadling

--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP-DB] Doc to PDF with mssql

2009-11-03 Thread Rafael Costa Pimenta
Hi
someone knows how to convert a word .doc to a PDF using PHP?

and how to store and retrieve a .doc file in a mssql database?


Re: [PHP-DB] Does PHP5 support querying an MS Access MDE file?

2009-11-03 Thread Timothy Legg
 2009/11/2 Timothy Legg php_l...@timothylegg.com:
 Hello,

 I have PHP Version 5.2.6-1+lenny3

 I have been having difficulty using odbc_connect with an MS Access MDE
 database. Â I do have php5-mysql and php5-odbc installed on this server.

 Due to the rather poor search results regarding the topic of querying
 MDE
 files with PHP, I am becoming increasingly concerned that this file type
 is not supported.

 Is it possible to query an MDE file via PHP5 or should I try different
 approach to querying the database from our linux server? Â I am
 interested
 in your thoughts.

 Thanks for your help.

 Tim Legg


 If you have the MS Access ODBC driver installed, then have you tried
 accessing the MDE as an MDB?


Yes, I have.  The username and password are arbitrarily set since the
management hasn't provided that data for me yet.  But I am not far enough
along to have run into a user rights issue.  I get a warning and also an
error upon interpreting the page.  I have checked the path to the database
file, and it is correct.  I also checked file ownership and readability
permissions, too.  So maybe the name of the driver is wrong; it does look
a little verbose to me, but it did come straight from the php.net online
documentation.

Error messages and source is below.  Sorry, I modified the domain name in
the path for privacy.

Warning: odbc_connect() [function.odbc-connect]: SQL error:
[unixODBC][Driver Manager]Data source name not found, and no default
driver specified, SQL state IM002 in SQLConnect in
/var/www/www.example.com/ht-secure/database_entry/test.php on line 9


?php
$mdbFilename = /root/tims_db.mde;
$user = root;
$password = 1248163264;

$connection = odbc_connect(Driver={Microsoft Access Driver
(*.mdb)};Dbq=$mdbFilename, $user, $password);

?

Thanks for looking this over,

Tim Legg



 --
 -
 Richard Quadling
 Standing on the shoulders of some very clever giants!
 EE : http://www.experts-exchange.com/M_248814.html
 Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498r=213474731
 ZOPA : http://uk.zopa.com/member/RQuadling




-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DB] Does PHP5 support querying an MS Access MDE file?

2009-11-03 Thread Richard Quadling
2009/11/3 Timothy Legg php_l...@timothylegg.com:
 2009/11/2 Timothy Legg php_l...@timothylegg.com:
 Hello,

 I have PHP Version 5.2.6-1+lenny3

 I have been having difficulty using odbc_connect with an MS Access MDE
 database. Â I do have php5-mysql and php5-odbc installed on this server.

 Due to the rather poor search results regarding the topic of querying
 MDE
 files with PHP, I am becoming increasingly concerned that this file type
 is not supported.

 Is it possible to query an MDE file via PHP5 or should I try different
 approach to querying the database from our linux server? Â I am
 interested
 in your thoughts.

 Thanks for your help.

 Tim Legg


 If you have the MS Access ODBC driver installed, then have you tried
 accessing the MDE as an MDB?


 Yes, I have.  The username and password are arbitrarily set since the
 management hasn't provided that data for me yet.  But I am not far enough
 along to have run into a user rights issue.  I get a warning and also an
 error upon interpreting the page.  I have checked the path to the database
 file, and it is correct.  I also checked file ownership and readability
 permissions, too.  So maybe the name of the driver is wrong; it does look
 a little verbose to me, but it did come straight from the php.net online
 documentation.

 Error messages and source is below.  Sorry, I modified the domain name in
 the path for privacy.

 Warning: odbc_connect() [function.odbc-connect]: SQL error:
 [unixODBC][Driver Manager]Data source name not found, and no default
 driver specified, SQL state IM002 in SQLConnect in
 /var/www/www.example.com/ht-secure/database_entry/test.php on line 9


 ?php
 $mdbFilename = /root/tims_db.mde;
 $user = root;
 $password = 1248163264;

 $connection = odbc_connect(Driver={Microsoft Access Driver
 (*.mdb)};Dbq=$mdbFilename, $user, $password);

 ?

 Thanks for looking this over,

 Tim Legg



 --
 -
 Richard Quadling
 Standing on the shoulders of some very clever giants!
 EE : http://www.experts-exchange.com/M_248814.html
 Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498r=213474731
 ZOPA : http://uk.zopa.com/member/RQuadling





You've got odbc, but probably not a driver for MS Access.

You need both.

I can't seem to find a unix driver for MSAccess.

Converting to a different DB would help (mysql, sqlite).

-- 
-
Richard Quadling
Standing on the shoulders of some very clever giants!
EE : http://www.experts-exchange.com/M_248814.html
Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498r=213474731
ZOPA : http://uk.zopa.com/member/RQuadling

--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DB] Does PHP5 support querying an MS Access MDE file?

2009-11-03 Thread Niel Archer
 2009/11/3 Timothy Legg php_l...@timothylegg.com:
  2009/11/2 Timothy Legg php_l...@timothylegg.com:
  Hello,
 
  I have PHP Version 5.2.6-1+lenny3
 
  I have been having difficulty using odbc_connect with an MS Access MDE
  database. Â I do have php5-mysql and php5-odbc installed on this server.
 
  Due to the rather poor search results regarding the topic of querying
  MDE
  files with PHP, I am becoming increasingly concerned that this file type
  is not supported.
 
  Is it possible to query an MDE file via PHP5 or should I try different
  approach to querying the database from our linux server? Â I am
  interested
  in your thoughts.
 
  Thanks for your help.
 
  Tim Legg
 
 
  If you have the MS Access ODBC driver installed, then have you tried
  accessing the MDE as an MDB?
 
 
  Yes, I have.  The username and password are arbitrarily set since the
  management hasn't provided that data for me yet.  But I am not far enough
  along to have run into a user rights issue.  I get a warning and also an
  error upon interpreting the page.  I have checked the path to the database
  file, and it is correct.  I also checked file ownership and readability
  permissions, too.  So maybe the name of the driver is wrong; it does look
  a little verbose to me, but it did come straight from the php.net online
  documentation.
 
  Error messages and source is below.  Sorry, I modified the domain name in
  the path for privacy.
 
  Warning: odbc_connect() [function.odbc-connect]: SQL error:
  [unixODBC][Driver Manager]Data source name not found, and no default
  driver specified, SQL state IM002 in SQLConnect in
  /var/www/www.example.com/ht-secure/database_entry/test.php on line 9
 
 
  ?php
  $mdbFilename = /root/tims_db.mde;
  $user = root;
  $password = 1248163264;
 
  $connection = odbc_connect(Driver={Microsoft Access Driver
  (*.mdb)};Dbq=$mdbFilename, $user, $password);
 
  ?
 
  Thanks for looking this over,
 
  Tim Legg
 
 
 
  --
  -
  Richard Quadling
  Standing on the shoulders of some very clever giants!
  EE : http://www.experts-exchange.com/M_248814.html
  Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498r=213474731
  ZOPA : http://uk.zopa.com/member/RQuadling
 
 
 
 
 
 You've got odbc, but probably not a driver for MS Access.
 
 You need both.
 
 I can't seem to find a unix driver for MSAccess.
 
 Converting to a different DB would help (mysql, sqlite).

I had a similar problem. I had to access (pardon the pun) a very old MS
Access db. Being on x64 windows ODBC is not an option, so in the end I
used OpenOffice.org with a java driver to open it and copy data to MySQL.

 -- 
 -
 Richard Quadling
 Standing on the shoulders of some very clever giants!
 EE : http://www.experts-exchange.com/M_248814.html
 Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498r=213474731
 ZOPA : http://uk.zopa.com/member/RQuadling
 
 -- 
 PHP Database Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php
 

--
Niel Archer
niel.archer (at) blueyonder.co.uk



--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DB] Doc to PDF with mssql

2009-11-03 Thread Chris

Rafael Costa Pimenta wrote:

Hi
someone knows how to convert a word .doc to a PDF using PHP?


There are external tools available to do it.

http://doc2pdf.sourceforge.net/overview.html is one such tool.

After installing it you exec the binary:

exec('pdf2doc blah blah');

where 'blah blah' is whatever pdf2doc tells you to put in.


and how to store and retrieve a .doc file in a mssql database?


I searched for 'mssql binary data' and found this article:

http://www.databasejournal.com/features/mssql/article.php/1475641/Storing-and-Retrieving-Binary-Data-in-SQL-Server.htm

--
Postgresql  php tutorials
http://www.designmagick.com/


--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php