If I have a .php file with some Oracle code previously accessing a Oracle DB, but have setup a MySQL DB and want to edit the existing .php file to be compatible with the MySQL DB, how would I go about doing this? Do I have to manually go through each line and search for the equivalent MySQL statement, and if so, is there a library I can access that gives me the Oracle to MySQL equivalent command?
There is this website with a good compilation of tips and tools to help you out on this task: http://www.sqlines.com/oracle-to-mysql
Related
i've looked into the tidesdk and found no way to query a local or external mysql database.
is there a way to connect to mysql and query a database/table, maybe via php?
thx for help
Currently there is no native way of accessing MySQL through TideSDK. You are welcome to help us create the native module for TideSDK to access MySQL.
Is it possible to write .MDF files using PHP. I have a simple HTML table - x columns, y rows that I wish to convert into a MS Access dataset. There are no foreign keys or anything exotic, just a number of rows and columns.
I have Google searched but the only advice I seem to be able to find is to save it as a .CSV. Unfortunately this isn't acceptable for my client. They want to simply be able to double click the icon and have the database load up in Access (Seems you have to import csv files and can't just double click them).
Those are actually two different problems:
1) Parsing HTML to separate values
Since you seem to have found a way to export to csv, I won't be answering this. You already got your parser then.
2) Create an mdb file.
You can use odbc to talk to Access, that is, if you are in Windows. That means that PHP must be installed on a Windows machine. I'm not aware of any Linux drivers for Access..
You can use odbc_connect to connect to the database:
$conn = odbc_connect("dbname","" ,"");
From there, working with the database is pretty similar to MySQL as long as you use the ODBC functions.
The only problem is creating the actual MDB. This cannot be done in ODBC, you'll need the JET engine. It may be possible to create an MDB file from PHP, but it may be easier to create an empty MDB once, and copy that file from PHP whenever you need a new database.
Jackcess is a pure Java library for reading from and writing to MS Access databases. It is part of the OpenHMS project from Health Market Science, Inc. . It is not an application. There is no GUI. It's a library, intended for other developers to use to build Java applications.
http://jackcess.sourceforge.net/
But an MDF file is not a standard Access file extension. MDB and MDE are while MDW is for user level security.
Have not tested this but this might help you:
http://devzone.zend.com/article/4065
Note that active development of MDB Tools has moved from Sourceforge to Github
https://github.com/brianb/mdbtools
I have a php script who access a MySQL database, all running in my server. I know how to compile php scripts in order to generate a .exe program, but this is the first time I got a php script that uses a MySQL, and I dont know how to compile the entire think. I dont want the .exe to use a remote mysql because I need to use it offline.
Thanks for any help.
If you use PDO you might just switch to SQLite on the fly.
No, it is not possible to embed a MySQL server in a compiled PHP script. The best you will be able to do is either replace MySQL with something like SQLite (not sure how feasible that will be) or build an installer that ships MySQL and the appropriate database tables (much more feasible).
Is there a way to export priviledges/users out of phpMyAdmin version 3.3.9? And yes, in such format that later those could be imported into a new installation.
It would be good if database relations would be kept and so on.
If phpMyAdmin cannot handle it, MySQL command line solution will work too.
Thanks in advance!
Basically you want to dump some tables from mysql database, like columns_priv,db,tables_priv and user
As far as I remember phpmyadmin have configuration option to hide some databases, but you can access it by typing ?db=mysql in url.
I have been given 2 files .DB and .sdf to work with. I have googled it a little and found out that its SQL Compact database format. I really have no idea how to work with these database files.
I have found here on stackoverflow some 3rd party tools, bud they were all for windows (I am on Mac).
I have also tried to open it in SQLite but no success.
I need this data in my web app written in PHP. So conversion to MySQL or Postrge seems to be an ideal solution. Any ideas?
You can use MSSQL extension in PHP to work with these databases