hihi, mssql = sux
check out www.mysql.com
(or you maybe a really big bubu in your DB structure)
> Hi,
> I am just starting out with php and have managed to get it running OK on
my
> machine (Win2K) and connecting to an MSSQL 7 database on another machine
(on
> my LAN). However, it seems to run really slowly when accessing the
database.
> It takes around 6 seconds for my simple page to appear... At first I
thought
> that it was because I was running IIS so I tried installing Apache and
using
> that. It is no quicker.
> Pages that don't contain connections to the database appear much faster. I
> am using the mssql functions. So for example my script might look
something
> like this:
>
> $connection = mssql_pconnect($databaseServer, $databaseUsername,
> $databasePassword) or die("ERROR CONNECTING TO DATABASE");
> $database = mssql_select_db($databaseName);
> $getArticles = mssql_query($getArticlesSQL) or die("ERROR EXECUTING SQL");
> while($getArticlesResult = mssql_fetch_row($getArticles){
> $articleID = $getArticlesResult[0];
> $date = $getArticlesResult[1];
> $title = $getArticlesResult[2];
> $introText = $getArticlesResult[3];
> echo $articleID . $date . $title . $introText . "<br>
> }
>
> Is there a faster way to do this? As far as I can see in the docs this is
> the most efficient way to get a result set and loop through it. Or are the
> connections to a MSSQL database just slow from PHP?
> Thanks in advance for any help anyone can give me,
> Kelvin.
>
>
> --
> PHP Windows 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 Windows 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]