473,569 Members | 2,782 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

ODBC, MySQL & PHP

Hi,

I am trying to update data from a Lotus Notes Database to a MySQL via
ODBC and always get a currupted table. Since I want to update only a
certain set of the data, I first write the necessary data from the OBDC
into a temp table, then delete the old data from the target table and
copy the new data from the temp into the targe table. I have no IDs in
the lotus notes table so thats the only way I think I can do that.

I am running the query with

odbc_connect(.. .)
then
odbc_exec(...)
then
While (odbc_fetch_row (...)) {
....

[here is a query that takes the row with odbc_results and writes then
into a temp table.]
....

}

then I do a
odbc_close(...)

now I delete from the target
then insert all the data from the temp to the target
Drop the temp table.

In the end, the targe table always has a wrong number of records etc.
I am ussuming that since the ODBC call takes quite some time, that this
might be an issue. Can it be that the php script continues running down
the script while the ODBC is still working? How can I assure that
everything is running step by step instead of simultaneous in case?

thanks

Oliver

Jul 17 '05 #1
0 1416

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

Similar topics

0
1574
by: Wedrowiec | last post by:
I have a problem for experienced programmers. The following code should copy data between two different databases: import dbi,odbc conn1=odbc.odbc('mysql'); conn2=odbc.odbc('sqlite') c1 = conn1.cursor(); c2 = conn2.cursor() c1.execute("SELECT field1, field2 FROM table1") rows = c1.fetchall() c2.executemany('INSERT INTO table1...
3
1437
by: David | last post by:
Hi, Quick question, We have a Cobalt Qube 3 Server running Linux & Chilisoft asp. At the moment my asp applications pull data from the installed MySQL database which is fed data via MS Access (via ODBC) which is used as our in-house front-end between 3 staff doing data entry. We are now possibly looking to implement an ERP/MRP solution...
3
2743
by: Steve Farber | last post by:
I'm not especially new to databases and I have used ODBC before with other data sources, but I cannot seem to get Access 2003 to talk to MySQL 4.0.15. I have MySQL running with new tables defined, but I cannot get a connection to those tables via ODBC using MyODBC 3.51. Can anyone point the way? Many thanks,
11
17534
by: DJJ | last post by:
I am using the MySQL ODBC 3.51 driver to link three relatively small MySQL tables to a Microsoft Access 2003 database. I am finding that the data from the MySQL tables takes a hell of a long time to load making any kind linkage with my Access data virtually useless. I have the MySQL driver setup in as a USER DSN. The MySQL data is...
2
2236
by: uli2003wien | last post by:
Dear group, we are dealing with some very specific problems with ODBC, where a connection from SQL-Server to Mysql works with ODBC-driver 3.51.10.00 and does NOT work with ODBC-driver 3.51.11.00. Maybe someone experiences similar problems or even has a solution ? Some feedback (to the group) would be highly appreciated. We use a...
9
3656
by: Greg Gursky | last post by:
Hello: I'm doing some planning on a potential project with which I need some help. The database at the focus of this question is a MS Access database that is currently accessed by DAO from a local webserver. I need to access the same database remotely through TCP/IP. There will be potentially many transactions coming from both the web...
2
4553
by: David | last post by:
Hi, I have an MS Access database in which the tables have been exported to a MySQL DB on a Cobalt Qube 3 server and then import linked back into MS Access. This was all done via an User DSN (ODBC) I created on my local machine. I then put my front-end on a shared directory on our network. I have one other user who needs access. I added a...
2
5933
by: dronkanoki | last post by:
I am attempting to set up myODBC 3.51 on Win XP Pro to a remote MySQL Linux server. I get the following error: Access denied for user: 'username@ipaddress.serviceprovider.net' (Using password: YES) I had MySQL installed locally for testing, and myODBC worked fine. All the other apps I use locally (Dreamweaver, PHPmyAdmin, MySQL Front) work...
7
5561
by: BillCo | last post by:
I need to Connect to an online mySQL database from Access using JET ODBC with no saved DSN. Anyone out there who as made this work and can give example of how it's done? I've seen lots of posts saying it's possible, but no code. This has to be Jet ODBC, because the users are technophobes and I wouldnt expect them to download and install a...
0
7605
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
1
7665
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...
0
7962
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
1
5501
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...
0
5217
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3651
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...
0
3631
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2105
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
1207
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.