473,624 Members | 2,269 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

command line ODBC connection problem

Hello

This is my problem:
I hava a php script which collect data from a remote IBM DB2 AS400 ,
and puts them on a local MYSQL server.
Calling it from a browser, it's fine.

I want to launch it from command line using CLI ($php script.php)
to put it in a cron job.
Not working!

It gives an error line like: " odbc_connect(): SQL error: , SQL state
è\@ø in SQLConnect".

After "SQL state" are not readable characters.

The error seems to be in the odbc_connect() statement?

Any ideas?
Can I solve it, or have to go back to PERL? (Don't want to!)

thanks
huge

Jan 12 '06 #1
6 2132
php experts, ah!

no answers....well , thank you.

Jan 13 '06 #2
hugenin wrote:
php experts, ah!

no answers....well , thank you.

Let's see...
Your problem statement:

I have a problem with my ODBC connection from the command line although
it works from the web server.

I'm not going to show you the code...I expect you experts to infer it
from my description.

I'm not going to mention things like what OS I'm on, what version of PHP
I have or even what parameters I am using for the connection since
experts such as yourself don't need annoying details like that.

I'm going to threaten to go back to perl unless you can help me.

If you don't help me within 26 hours, I will taunt you with a sarcastic
message.

Gosh! Who wouldn't *jump* at the chance to help you? You make it *so* easy.

-david-

Jan 13 '06 #3
you see David...
had to be sarcastic to get an answer!

Was too hard to say "post the code, please"???
This was the first time I asked for help here,
I understand I had to post more information. My fault.

anyway, I solved the problem, it was easy...no perl!

bye David.

huge

Jan 13 '06 #4
hugenin wrote:
you see David...
had to be sarcastic to get an answer!
No, you had to ask a second time. You didn't need to be sarcastic.
Was too hard to say "post the code, please"???
This was the first time I asked for help here,
I understand I had to post more information. My fault.
I keep being amazed (I suppose I shouldn't be, by now) at how bad many
people are at reporting problems (including some of the professional
software developers who are my colleagues).

Yours was actually better than many - you said what you were trying to
do and you even said what result you got (you'd be amazed how many
people looking for help just say it 'didn't work').

But you anyway, I solved the problem, it was easy...no perl!

bye David.

huge

I'm glad you solved your problem, but I have a great deal of sympathy
with David's reply. I don't think you would have got such a sarcastic
reply if you hadn't posted your aggressive second posting.

Of course, given you hadn't had a reply in the first 24 hours you
probably wouldn't have got one - because there was not enough
information in your original posting.

I work
Jan 15 '06 #5
I had heard from another post-er that MySQL ab started to disable mysql
stuff in command-line PHP due to licensing issues.

"hugenin" <hu*****@gmail. com> wrote in message
news:11******** **************@ g49g2000cwa.goo glegroups.com.. .
you see David...
had to be sarcastic to get an answer!

Was too hard to say "post the code, please"???
This was the first time I asked for help here,
I understand I had to post more information. My fault.

anyway, I solved the problem, it was easy...no perl!

bye David.

huge

Jan 25 '06 #6
"Jim Michaels" <jm******@yahoo .com> wrote in message
news:kY******** *************** *******@comcast .com...
I had heard from another post-er that MySQL ab started to disable mysql
stuff in command-line PHP due to licensing issues.
yup. tried something simple from the command-line.
PHP Fatal error: Call to undefined function mysql_connect() in
C:\php5.1.2\tes t.php on line 2


"hugenin" <hu*****@gmail. com> wrote in message
news:11******** **************@ g49g2000cwa.goo glegroups.com.. .
you see David...
had to be sarcastic to get an answer!

Was too hard to say "post the code, please"???
This was the first time I asked for help here,
I understand I had to post more information. My fault.

anyway, I solved the problem, it was easy...no perl!

bye David.

huge


Jan 25 '06 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
5203
by: Sean Anderson | last post by:
ODBC under System DSN Setup Access Driver give it the DSN (Data Source Name) MSA Click on Select and point to the myfile.mdb (your database file)
5
4368
by: Bruno Alexandre | last post by:
Hi guys, withou using SP, I want to be able to add a Parameter to the SQL Query and retrive the Recordset so I can use the Paging property under the recorset object.... how can I do this? I'm stuck here.
5
102527
by: SerGioGio | last post by:
Hello, I am going nuts. I am trying to connect to my local ORACLE instance using ODBC. It used to work few weeks ago, but it fails now. Connection with: - SQL*plus: connection works! - DataDirect 5.0 Oracle Wire protocol (3rd party ODBC driver): connection works when I hit the driver's "test connection"
6
14589
by: Paul Deverson | last post by:
I'm a newbie to MySQL and am really confused about when I should be using the Command Line Client and when the DOS prompt. I'm using Windows XP and I've just installed MySQL 4.1.10. I can use the Command Line Client to logon as 'root'. It prompts me for a password and then I can create databases, etc. from the mysql prompt. However, if I wanted to logon as a different user, I'm not sure how to do it.
4
3566
by: Dave | last post by:
Hey guys, I have an ODBC problem that has me stumped. I wrote a VBA script to run in Microsoft Excel that pulls data out of an application using that application's ODBC driver and puts it into Excel. I am trying to translate the same program over to Microsoft Access and I ran into a problem. Access locks up if the data I am querying for is not present in the database. To retrieve data from the database of the application, my Excel...
0
1573
by: Steve Bishop | last post by:
I have a form with a search text box and a grid that displays the results. Within the grid, I have edit command links set up to response.redirect to another page that puts the DataKey value in the query string. The problem is, when I return to my initial page and do another search by entering a value in the text box then hitting enter, it takes that value and sends it to the other page as if I hit the edit link within the grid. Help...
4
5150
by: George Shawn | last post by:
Hi, I am running into an extremely frustrating problem and after hours of troubleshooting have not made any progress. When I try to use the ADO Command object to update a table, I receive the following error message: Microsoft OLE DB Provider for ODBC Drivers error '80040e10' No value given for one or more required parameters.
0
6368
by: marc.holt | last post by:
Please help! I am attempting to extract data from a Sage Line 50 database ( .dta extention) via an ODBC connection. Included in the application install of Sage Line 50, is an ODBC driver. I have successfully managed to extract data from other SQL databases using ODBC connections with no errors. The php code I am using is:
1
1706
by: bradwest1217 | last post by:
I am having a problem running a server command line executable from my web application. What is happening is I cannot make a database connection using the command line application (written in VB.net). Here is the error I get when doing it. ERROR ERROR SQL Server does not exist or access denied. ERROR ConnectionOpen (Connect()). ERROR Invalid connection string attribute at System.Data.Odbc.OdbcConnection.Open() at...
0
8675
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8619
jinu1996
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8334
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7158
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6108
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4078
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4173
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2604
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1784
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.