Thanks for some help. I will look into that. This is not my database so I am
not sure how or why it was setup this way. There is more than 255 characters
in each of these fields.
"@ Edwin" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Hello,
>
> ...just wondering...
>
> Are you sure VARCHAR in MS SQL can handle 5000? Should be 255 only? (I'm
not
> really familiar with MS SQL but you can count the number of characters
> returned by php...)
>
> - E
>
>
> "Christopher J. Crane" <[EMAIL PROTECTED]> wrote in message
> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> > I wrote a simple script to return data from a query. The database is MS
> SQL
> > and the field I am looking to return is a VARCHAR(5000). Everything
seems
> to
> > work except the data returned is not the whole field it is shortened. It
> > only returns a portion of the field.
> >
> > Here is the field:
> > 99 Services, Inc. is a full service IT systems integrator and general
> > contractor specializing in cradle to grave technology planning with
strong
> > emphasis on LAN/WAN design (routing and switching) and deployment of
high
> > speed, fully redundant, high availability networks. 99 Services also
> > provides Internet/Intranet/Website/email systems design.  The company
> > services small to medium sized businesses as well as home offices.
> >
> > Here is what is returned by the PHP:
> > 99 Services, Inc. is a full service IT systems integrator and general
> > contractor specializing in cradle to grave technology planning with
strong
> > emphasis on LAN/WAN design (routing and switching) and deployment of
high
> > speed, fully redundant, high availab
> >
> >
> > Here is the script:
> > <?PHP
> > /* CTC Profile about Company */
> > /* ========================= */
> >     $HostName = "DAS54-DAL-SBC";
> >     $UserName = "*******"; //changed for security
> >     $Password = "********"; //changed for security
> >     $DBName = "DirectoryDB";
> >
> >     MSSQL_CONNECT($HostName,$UserName,$Password);
> >     mssql_select_db($DBName) or DIE("Table unavailable");
> >
> >     $ProfileResults = MSSQL_QUERY("SELECT * FROM CompanyProfile WHERE
> > CompanyID = '$ID'");
> >     $RowCount = MSSQL_NUM_ROWS($ProfileResults);
> >
> >     if($RowCount != 0) {
> >       for ($i = 0; $Field2 = MSSQL_FETCH_ARRAY($ProfileResults); ++$i) {
> >   $Profile = $Field2["Profile"];
> >         echo $Field2["CompanyID"] . "<br>" . $Field2["Profile"] .
> > "<br><br>To read more information about this ";
> >         echo "company, visit their website\n";
> >      }
> >    }
> >  else { print "This company, $sym is not listed in the CTC
Directory."; }
> >
> >     MSSQL_CLOSE();
> > ?>
> >
> >
>



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

Reply via email to