hello i m new to php
i m working on project that has interface with simple html and php i m
thinking to use
i got some problem with the connecting to DB here is the code for
connecting db
$db = "Snmp_Dba";
// $connection_id = odbc_connect_custom($db);
$db_connection = odbc_connect("DRIVER={Microsoft Access Driver
(*.mdb)}; DBQ=$db", "ADODB.Connection", "", "SQL_CUR_USE_ODBC");
// $query = "SELECT * FROM System_Master";
//$result_id = odbc_exec($connection_id,$query);
$result = odbc_tables($db_connection);
while (odbc_fetch_row($result)) {
if(odbc_result($result,"TABLE_TYPE")=="TABLE") {
echo "<br />" . odbc_result($result,"TABLE_NAME");
?>
by doing this i got error in ie as follows
Parse error: parse error in c:\program files\easyphp1-8\www\search.php
on line 25
any body help me to slove this problem
Thanks
Vijay 3 1478
BigZero wrote:
hello i m new to php
i m working on project that has interface with simple html and php i m
thinking to use
i got some problem with the connecting to DB here is the code for
connecting db
$db = "Snmp_Dba";
// $connection_id = odbc_connect_custom($db);
$db_connection = odbc_connect("DRIVER={Microsoft Access Driver
(*.mdb)}; DBQ=$db", "ADODB.Connection", "", "SQL_CUR_USE_ODBC");
// $query = "SELECT * FROM System_Master";
//$result_id = odbc_exec($connection_id,$query);
$result = odbc_tables($db_connection);
while (odbc_fetch_row($result)) {
if(odbc_result($result,"TABLE_TYPE")=="TABLE") {
echo "<br />" . odbc_result($result,"TABLE_NAME");
?>
by doing this i got error in ie as follows
Parse error: parse error in c:\program files\easyphp1-8\www\search.php
on line 25
any body help me to slove this problem
Thanks
Vijay
Which is line 25?
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp. js*******@attglobal.net
==================
On Apr 26, 7:05*am, BigZero <vijaymajagaon...@gmail.comwrote:
hello i m new to php
i m working on project that has interface with simple html and php i m
thinking to use
i got some problem with the connecting to DB here is the code for
connecting db
$db = "Snmp_Dba";
* // *$connection_id = odbc_connect_custom($db);
$db_connection = odbc_connect("DRIVER={Microsoft Access Driver
(*.mdb)}; DBQ=$db", "ADODB.Connection", "", "SQL_CUR_USE_ODBC");
* *// $query * * * * = "SELECT * FROM System_Master";
* * //$result_id * * = odbc_exec($connection_id,$query);
$result = odbc_tables($db_connection);
while (odbc_fetch_row($result)) {
* * if(odbc_result($result,"TABLE_TYPE")=="TABLE") {
* * * * echo "<br />" . odbc_result($result,"TABLE_NAME");
?>
by doing this i got error in ie as follows
Parse error: parse error in c:\program files\easyphp1-8\www\search.php
on line 25
any body help me to slove this problem
Thanks
Vijay
I think this
$db_connection = odbc_connect("DRIVER={Microsoft Access Driver
(*.mdb)}; DBQ=$db", "ADODB.Connection", "", "SQL_CUR_USE_ODBC");
needs to be this
$db_connection = odbc_connect("DRIVER={Microsoft Access Driver
(*.mdb)}; DBQ=" . $db, "ADODB.Connection", "", "SQL_CUR_USE_ODBC");
Thanks
i got solution for that,
i chabged UserDsn to SystemDSN setting in control panel
and all did change in code is
$con = odbc_connect('MSAccessDriver','','');
any way thanks
Regards
Vijay This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Google Mike |
last post by:
After a lot of thought and research, and playing with FreeTDS and
InlineTDS, as well as various ODBC connections, I have determined that
the fastest and cheapest way to get up and going with PHP on...
|
by: bigoxygen |
last post by:
Hi.
I am experiencing problems connecting to MSSQL.
I'm not sure where to begin looking for the problem.
I don't know if the problem is originating with PHP or MSSQL
What should the host name...
|
by: TP |
last post by:
Hi,
This is probably my 7th post of the day. not spamming, just want to
get the questions out, so that I can find the answers and post them
back or some good soul can help me out.
Right now I...
|
by: Ann Marinas |
last post by:
Hi all,
I would like to ask for some help regarding separating the asp.net
webserver and the sql server.
I have created an asp.net application for a certain company. Initially,
we installed...
|
by: peshekeedweller |
last post by:
Using asp.net 1.1. vb.net 2003.
I am trying to connect to a remote sql server 2000 on a virtual machine
running windows 2000 server. I can connect through the server explorer in
visual studio,...
|
by: cj.snead |
last post by:
Hello,
I am having trouble connecting to a remote named instance of SQL Server
via Pocket PC. I have had absolutely no luck connecting with VS 2005
(even to a default instance), so I wen't back...
|
by: =?Utf-8?B?R2lkaQ==?= |
last post by:
Hi,
I've my win32 application which connecting to my sql database.
till now i used MSDE as my database and now i want to upgrade to sql express
2005. after the upgrade i tried to connect to the...
|
by: mairhtin o'feannag |
last post by:
Hello,
I'm having problems connecting to my new v9 db box. The pertinent
information is below:
DB2_db2inst1 60000/tcp
DB2_db2inst1_1 60001/tcp
DB2_db2inst1_2 60002/tcp
DB2_db2inst1_END...
|
by: asafok |
last post by:
hi ,
for some reason every time i try connecting to my northwind sql server from VS2005 i get an Error massage.
first it was the remote connection that didn't allow me to connect and after that i...
|
by: taylorcarr |
last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
| |