Ask a Question related to PHP Development, Design and Development.

  1. #1

    Default Re: PHP/msSQL

    On Wed, 25 Jun 2003 17:04:18 -0400, Adam wrote:
    > Is there a url that explains how to either compile it or add the modules
    > cause I have no idea heh..
    >
    > Thanks!!
    >
    > -Adam!
    >
    > "sotto" <junk@sotto.be> wrote in message
    > news:pan.2003.06.25.18.03.02.346271@sotto.be...
    >> On Wed, 25 Jun 2003 13:23:57 -0400, Adam wrote:
    >>
    >> > Hello everyone, looking for some help here..
    >> >
    >> > I have PHP 4.2.2 running on my windows server and im trying to figure
    > out
    >> > what I need to do, so that I can connect to an existing msSQL Server
    > 2000.
    >> >
    >> >
    >> > The only facts about PHP I have are version: 4.2.2, Server API: CGI
    >> >
    >> > I have no idea where to begin, or what needs to be done, all I know is
    >> > that I need to get msSQL and PHP working together.
    >> >
    >> > -Both are on the same win2k webserver.
    >> >
    >> > Thanks in advance!
    >> >
    >> > -Adam
    >>
    >> Probably you need to compile your php-server with msSQL support, or add
    >> some mssql support via modules (i know it's like that for PostGreSQL ...
    >> so i guess it would be the same for mssql)
    >>
    >> Anyway, when you got that working, you can use this "layer" to access
    >> your database: [url]http://php.weblogs.com/portable_sql[/url] (to me it seems like
    >> usefull thing)
    >>
    >>
    Yes there is.
    let me tell you: [url]www.google.com[/url] ... and i'd say you search for php+mysql
    howto

    hmm... i tried it for you just right now ... guess what??? OOoohh i found
    something usefull i think!

    [url]http://www.phpbuilder.com/columns/alberto20000919.php3[/url]


    ps, sorry, i get pissed off sometimes when people don't try google before
    asking help.

    sotto Guest

  2. Similar Questions and Discussions

    1. PHP MSSQL
      I have been searching for an extension to use with Dreamweaver that supports a PHP-Microsoft SQL model vs. PHP-MySQL. The latter has been fun, but...
    2. Help with MSSQL/PHP
      Hi wondering if anyone can help. What i'm trying to do is get a company from a MSSQL database with the COMPANYNO which is a 'uniqueidentifier'....
    3. php x MsSql
      Hello to all. I'm creating a site using php with database MsSql, when i test in my server using Win XP x php 4.3.2 it's all ok, but when i send...
    4. [PHP] php x MsSql
      * Thus wrote João Cândido de Souza Neto (joao@mrmidia.com.br): My bet: diff winXP/php.ini linux/php.ini < magic_quote_sybase = 1 Curt -- ...
    5. mssql.dll
      Where is mssql.dll (not include in packages 4.1.2 / 4.2.3 / 4.3.2 ? Thanks
  3. #2

    Default Re: PHP/msSQL

    Hi sotto!

    On Thu, 26 Jun 2003 18:41:26 +0200, "sotto" <junk@sotto.be> wrote:
    >Yes there is.
    >let me tell you: [url]www.google.com[/url] ... and i'd say you search for php+mysql
    >howto
    >
    Must be a typo.He is looking for PHP and Microsoft (MS) SQL



    Jochen
    --
    Jochen Daum - CANS Ltd.
    PHP DB Edit Toolkit -- PHP scripts for building
    database editing interfaces.
    [url]http://sourceforge.net/projects/phpdbedittk/[/url]
    Jochen Daum Guest

  4. #3

    Default Re: PHP/msSQL

    hmm ok, ill look into that dll file, and i did try google first :D
    But mysql is easy to make work, microsoft is not as easy.

    so far anyway..

    Thanks guys!


    "Jochen Daum" <jochen.daum@cans.co.nz> wrote in message
    news:btckfvsg0m6ulho9g4ch2ca5d4770ctv6i@4ax.com...
    > Hi !
    >
    > On Wed, 25 Jun 2003 13:23:57 -0400, "Adam" <adoeler@sharklogic.com>
    > wrote:
    >
    > >Hello everyone, looking for some help here..
    > >
    > >I have PHP 4.2.2 running on my windows server and im trying to figure out
    > >what I need to do, so that I can connect to an existing msSQL Server
    2000.
    > >
    > >
    > >The only facts about PHP I have are version: 4.2.2, Server API: CGI
    > >
    > >I have no idea where to begin, or what needs to be done, all I know is
    that
    > >I need to get msSQL and PHP working together.
    > >
    > >-Both are on the same win2k webserver.
    > >
    > I think you need to enable the mssql extension - something like
    > php_mssql.dll in php.ini
    >
    > Thats it as far as I know
    >
    > Jochen
    > --
    > Jochen Daum - CANS Ltd.
    > PHP DB Edit Toolkit -- PHP scripts for building
    > database editing interfaces.
    > [url]http://sourceforge.net/projects/phpdbedittk/[/url]

    Adam Guest

  5. #4

    Default PHP/MSSQL

    Hi there.

    Tried a number of methods.

    I basically want to extract a GUID from a MSSQL database and use it in
    another SELECT.

    When I get the company name and company no the company no outputs like...
    63180001000000000000000000000000

    I wanted to reference another table so I...
    $query = "SELECT ACTIVITYHEADERNO,COMPANYNO FROM ACTIVITYHEADER WHERE
    COMPANYNO='$companyno'";

    And of course this wouldn't work and the error was:

    Warning: Sybase message: Syntax error converting from a character string to
    uniqueidentifier.

    I have been looking at...

    [url]http://uk.php.net/manual/en/function.mssql-guid-string.php[/url]

    But when using mssql_guid_string i get...

    Fatal error: Call to undefined function: mssql_guid_string() in
    /export/home/darrenm/web/scripts/guid.php on line 32.

    php-4.3.1
    freetds-0.61

    and yes it was compiled with --enable-msdblib --with-tdsver=7.0

    If i do...

    $query = "SELECT cast(COMPANYNO as varchar(36)),USERSTRING1 FROM CONTACT
    WHERE USERSTRING1='$iusername'";

    it gets one result (which is correct) but COMPANYNO is blank when i try and
    print it (because it's something that can't be printed? i have no idea!)


    Any help would be great!

    Thank you very much.

    Darren


    Darren Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139