[PHP-DB] PHP MSSQL on Linux
A few months back I wrote the list asking for help making a connection to a MS SQL database from our linux webserver. At that time I was able to make a successfull connection on Fedora Core 1 after installing php-mssql.rpm and a freetds rpm. When I upgradd to FC4, I was unable to continue my project because the RPMs had not been built for PHP5.0.4, whic is the version we run now. Today, I was able to get the version of php-mssql I needed and installed it successfully. I am able to make a connection to our ms sql server using tsql. There is a mssql.ini file in the php.d directory and the mssql.so file is in /usr/lib/php/modules/. Using the get_loaded_extensions fuction, I see that mssql is a loaded module and the phpinfo() function shows me mssql configuration files. All indicators tell me that I should be able to connect. Obvsiously, since I'm posting to the list, you can guess that it's not working. The error message I get back is useless as I'm only told that the connection failed. Does anyone know anything else I need to check to get the connection working? Thank you, Robbert van Andel -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] PHP MSSQL on Linux
Is it from php or the mssql driver? If it's from the driver, then the library is installed at least partially correctly. If it's from php, perhaps not. From there you can narrow it down by checking the connection parameters outside of php to make sure they're right, is there a mssql client for linux? If the driver is loading, I would hope it would give better error messages than just 'connection failed'.. but as I've never used the driver I might be wrong. You can also packet sniff the network during the connection attempt to see what goes on there, there's lots of clues that could be helpful in the packet stream. -Micah On Tuesday 01 November 2005 2:30 pm, [EMAIL PROTECTED] wrote: A few months back I wrote the list asking for help making a connection to a MS SQL database from our linux webserver. At that time I was able to make a successfull connection on Fedora Core 1 after installing php-mssql.rpm and a freetds rpm. When I upgradd to FC4, I was unable to continue my project because the RPMs had not been built for PHP5.0.4, whic is the version we run now. Today, I was able to get the version of php-mssql I needed and installed it successfully. I am able to make a connection to our ms sql server using tsql. There is a mssql.ini file in the php.d directory and the mssql.so file is in /usr/lib/php/modules/. Using the get_loaded_extensions fuction, I see that mssql is a loaded module and the phpinfo() function shows me mssql configuration files. All indicators tell me that I should be able to connect. Obvsiously, since I'm posting to the list, you can guess that it's not working. The error message I get back is useless as I'm only told that the connection failed. Does anyone know anything else I need to check to get the connection working? Thank you, Robbert van Andel -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: Re: [PHP-DB] PHP MSSQL on Linux
The error I'm getting is from the PHP function. Both mssql_connect and PEAR are returning the same error. As far as I can tell, mssql only returns the last line of an error message so I can't be sure that the error I'm seeing is from MSSQL or PHP. Running TCPdump shows no traffic is going to my sql database from the webserver. But when I run tsql,it shows that communication occurred. This looks like a problem with my PHP configuration but I'm at a loss as to what it is. Robbert Micah Stevens [EMAIL PROTECTED] wrote on 11/01/2005, 11:55:52 PM: Is it from php or the mssql driver? If it's from the driver, then the library is installed at least partially correctly. If it's from php, perhaps not. From there you can narrow it down by checking the connection parameters outside of php to make sure they're right, is there a mssql client for linux? If the driver is loading, I would hope it would give better error messages than just 'connection failed'.. but as I've never used the driver I might be wrong. You can also packet sniff the network during the connection attempt to see what goes on there, there's lots of clues that could be helpful in the packet stream. -Micah On Tuesday 01 November 2005 2:30 pm, [EMAIL PROTECTED] wrote: A few months back I wrote the list asking for help making a connection to a MS SQL database from our linux webserver. At that time I was able to make a successfull connection on Fedora Core 1 after installing php-mssql.rpm and a freetds rpm. When I upgradd to FC4, I was unable to continue my project because the RPMs had not been built for PHP5.0.4, whic is the version we run now. Today, I was able to get the version of php-mssql I needed and installed it successfully. I am able to make a connection to our ms sql server using tsql. There is a mssql.ini file in the php.d directory and the mssql.so file is in /usr/lib/php/modules/. Using the get_loaded_extensions fuction, I see that mssql is a loaded module and the phpinfo() function shows me mssql configuration files. All indicators tell me that I should be able to connect. Obvsiously, since I'm posting to the list, you can guess that it's not working. The error message I get back is useless as I'm only told that the connection failed. Does anyone know anything else I need to check to get the connection working? Thank you, Robbert van Andel -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] PHP MSSQL on Linux
Hmm.. if you're using a function like mssql_error or something like that, it's likely coming from the driver and not php.. Did you see this on the docs page? I have spent the last 2 days trying to get PHP to connect to MSDE on Windows 2003 Web Edition. Although initally PHP would connect to the database without a problem, it would then refuse to connect, hitting F5 enough times would eventually connect to the database. As you can imagine this intermittent problem was hard to trace. I was using PHP 5.0.5 (although 5.0.4 has the same problem) on a Windows 2003 Web Edition SP1 server, and was trying to connect to MSDE Rel A. Solution: ~ Firstly MSDE needed to be installed with the following arguments: SECURITYMODE=SQL DISABLENETWORKPROTOCOLS=0. Secondly it was necessary to delete ntwdblib.dll from c:\php Thirdly I downloaded the SQL 2000 evaluation and installed only the client tools on a seperate PC (Ent. Manager will now connect to the database). Lastly I copied the version of ntwdblib.dll from the PC with Ent. Manager on it (ver 2000.80.2039.0) to c:\windows\system32\ After a re-boot no more connection problems. Pls note that this is only for 2003 Web Edition with MSDE, this problem does not seem to occour with Standard Edition -Micah On Tuesday 01 November 2005 3:18 pm, [EMAIL PROTECTED] wrote: The error I'm getting is from the PHP function. Both mssql_connect and PEAR are returning the same error. As far as I can tell, mssql only returns the last line of an error message so I can't be sure that the error I'm seeing is from MSSQL or PHP. Running TCPdump shows no traffic is going to my sql database from the webserver. But when I run tsql,it shows that communication occurred. This looks like a problem with my PHP configuration but I'm at a loss as to what it is. Robbert Micah Stevens [EMAIL PROTECTED] wrote on 11/01/2005, 11:55:52 PM: Is it from php or the mssql driver? If it's from the driver, then the library is installed at least partially correctly. If it's from php, perhaps not. From there you can narrow it down by checking the connection parameters outside of php to make sure they're right, is there a mssql client for linux? If the driver is loading, I would hope it would give better error messages than just 'connection failed'.. but as I've never used the driver I might be wrong. You can also packet sniff the network during the connection attempt to see what goes on there, there's lots of clues that could be helpful in the packet stream. -Micah On Tuesday 01 November 2005 2:30 pm, [EMAIL PROTECTED] wrote: A few months back I wrote the list asking for help making a connection to a MS SQL database from our linux webserver. At that time I was able to make a successfull connection on Fedora Core 1 after installing php-mssql.rpm and a freetds rpm. When I upgradd to FC4, I was unable to continue my project because the RPMs had not been built for PHP5.0.4, whic is the version we run now. Today, I was able to get the version of php-mssql I needed and installed it successfully. I am able to make a connection to our ms sql server using tsql. There is a mssql.ini file in the php.d directory and the mssql.so file is in /usr/lib/php/modules/. Using the get_loaded_extensions fuction, I see that mssql is a loaded module and the phpinfo() function shows me mssql configuration files. All indicators tell me that I should be able to connect. Obvsiously, since I'm posting to the list, you can guess that it's not working. The error message I get back is useless as I'm only told that the connection failed. Does anyone know anything else I need to check to get the connection working? Thank you, Robbert van Andel -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] PHP MSSQL on Linux
There's actually a few issues with php5 connecting that have solutions on this page: http://us2.php.net/manual/en/function.mssql-connect.php You may of read it already though.. On Tuesday 01 November 2005 3:24 pm, Micah Stevens wrote: Hmm.. if you're using a function like mssql_error or something like that, it's likely coming from the driver and not php.. Did you see this on the docs page? I have spent the last 2 days trying to get PHP to connect to MSDE on Windows 2003 Web Edition. Although initally PHP would connect to the database without a problem, it would then refuse to connect, hitting F5 enough times would eventually connect to the database. As you can imagine this intermittent problem was hard to trace. I was using PHP 5.0.5 (although 5.0.4 has the same problem) on a Windows 2003 Web Edition SP1 server, and was trying to connect to MSDE Rel A. Solution: ~ Firstly MSDE needed to be installed with the following arguments: SECURITYMODE=SQL DISABLENETWORKPROTOCOLS=0. Secondly it was necessary to delete ntwdblib.dll from c:\php Thirdly I downloaded the SQL 2000 evaluation and installed only the client tools on a seperate PC (Ent. Manager will now connect to the database). Lastly I copied the version of ntwdblib.dll from the PC with Ent. Manager on it (ver 2000.80.2039.0) to c:\windows\system32\ After a re-boot no more connection problems. Pls note that this is only for 2003 Web Edition with MSDE, this problem does not seem to occour with Standard Edition -Micah On Tuesday 01 November 2005 3:18 pm, [EMAIL PROTECTED] wrote: The error I'm getting is from the PHP function. Both mssql_connect and PEAR are returning the same error. As far as I can tell, mssql only returns the last line of an error message so I can't be sure that the error I'm seeing is from MSSQL or PHP. Running TCPdump shows no traffic is going to my sql database from the webserver. But when I run tsql,it shows that communication occurred. This looks like a problem with my PHP configuration but I'm at a loss as to what it is. Robbert Micah Stevens [EMAIL PROTECTED] wrote on 11/01/2005, 11:55:52 PM: Is it from php or the mssql driver? If it's from the driver, then the library is installed at least partially correctly. If it's from php, perhaps not. From there you can narrow it down by checking the connection parameters outside of php to make sure they're right, is there a mssql client for linux? If the driver is loading, I would hope it would give better error messages than just 'connection failed'.. but as I've never used the driver I might be wrong. You can also packet sniff the network during the connection attempt to see what goes on there, there's lots of clues that could be helpful in the packet stream. -Micah On Tuesday 01 November 2005 2:30 pm, [EMAIL PROTECTED] wrote: A few months back I wrote the list asking for help making a connection to a MS SQL database from our linux webserver. At that time I was able to make a successfull connection on Fedora Core 1 after installing php-mssql.rpm and a freetds rpm. When I upgradd to FC4, I was unable to continue my project because the RPMs had not been built for PHP5.0.4, whic is the version we run now. Today, I was able to get the version of php-mssql I needed and installed it successfully. I am able to make a connection to our ms sql server using tsql. There is a mssql.ini file in the php.d directory and the mssql.so file is in /usr/lib/php/modules/. Using the get_loaded_extensions fuction, I see that mssql is a loaded module and the phpinfo() function shows me mssql configuration files. All indicators tell me that I should be able to connect. Obvsiously, since I'm posting to the list, you can guess that it's not working. The error message I get back is useless as I'm only told that the connection failed. Does anyone know anything else I need to check to get the connection working? Thank you, Robbert van Andel -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] PHP MSSQL on Linux
See what perplexes me is that the extension seems to be installed (I uninstalled the php-mssql rpm and got an error that the extension wasn't installed). Reinstalling the rpm returned me to my original error that the connection failed. As I mentioned TCPDUMP tells me that there is no traffic going to my database server. The website where I got the php-mssql and freetds RPMs told me that I wouldn't need to recompile PHP but other sites tell me that I need to configure php with freetds. Since I'm running on a linux box, the solution to your problem doesn't apply to me. Thanks for your continued help, Robbert Micah Stevens [EMAIL PROTECTED] wrote on 11/02/2005, 12:24:48 AM: Hmm.. if you're using a function like mssql_error or something like that, it's likely coming from the driver and not php.. Did you see this on the docs page? I have spent the last 2 days trying to get PHP to connect to MSDE on Windows 2003 Web Edition. Although initally PHP would connect to the database without a problem, it would then refuse to connect, hitting F5 enough times would eventually connect to the database. As you can imagine this intermittent problem was hard to trace. I was using PHP 5.0.5 (although 5.0.4 has the same problem) on a Windows 2003 Web Edition SP1 server, and was trying to connect to MSDE Rel A. Solution: ~ Firstly MSDE needed to be installed with the following arguments: SECURITYMODE=SQL DISABLENETWORKPROTOCOLS=0. Secondly it was necessary to delete ntwdblib.dll from c:\php Thirdly I downloaded the SQL 2000 evaluation and installed only the client tools on a seperate PC (Ent. Manager will now connect to the database). Lastly I copied the version of ntwdblib.dll from the PC with Ent. Manager on it (ver 2000.80.2039.0) to c:\windows\system32\ After a re-boot no more connection problems. Pls note that this is only for 2003 Web Edition with MSDE, this problem does not seem to occour with Standard Edition -Micah On Tuesday 01 November 2005 3:18 pm, [EMAIL PROTECTED] wrote: The error I'm getting is from the PHP function. Both mssql_connect and PEAR are returning the same error. As far as I can tell, mssql only returns the last line of an error message so I can't be sure that the error I'm seeing is from MSSQL or PHP. Running TCPdump shows no traffic is going to my sql database from the webserver. But when I run tsql,it shows that communication occurred. This looks like a problem with my PHP configuration but I'm at a loss as to what it is. Robbert Micah Stevens wrote on 11/01/2005, 11:55:52 PM: Is it from php or the mssql driver? If it's from the driver, then the library is installed at least partially correctly. If it's from php, perhaps not. From there you can narrow it down by checking the connection parameters outside of php to make sure they're right, is there a mssql client for linux? If the driver is loading, I would hope it would give better error messages than just 'connection failed'.. but as I've never used the driver I might be wrong. You can also packet sniff the network during the connection attempt to see what goes on there, there's lots of clues that could be helpful in the packet stream. -Micah On Tuesday 01 November 2005 2:30 pm, [EMAIL PROTECTED] wrote: A few months back I wrote the list asking for help making a connection to a MS SQL database from our linux webserver. At that time I was able to make a successfull connection on Fedora Core 1 after installing php-mssql.rpm and a freetds rpm. When I upgradd to FC4, I was unable to continue my project because the RPMs had not been built for PHP5.0.4, whic is the version we run now. Today, I was able to get the version of php-mssql I needed and installed it successfully. I am able to make a connection to our ms sql server using tsql. There is a mssql.ini file in the php.d directory and the mssql.so file is in /usr/lib/php/modules/. Using the get_loaded_extensions fuction, I see that mssql is a loaded module and the phpinfo() function shows me mssql configuration files. All indicators tell me that I should be able to connect. Obvsiously, since I'm posting to the list, you can guess that it's not working. The error message I get back is useless as I'm only told that the connection failed. Does anyone know anything else I need to check to get the connection working? Thank you, Robbert van Andel -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] PHP MSSQL bug
Do you have permissions to run the query as the php/webserver user? Bastien From: Raul IONESCU [EMAIL PROTECTED] Reply-To: Raul IONESCU [EMAIL PROTECTED] To: php-db php-db@lists.php.net Subject: [PHP-DB] PHP MSSQL bug Date: Mon, 14 Mar 2005 09:16:40 +0200 I have created a stored procedure wich is accessing an remote linked MSSQL 2000 server and works perfectly from Querry Analyzer. The problem occurs when I try to execute the stored procedure from php 5.0.3 (by using mssql_bind or mssql_query); I've got no error but no result either. It seems that php doesn't allows to access remote linked servers! -- Raul IONESCU -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] PHP MSSQL bug
Yes, of course; I'm running under sa credentials so that's not the problem. On Mon, 14 Mar 2005 09:28:15 -0500, Bastien Koert [EMAIL PROTECTED] wrote: Do you have permissions to run the query as the php/webserver user? Bastien From: Raul IONESCU [EMAIL PROTECTED] Reply-To: Raul IONESCU [EMAIL PROTECTED] To: php-db php-db@lists.php.net Subject: [PHP-DB] PHP MSSQL bug Date: Mon, 14 Mar 2005 09:16:40 +0200 I have created a stored procedure wich is accessing an remote linked MSSQL 2000 server and works perfectly from Querry Analyzer. The problem occurs when I try to execute the stored procedure from php 5.0.3 (by using mssql_bind or mssql_query); I've got no error but no result either. It seems that php doesn't allows to access remote linked servers! -- Raul IONESCU -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Raul IONESCU -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] PHP MSSQL bug
Then, is it safe to assume that you can run stored procedures and queries that don't use a remote linked server? Fundamentally, I don't know why PHP would be the problem, since the remote link is established within the stored procedure. To make sure that it is not a problem with the mssql extension, you should see if the same problem occurs with the odbc or odbtp extensions. -- bob On Mon, 14 Mar 2005, Raul IONESCU wrote: Yes, of course; I'm running under sa credentials so that's not the problem. On Mon, 14 Mar 2005 09:28:15 -0500, Bastien Koert [EMAIL PROTECTED] wrote: Do you have permissions to run the query as the php/webserver user? Bastien From: Raul IONESCU [EMAIL PROTECTED] Reply-To: Raul IONESCU [EMAIL PROTECTED] To: php-db php-db@lists.php.net Subject: [PHP-DB] PHP MSSQL bug Date: Mon, 14 Mar 2005 09:16:40 +0200 I have created a stored procedure wich is accessing an remote linked MSSQL 2000 server and works perfectly from Querry Analyzer. The problem occurs when I try to execute the stored procedure from php 5.0.3 (by using mssql_bind or mssql_query); I've got no error but no result either. It seems that php doesn't allows to access remote linked servers! -- Raul IONESCU -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Raul IONESCU -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] PHP MSSQL bug
I have created a stored procedure wich is accessing an remote linked MSSQL 2000 server and works perfectly from Querry Analyzer. The problem occurs when I try to execute the stored procedure from php 5.0.3 (by using mssql_bind or mssql_query); I've got no error but no result either. It seems that php doesn't allows to access remote linked servers! -- Raul IONESCU -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] php mssql
Recently, I had to format my db server and when I re-attached the database, I noticed some unusal behavior. I have some fields in certain tables with a width of 60. When I would extract data from the table for that specific field, the data would contain extra blank chars. As a result, I am forced to use the trim function to get rid of the extra chars. This problem has never occured before and I now find it quite annoying. Does anybody have any ideas? Thanks, Dale -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] php mssql
Th cols are likely defined as CHAR not as VARCHAR. CHAR cols will pad out the length of the value to the full width of the column...change the type to varchar... bastien From: Dale Hersowitz [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: [PHP-DB] php mssql Date: Tue, 19 Oct 2004 09:36:25 -0700 Recently, I had to format my db server and when I re-attached the database, I noticed some unusal behavior. I have some fields in certain tables with a width of 60. When I would extract data from the table for that specific field, the data would contain extra blank chars. As a result, I am forced to use the trim function to get rid of the extra chars. This problem has never occured before and I now find it quite annoying. Does anybody have any ideas? Thanks, Dale -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] PHP - MSSQL - LINUX
Hi Madhu, I am speaking about MSSQL not MySQL . Is it possible can i get for MSSQL.so from MYSQL Installation. Thanks and Regards, Santhosh Kumar.M - Original Message - From: Madhu Manjari To: [EMAIL PROTECTED] Sent: Wednesday, March 17, 2004 2:27 PM Subject: Re: [PHP-DB] PHP - MSSQL - LINUX Hi Santosh Try to install mysql-3..22 source where you will get all libraries by default . After installation of mysql configure php support with mysql. Madhu. Hi All, Where do I get mssql.so to connect mssql with my PHP4.0.6 and PHP4.3.3 Regards, Santos Kumar.M -- This Message and any attachments is intended solely for the addresses and is confidential. If you receive this message in error or if you are not the intended recipient, please delete the mail. Any use not in accord with its purpose, any dissemination or disclosure, either whole or partial, is prohibited. Please inform us in case of erroneous delivery, thanks for your cooperation.
Re: [PHP-DB] PHP - MSSQL - LINUX
No, if you are attempting to run PHP under Windows, you want the MSSQL DLL File, if you are attempting to run PHP under Linux or Unix, you want to install FreeTDS from www.freetds.org On Wed, 2004-03-17 at 05:17, Santhosh Kumar wrote: Hi Madhu, I am speaking about MSSQL not MySQL . Is it possible can i get for MSSQL.so from MYSQL Installation. Thanks and Regards, Santhosh Kumar.M - Original Message - From: Madhu Manjari To: [EMAIL PROTECTED] Sent: Wednesday, March 17, 2004 2:27 PM Subject: Re: [PHP-DB] PHP - MSSQL - LINUX Hi Santosh Try to install mysql-3..22 source where you will get all libraries by default . After installation of mysql configure php support with mysql. Madhu. Hi All, Where do I get mssql.so to connect mssql with my PHP4.0.6 and PHP4.3.3 Regards, Santos Kumar.M -- This Message and any attachments is intended solely for the addresses and is confidential. If you receive this message in error or if you are not the intended recipient, please delete the mail. Any use not in accord with its purpose, any dissemination or disclosure, either whole or partial, is prohibited. Please inform us in case of erroneous delivery, thanks for your cooperation. -- Adam Voigt [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] PHP - MSSQL - LINUX
Open your php.ini file and uncomment the line: extension=php_mssql.dll Happy coding, Jimmy Brock -Original Message- From: Santhosh Kumar [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 17, 2004 5:17 AM To: PHP DB; [EMAIL PROTECTED] Subject: Re: [PHP-DB] PHP - MSSQL - LINUX Hi Madhu, I am speaking about MSSQL not MySQL . Is it possible can i get for MSSQL.so from MYSQL Installation. Thanks and Regards, Santhosh Kumar.M - Original Message - From: Madhu Manjari To: [EMAIL PROTECTED] Sent: Wednesday, March 17, 2004 2:27 PM Subject: Re: [PHP-DB] PHP - MSSQL - LINUX Hi Santosh Try to install mysql-3..22 source where you will get all libraries by default . After installation of mysql configure php support with mysql. Madhu. Hi All, Where do I get mssql.so to connect mssql with my PHP4.0.6 and PHP4.3.3 Regards, Santos Kumar.M -- This Message and any attachments is intended solely for the addresses and is confidential. If you receive this message in error or if you are not the intended recipient, please delete the mail. Any use not in accord with its purpose, any dissemination or disclosure, either whole or partial, is prohibited. Please inform us in case of erroneous delivery, thanks for your cooperation. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] PHP - MSSQL - LINUX
You will need to install and configure the FreeTDS library. Another alternative is to use ODBTP, which is available at http://odbtp.sourceforge.net. It is much easier to install and configure than FreeTDS, and supports all of the mssql_* functions. However, ODBTP requires a WIn32 service to be installed on the machine running SQL server, or some other Win32 machine that can be accessed by the Linux machine. If this is not a problem, you will be able to get connected more quickly, and with additional capabilities. -- bob On Wed, 17 Mar 2004, Santhosh Kumar wrote: Hi All, Where do I get mssql.so to connect mssql with my PHP4.0.6 and PHP4.3.3 Regards, Santos Kumar.M -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] PHP - MSSQL - LINUX
Hi All, Where do I get mssql.so to connect mssql with my PHP4.0.6 and PHP4.3.3 Regards, Santos Kumar.M
RE: [PHP-DB] PHP - MSSQL connects, but can't query
I changed the mssql_select_db line as suggested by another person here but it didn't change a thing. I still get the exact same error message. Is there anyone else here connecting to a MS SQL server using TDS v8.0 ?? Thanks! Jason -Original Message- From: Jason Morrill [mailto:[EMAIL PROTECTED] Sent: Friday, March 12, 2004 8:36 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] PHP - MSSQL connects, but can't query I've got a very simple PHP script for testing my MS SQL Server connection. I've installed FreeTDS and I can connect and query the database with TSQL. With PHP I can connect and disconnect properly but I can't query or attach to different databases. Here is my sample PHP followed by what the web server throws back at me: sql-test.php html body bgcolor=white ?php $dbproc = mssql_connect(roger,sa,admin); #$dbproc = sybase_connect(roger,sa,admin); if (! $dbproc) { print Can't connect to server; return; } print Connected to server.; $dbconnect = mssql_select_db(Northwind); if (! $dbconnect) { print Can't connect to Northwind; return; } print Connected to database; #$res = sybase_query(select * from test,$dbproc); #if (! $res) { # return; #} #while ($arr = sybase_fetch_array($res)) { # print $arr[i] . . $arr[v] . br\n; #} if (! mssql_close($dbproc)) { print Can't close server connection; return; } print Connection closed.; ? /body /html Output in browser when referencing the sql-test.php file: - Connected to server. Warning: Sybase: Server message: Line 1: Incorrect syntax near 'e'. (severity 15, procedure N/A) in /home/www/sql-test.php on line 12 Can't connect to Northwind Can anyone help me figure this one out?! Thanks! Jason Morrill IT Manager Child Family Agency SE Connecticut -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] PHP - MSSQL connects, but can't query
Yes, I'm connecting to a MSSQL server from FreeTDS, and it works fine. Try using the IP of the MSSQL server instead of the name, and see if that makes any difference. On Mon, 2004-03-15 at 09:23, Jason Morrill wrote: I changed the mssql_select_db line as suggested by another person here but it didn't change a thing. I still get the exact same error message. Is there anyone else here connecting to a MS SQL server using TDS v8.0 ?? Thanks! Jason -Original Message- From: Jason Morrill [mailto:[EMAIL PROTECTED] Sent: Friday, March 12, 2004 8:36 AM To: [EMAIL PROTECTED] Subject: [PHP-DB] PHP - MSSQL connects, but can't query I've got a very simple PHP script for testing my MS SQL Server connection. I've installed FreeTDS and I can connect and query the database with TSQL. With PHP I can connect and disconnect properly but I can't query or attach to different databases. Here is my sample PHP followed by what the web server throws back at me: sql-test.php html body bgcolor=white ?php $dbproc = mssql_connect(roger,sa,admin); #$dbproc = sybase_connect(roger,sa,admin); if (! $dbproc) { print Can't connect to server; return; } print Connected to server.; $dbconnect = mssql_select_db(Northwind); if (! $dbconnect) { print Can't connect to Northwind; return; } print Connected to database; #$res = sybase_query(select * from test,$dbproc); #if (! $res) { # return; #} #while ($arr = sybase_fetch_array($res)) { # print $arr[i] . . $arr[v] . br\n; #} if (! mssql_close($dbproc)) { print Can't close server connection; return; } print Connection closed.; ? /body /html Output in browser when referencing the sql-test.php file: - Connected to server. Warning: Sybase: Server message: Line 1: Incorrect syntax near 'e'. (severity 15, procedure N/A) in /home/www/sql-test.php on line 12 Can't connect to Northwind Can anyone help me figure this one out?! Thanks! Jason Morrill IT Manager Child Family Agency SE Connecticut -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Adam Voigt [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] PHP - MSSQL connects, but can't query
I've got a very simple PHP script for testing my MS SQL Server connection. I've installed FreeTDS and I can connect and query the database with TSQL. With PHP I can connect and disconnect properly but I can't query or attach to different databases. Here is my sample PHP followed by what the web server throws back at me: sql-test.php html body bgcolor=white ?php $dbproc = mssql_connect(roger,sa,admin); #$dbproc = sybase_connect(roger,sa,admin); if (! $dbproc) { print Can't connect to server; return; } print Connected to server.; $dbconnect = mssql_select_db(Northwind); if (! $dbconnect) { print Can't connect to Northwind; return; } print Connected to database; #$res = sybase_query(select * from test,$dbproc); #if (! $res) { # return; #} #while ($arr = sybase_fetch_array($res)) { # print $arr[i] . . $arr[v] . br\n; #} if (! mssql_close($dbproc)) { print Can't close server connection; return; } print Connection closed.; ? /body /html Output in browser when referencing the sql-test.php file: - Connected to server. Warning: Sybase: Server message: Line 1: Incorrect syntax near 'e'. (severity 15, procedure N/A) in /home/www/sql-test.php on line 12 Can't connect to Northwind Can anyone help me figure this one out?! Thanks! Jason Morrill IT Manager Child Family Agency SE Connecticut -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] PHP - MSSQL connects, but can't query
Hmm, replace the line where you select the DB with: $dbconnect = mssql_select_db(Northwind) or die(mssql_get_last_message()); (All on one line incase the email wraps it.) On Fri, 2004-03-12 at 08:35, Jason Morrill wrote: I've got a very simple PHP script for testing my MS SQL Server connection. I've installed FreeTDS and I can connect and query the database with TSQL. With PHP I can connect and disconnect properly but I can't query or attach to different databases. Here is my sample PHP followed by what the web server throws back at me: sql-test.php html body bgcolor=white ?php $dbproc = mssql_connect(roger,sa,admin); #$dbproc = sybase_connect(roger,sa,admin); if (! $dbproc) { print Can't connect to server; return; } print Connected to server.; $dbconnect = mssql_select_db(Northwind); if (! $dbconnect) { print Can't connect to Northwind; return; } print Connected to database; #$res = sybase_query(select * from test,$dbproc); #if (! $res) { # return; #} #while ($arr = sybase_fetch_array($res)) { # print $arr[i] . . $arr[v] . br\n; #} if (! mssql_close($dbproc)) { print Can't close server connection; return; } print Connection closed.; ? /body /html Output in browser when referencing the sql-test.php file: - Connected to server. Warning: Sybase: Server message: Line 1: Incorrect syntax near 'e'. (severity 15, procedure N/A) in /home/www/sql-test.php on line 12 Can't connect to Northwind Can anyone help me figure this one out?! Thanks! Jason Morrill IT Manager Child Family Agency SE Connecticut -- Adam Voigt [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] PHP - MsSQL - DB error connect failed
It is not directly PHP but it is Db with PHP/Linux Linux 2.4.19-4GB Apache: httpd-2.0.48 php-4.3.4 freetds-0.61.2 I have php pages to connect to MsSQL-2000 server $conn = mssql_connect($server, $user, $pass) or die ; or (PEAR:Db) $dsn = mssql://$user:[EMAIL PROTECTED]/$dbname; if (DB::isError($db)) {die ($db-getMessage()); } PHP-pages with these instructions worked this morning. Later and still now: DB error connect failed : impossible to connect now. I suspect the MsSQL server to be overloaded. Other users (Windows) are connecting via piped names Myself (on Linux) connect via IP-address If I reboot in Windows-2000 (Dual-boot system): no problem to access Db (piped name). If I make a test (on Linux) with tsql (FreeTDS): connection OK Only problem is to try connecting through Apache/PHP on Linux via IP-Address I had once problem making a DHCP enquiry on a Windows server from a Linux Host and I had to increase the TimeOut thus I wondered if I do not have the same problem now. I checked thus /www/conf/php.ini I uncommented the lines: mssql.connect_timeout = 10 mssql.timeout = 60 and tried higher numbers but without success. Apache/PHP don't seem to repeat the request till success. If anybody knows of a way to awake or shake MsSQL (apart from blowing it). Of course, the obvious is to install MySQL bur I am not the master here. -- Alain Barthélemy [EMAIL PROTECTED] http://bartydeux.be Linux User #315631 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] PHP - MsSQL - DB error connect failed
Le Wednesday 21 January 2004, 12:54:18 ou environ Robert Twitty [EMAIL PROTECTED] a écrit: Hi again Bob, It was about 13h00 (13 pm) when you sent this mail and about 8 pm here. Thus give me time to go back to work tomorrow morning and to study the question. If interested I contact again. Good Night, Alain Hi Alain ODBTP is a protocol that provides remote access to WIn32-based ODBC drivers. More details are available at http://odbtp.sourceforge.net. I created it because PHP's mssql ext did not adequately support SQL Server 7.0 and 2000. The main problem with this ext is that on UNIX it was built with FreeTDS, a reengineered and sometimes faulty version of the TDS protocol. On Windows it was built with the obsolete and unsupported DB-Library, which does not support ntext or varchar(255) data types. ODBTP provides the best access to MSSQL because it uses the ODBC driver for SQL Server by Microsoft. It is faster than the FreeTDS version, and is equal in speed to the DB-Library version. Version 1.0 is publically available at SourceForge. Version 1.1 will be released soon. This version should interest you because it provides support for all of the mssql_* functions. Let me know if you want to try it. -- bob On Wed, 21 Jan 2004, Alain [iso-8859-15] Barthélemy wrote: Le Wednesday 21 January 2004, 10:33:38 ou environ Robert Twitty [EMAIL PROTECTED] a écrit: Hi Bob, ODBC - ODBTP? I thought of installing the ODBC driver but I read it was still in development and not fully operational and as long as FreeTDS worked ... Of course, I have not heard of ODBTP yet but I am not a specialist of Windows. Hi Alain Would you like to try a better solution for connecting to MSSQL? It does not use FreeTDS, and will not require you to change your code. It's called ODBTP. -- bob On Wed, 21 Jan 2004, Alain [iso-8859-15] Barthélemy wrote: It is not directly PHP but it is Db with PHP/Linux Linux 2.4.19-4GB Apache: httpd-2.0.48 php-4.3.4 freetds-0.61.2 I have php pages to connect to MsSQL-2000 server $conn = mssql_connect($server, $user, $pass) or die ; or (PEAR:Db) $dsn = mssql://$user:[EMAIL PROTECTED]/$dbname; if (DB::isError($db)) {die ($db-getMessage()); } PHP-pages with these instructions worked this morning. Later and still now: DB error connect failed : impossible to connect now. I suspect the MsSQL server to be overloaded. Other users (Windows) are connecting via piped names Myself (on Linux) connect via IP-address If I reboot in Windows-2000 (Dual-boot system): no problem to access Db (piped name). If I make a test (on Linux) with tsql (FreeTDS): connection OK Only problem is to try connecting through Apache/PHP on Linux via IP-Address I had once problem making a DHCP enquiry on a Windows server from a Linux Host and I had to increase the TimeOut thus I wondered if I do not have the same problem now. I checked thus /www/conf/php.ini I uncommented the lines: mssql.connect_timeout = 10 mssql.timeout = 60 and tried higher numbers but without success. Apache/PHP don't seem to repeat the request till success. If anybody knows of a way to awake or shake MsSQL (apart from blowing it). Of course, the obvious is to install MySQL bur I am not the master here. -- Alain Barthélemy [EMAIL PROTECTED] http://bartydeux.be Linux User #315631 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] php mssql tcpip
I used to use named pipes to connect to a remote sql server. My nt department removed anonymous access account and now I have to use tcpip. Since the change the performance of the php quering has decreased. it takes more time to load the page. anything to look at in the sql configs or in the php.ini file to speed up the tcpip query? Any other ideas would be great. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] php mssql tcpip
Thoughts... I've used mssql via PHP on linux via tcp/ip 1433 with good success and performance.. Never used named pipes (I'm assuming you have to be an entire ms environment to do that) You might check into timing the process, perhaps the tcp/ip login is taking longer for authentication against the mssql server as it could be anybody connecting. Might add some timing code into that.. Also depending on how busy things are, be sure all your webservers + sql systems are hooked together 100MB or faster fully switched network.. , using named pipes, the sqlserver I would assum On Thu, 21 Aug 2003, JD wrote: I used to use named pipes to connect to a remote sql server. My nt department removed anonymous access account and now I have to use tcpip. Since the change the performance of the php quering has decreased. it takes more time to load the page. anything to look at in the sql configs or in the php.ini file to speed up the tcpip query? Any other ideas would be great. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] PHP MSSQL
Shaun, the MySQL manual suggests that you have hit your limit using the VARCHAR field type (255 characters). To store 6,000 characters have you not considered using the TEXT field type? 6.2.3.1 The CHAR and VARCHAR Types The CHAR and VARCHAR types are similar, but differ in the way they are stored and retrieved. The length of a CHAR column is fixed to the length that you declare when you create the table. The length can be any value between 1 and 255. (As of MySQL Version 3.23, the length of CHAR may be 0 to 255.) When CHAR values are stored, they are right-padded with spaces to the specified length. When CHAR values are retrieved, trailing spaces are removed. Values in VARCHAR columns are variable-length strings. You can declare a VARCHAR column to be any length between 1 and 255, just as for CHAR columns. However, in contrast to CHAR, VARCHAR values are stored using only as many characters as are needed, plus one byte to record the length. Values are not padded; instead, trailing spaces are removed when values are stored. (This space removal differs from the SQL-99 specification.) No case conversion takes place during storage or retrieval. If you assign a value to a CHAR or VARCHAR column that exceeds the column's maximum length, the value is truncated to fit. - Original Message - From: Shaun Bentley [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, August 11, 2003 11:23 AM Subject: [PHP-DB] PHP MSSQL Hi I am currently trying to use PHP and MSSQL together but I am having a few problems. I can enter data into the Db OK, but when pulling the data back to display on the page, the string cuts to around 250 chars. The Db field is VarChar 6000 and I can see the whole data in the field. I have tried pulling the data out as object, array row but always lose the end. Any help please! Shaun -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.506 / Virus Database: 303 - Release Date: 01/08/2003 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] PHP MSSQL
This is true if Shaun was using MySQL, but he is using MSSQL. MSSQL allowas you to declare char and varchar fields with lengths up to 8000 characters. Unfortunately the extension bundled with PHP cannot read beyond the first 255 characters. This is primarily due to the fact that the extension was built using DB-LIB, which does not adequately support all of the new data types introduced in MSSQL 7.0 and 2000. -- bob On Mon, 11 Aug 2003, Matthew McNicol wrote: Shaun, the MySQL manual suggests that you have hit your limit using the VARCHAR field type (255 characters). To store 6,000 characters have you not considered using the TEXT field type? 6.2.3.1 The CHAR and VARCHAR Types The CHAR and VARCHAR types are similar, but differ in the way they are stored and retrieved. The length of a CHAR column is fixed to the length that you declare when you create the table. The length can be any value between 1 and 255. (As of MySQL Version 3.23, the length of CHAR may be 0 to 255.) When CHAR values are stored, they are right-padded with spaces to the specified length. When CHAR values are retrieved, trailing spaces are removed. Values in VARCHAR columns are variable-length strings. You can declare a VARCHAR column to be any length between 1 and 255, just as for CHAR columns. However, in contrast to CHAR, VARCHAR values are stored using only as many characters as are needed, plus one byte to record the length. Values are not padded; instead, trailing spaces are removed when values are stored. (This space removal differs from the SQL-99 specification.) No case conversion takes place during storage or retrieval. If you assign a value to a CHAR or VARCHAR column that exceeds the column's maximum length, the value is truncated to fit. - Original Message - From: Shaun Bentley [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, August 11, 2003 11:23 AM Subject: [PHP-DB] PHP MSSQL Hi I am currently trying to use PHP and MSSQL together but I am having a few problems. I can enter data into the Db OK, but when pulling the data back to display on the page, the string cuts to around 250 chars. The Db field is VarChar 6000 and I can see the whole data in the field. I have tried pulling the data out as object, array row but always lose the end. Any help please! Shaun -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.506 / Virus Database: 303 - Release Date: 01/08/2003 -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] PHP MSSQL
Hi I am currently trying to use PHP and MSSQL together but I am having a few problems. I can enter data into the Db OK, but when pulling the data back to display on the page, the string cuts to around 250 chars. The Db field is VarChar 6000 and I can see the whole data in the field. I have tried pulling the data out as object, array row but always lose the end. Any help please! Shaun -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] php, mssql and french accents
hi, The charset used on my sql server is : Character Set = 1, iso_1 ISO 8859-1 (Latin-1) - Western European 8-bit character set. Where can I change these settings ? Ben [EMAIL PROTECTED] (Edwin Boersma) wrote in news:[EMAIL PROTECTED]: Your code page setting might be wrong. Edwin Benjamin Masdoua wrote: Hello, I'm developping an application using php and mssql. I have problems with french accents, when I insert something from php, and i consult it by enterprise manager (sql server) the accents are replaced, example paté becomes patÚ and if I insert something from enterprise manager and get teh value by php, the accents are also replaced and not by the same as the first situation example : paté becomes pat, any idea ? Benjamin Masdoua ABS-Integration Toulouse. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] php, mssql and french accents
Hello, I'm developping an application using php and mssql. I have problems with french accents, when I insert something from php, and i consult it by enterprise manager (sql server) the accents are replaced, example paté becomes patÚ and if I insert something from enterprise manager and get teh value by php, the accents are also replaced and not by the same as the first situation example : paté becomes pat, any idea ? Benjamin Masdoua ABS-Integration Toulouse. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] php, mssql and french accents
Your code page setting might be wrong. Edwin Benjamin Masdoua wrote: Hello, I'm developping an application using php and mssql. I have problems with french accents, when I insert something from php, and i consult it by enterprise manager (sql server) the accents are replaced, example paté becomes patÚ and if I insert something from enterprise manager and get teh value by php, the accents are also replaced and not by the same as the first situation example : paté becomes pat, any idea ? Benjamin Masdoua ABS-Integration Toulouse. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] PHP - MSSQL
Folks... I have a situation where I need a Visual Basic program, running on a win2k server to store some data. I later need a PHP script to come along, retrieve and parse that data. I have a MS SQL server running on the win2k server along with the VP program. I then have a RedHat/Apache box that the PHP script is running on, which also has MySQL. My first thought was to have the VP app store the data in a MS SQL table (since this is the easiest for the VP programmer), and then I (the PHP programmer) would have to figure out how to connect the the MS SQL table with PHP. I know this is possible, but I've also heard it can be messy (recompiling PHP. installing odbc drivers which sometimes give errors etc). The other option, is to do it the other way around. Have the VB guy write the data to a MySQL table, which then would be a piece of cake for me to retrieve with PHP. What I don't know, is how easy it is for VB to talk to MySQL. Anyone have experience with either way? I know PHP fairly well, but I'm not too sure about the installation/compiling/etc process to get odbc working. Any tips or advice would be appreciated. Thanks! Joseph -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP-DB] PHP - MSSQL
First make a odbc DSN to the MSSQL database. Here is a code sample of how I connect to my MSSQL server via PHP. This is inside my class_db.php class Db { var $datasource;// Data source á server var $username; var $password; var $connect; // Connect strengurinn function Db() //Smiður klasa - default constructor { $this-datasource = vcdmssql; // the name of the DSN $this-username = misteruser; // your username $this-password = somepass; // and password $this-connect = odbc_connect($this-datasource, $this-username, $this-password); } function sql($sql_string) { return odbc_exec($this-connect, $sql_string); } function fjoldi($recordset) { return odbc_num_rows($recordset); } } Then make a new instance of the class .. $db = new db; $query = SELECT id,name from movies; $get = $db-sql($query); // make the query while (odbc_fetch_row($get)) // walk through all results { $id = odbc_result($get,1); $name = odbc_result($get,2); echo $name has id $id; } Hope this helps, Greetings, Konni. -Original Message- From: Joseph Szobody [mailto:[EMAIL PROTECTED]] Sent: 20. september 2002 22:44 To: [EMAIL PROTECTED] Subject: [PHP-DB] PHP - MSSQL Folks... I have a situation where I need a Visual Basic program, running on a win2k server to store some data. I later need a PHP script to come along, retrieve and parse that data. I have a MS SQL server running on the win2k server along with the VP program. I then have a RedHat/Apache box that the PHP script is running on, which also has MySQL. My first thought was to have the VP app store the data in a MS SQL table (since this is the easiest for the VP programmer), and then I (the PHP programmer) would have to figure out how to connect the the MS SQL table with PHP. I know this is possible, but I've also heard it can be messy (recompiling PHP. installing odbc drivers which sometimes give errors etc). The other option, is to do it the other way around. Have the VB guy write the data to a MySQL table, which then would be a piece of cake for me to retrieve with PHP. What I don't know, is how easy it is for VB to talk to MySQL. Anyone have experience with either way? I know PHP fairly well, but I'm not too sure about the installation/compiling/etc process to get odbc working. Any tips or advice would be appreciated. Thanks! Joseph -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] php mssql* functions
Because of the limitations of MS SQL Server and the inability to limit result sets as you are in MySQL, I am having to finesse/brute force a method to peruse through large result sets. My question is this: How exactly does the mssql_fetch_array() function work? Does it make a call to the db server for each fetch, or is the entire result set returned from the db server and stored locally in memory and the fetch call just pulls it from there? I suppose it makes little difference in the final design, since I'll need to have the functionality anyway, I was just curious about what kind of overhead I'd be creating. Thanks, Jeremy -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-DB] PHP MSSQL, IIS Question -- Size Question
What version of php are you using ? Handling of binary data from MSSQL Server was changed from php4.0.5 to php4.0.6. As far as I can tell You should not have any problems with php4.0.6 - Frank I am preparing a report for a database at my company that will be shown on the web. It has several nested tables and such in it. One of the fields to show is a blob field. If the blob field is too long, IIS will hang, and not be able to render the table. If the blob field is less than 2K it is fine. Sometimes it is bigger. If I remove the blob field from showing it always works fine, on every record. If I put the blob field in, it will hang on certain records but not all. How can I increase IIS's or PHP's buffer size so that it will render the entire page correctly everytime? Joshua -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DB] PHP MSSQL, IIS Question -- Size Question
I am preparing a report for a database at my company that will be shown on the web. It has several nested tables and such in it. One of the fields to show is a blob field. If the blob field is too long, IIS will hang, and not be able to render the table. If the blob field is less than 2K it is fine. Sometimes it is bigger. If I remove the blob field from showing it always works fine, on every record. If I put the blob field in, it will hang on certain records but not all. How can I increase IIS's or PHP's buffer size so that it will render the entire page correctly everytime? Joshua -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DB] PHP , MSSQL and ODBC
Hey all - I would like to connect to a MSSQL server and do not know how. I have only worked with MySQL which is pretty easy to set up. Can you tell me how to go about this? Do I need to set up ODBC first? I imagine that it is not as simple as MySQL but will not be much different. Thanks much, olinux _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] php - MSSQL
As someone else has noted, the ODBC functions are one way. Another way, particularly if you prefer to talk to the database directly rather than through a translation layer, is to install the FreeTDS libraries (http://www.freetds.org/) on your Linux machine and then build PHP with the --with-sybase configuration parameter. This will enable the mssql_* functions. Hello, Please tell me : Does it work with MS SQL server 2000. How build freetds (--what ?) ? snpe -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DB] php - MSSQL
Hi there. Is there any possible way to connect PHP (running on apache 1.3.12 on Red Hat Linux 7) with Microsoft SQL server (running on Windows 2000) ? Dragan Dinic, Serbia -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] php - MSSQL
On Mon, May 14, 2001 at 12:11:17PM +0200, Dragan Dinic wrote: Hi there. Hi. Is there any possible way to connect PHP (running on apache 1.3.12 on Red Hat Linux 7) with Microsoft SQL server (running on Windows 2000) ? Yes -- Jason Stechschulte [EMAIL PROTECTED] -- Perl itself is usually pretty good about telling you what you shouldn't do. :-) -- Larry Wall in [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] php MSSQL problem
What is the problem you're having? Are you trying to change setting in the PHP.INI file and they are not reflecting in the scripts or is PHP returning some other sort of error saying it could not locate PHP.INI? ""Robert"" [EMAIL PROTECTED] wrote in message 000c01c080c1$960de3b0$d5245ed1@tech2000">news:000c01c080c1$960de3b0$d5245ed1@tech2000... php 4.0.5-dev / IIS 4 / Win NT 4 Server / MSSQL 6.5 It looks like PHP is ignoring my php.ini file ( in c:\winnt\ ) I make changes, restart IIS and do a phpinfo() the changes do not show up I tried copying the php.ini file to c:\ c:\winnt\ c:\winnt\system32\ and even made a c:\windows folder to copy it to. Nothing worked. Am I missing something here? -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]