CodeCharge Studio
search Register Login  

Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> CodeChargeStudio.Discussion

 Local Database vs. Remote

Print topic Send  topic

Author Message
DataDoIt
Posted: 12/17/2003, 8:06 AM

CCS 2.0; FrontPage 2000; Access 2000; MySQL; PHP4; Apache 1.3

This is the first time I'm attempting this, as I've been developing directly
to a remote MySQL database.

I would like to develope locally to an MS Access database, and publish
remotely to an MySQL database. The language is PHP. I've set up the
connections, remote using ODBC and local using MS OLE DB. Both connections
connect okay when tested. However, when I attempt to view a test page
locally (which should run against MS Access), I get:

Warning: mysql_pconnect(): Can't connect to MySQL server on 'localhost'
(10061) in c:\usr\www\fundorg_secure\db_mysql.php on line 97
Database error: pconnect(, , $DBPassword) failed.
MySQL Error: 0 ()
Session halted.

Am I wrong in thinking that I can develope locally using PHP against an
Access database, and publish the same code remotely using PHP against an
MySQL database, and CCS would be "smart" enough to figure all this out for
me?

Thanks.

-Mike R.

DataDoIt
Posted: 12/17/2003, 8:21 AM

"DataDoIt" <mike@datadoit.com> wrote in message
news:brputq$ad2$1@news.codecharge.com...
> CCS 2.0; FrontPage 2000; Access 2000; MySQL; PHP4; Apache 1.3
>
> This is the first time I'm attempting this, as I've been developing
directly
> to a remote MySQL database.
>
> I would like to develope locally to an MS Access database, and publish
> remotely to an MySQL database. The language is PHP. I've set up the
> connections, remote using ODBC and local using MS OLE DB. Both
connections
> connect okay when tested. However, when I attempt to view a test page
> locally (which should run against MS Access), I get:
>
> Warning: mysql_pconnect(): Can't connect to MySQL server on 'localhost'
> (10061) in c:\usr\www\fundorg_secure\db_mysql.php on line 97
> Database error: pconnect(, , $DBPassword) failed.
> MySQL Error: 0 ()
> Session halted.
>
> Am I wrong in thinking that I can develope locally using PHP against an
> Access database, and publish the same code remotely using PHP against an
> MySQL database, and CCS would be "smart" enough to figure all this out for
> me?
>
> Thanks.
>
> -Mike R.
---------------------------------------

Changed the local connection to use ODBC driver for Access instead of using
OLE DB, and all is well.

-Mike R.

DonB
Posted: 12/17/2003, 11:08 AM

Also be wary of the differences in datatypes (particularly the "boolean" and
what means true vs. what means false). You might find different results in
production MySQL after you tested against Access. And also, there is the
obvious caution against using a Querydef in Access because there are no
Views in MySQL (yet).

--
DonB

http://www.gotodon.com/ccbth


"DataDoIt" <mike@datadoit.com> wrote in message
news:brpvql$be9$1@news.codecharge.com...
> "DataDoIt" <mike@datadoit.com> wrote in message
>news:brputq$ad2$1@news.codecharge.com...
> > CCS 2.0; FrontPage 2000; Access 2000; MySQL; PHP4; Apache 1.3
> >
> > This is the first time I'm attempting this, as I've been developing
> directly
> > to a remote MySQL database.
> >
> > I would like to develope locally to an MS Access database, and publish
> > remotely to an MySQL database. The language is PHP. I've set up the
> > connections, remote using ODBC and local using MS OLE DB. Both
> connections
> > connect okay when tested. However, when I attempt to view a test page
> > locally (which should run against MS Access), I get:
> >
> > Warning: mysql_pconnect(): Can't connect to MySQL server on 'localhost'
> > (10061) in c:\usr\www\fundorg_secure\db_mysql.php on line 97
> > Database error: pconnect(, , $DBPassword) failed.
> > MySQL Error: 0 ()
> > Session halted.
> >
> > Am I wrong in thinking that I can develope locally using PHP against an
> > Access database, and publish the same code remotely using PHP against an
> > MySQL database, and CCS would be "smart" enough to figure all this out
for
> > me?
> >
> > Thanks.
> >
> > -Mike R.
> ---------------------------------------
>
> Changed the local connection to use ODBC driver for Access instead of
using
> OLE DB, and all is well.
>
> -Mike R.
>
>

Kevin
Posted: 12/18/2003, 9:31 AM

You have to understand why CCS uses two databases:
The first connector under
"Project/Settings/Connections/NAMEOFYOURCONNECTOR/Modify or Add" is the
"Design" connector
The "Design" connector is designed to use ODBC, the Drop down list tells CCS
which type of database you are using but your still using an ODBC connector.
This connector can be any source (that is supported in the drop down list)
that has an ODBC driver like MySQL or Access.
The Server connector can be an ODBC source or a LIBRARY source. A LIBRARY
source means you have a database that has provided a (Windows) .DLL with
database access code that CCS can use to access the database, the drop down
"PHP Database Library:" window lists the supported LIBRARIES. The Server
connector can also be an ODBC connector.

When you have the Connection setup correctly the Test button on the
Connection tab test the Design connector only. The Design connection is
where CCS gets it's information about the table structures BUT when you
click on Live Page the data is coming from the Server connector.
In other words: The Design connections data is only viewed while building
grids and records for a view of the page switches to the Server connection.

I have ask CCS to put a check box on the Server connector that says "Use for
Design". Keeping three databases in sync sucks and having to build an ODBC
connector to a MySQL database means you have to add a second user to the
MySQL server with rights to remotely access the database (if your MySQL
server in not local).

I have "local" Linux servers that I use to develop then I FTP from the
development servers to the production servers, if the production servers
disappear I can recreate them in minutes.. We have started to migrate to
PostgreSQL as MySQL is not supported with PHP5.


"DataDoIt" <mike@datadoit.com> wrote in message
news:brputq$ad2$1@news.codecharge.com...
> CCS 2.0; FrontPage 2000; Access 2000; MySQL; PHP4; Apache 1.3
>
> This is the first time I'm attempting this, as I've been developing
directly
> to a remote MySQL database.
>
> I would like to develope locally to an MS Access database, and publish
> remotely to an MySQL database. The language is PHP. I've set up the
> connections, remote using ODBC and local using MS OLE DB. Both
connections
> connect okay when tested. However, when I attempt to view a test page
> locally (which should run against MS Access), I get:
>
> Warning: mysql_pconnect(): Can't connect to MySQL server on 'localhost'
> (10061) in c:\usr\www\fundorg_secure\db_mysql.php on line 97
> Database error: pconnect(, , $DBPassword) failed.
> MySQL Error: 0 ()
> Session halted.
>
> Am I wrong in thinking that I can develope locally using PHP against an
> Access database, and publish the same code remotely using PHP against an
> MySQL database, and CCS would be "smart" enough to figure all this out for
> me?
>
> Thanks.
>
> -Mike R.
>
>


   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

PHP Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright 2003-2004 by UltraApps.com  and YesSoftware, Inc.