How to export mysql database into ms access using php - php

I am looking for a way to export a mysql table into MS Access file using php. The server is windows based and I want to export all the data in my mysql table into a msaccess file. I know about mysql to csv to mbd conversion(using phpmyadmin and ms access s/w), but is there a easy and better way to convert the tables into access file say on a mouse click using php?
Please note that there are lots records in the mysql table
Thanks for the help in advance.

There are a couple of ways to do this. I'd probably just connect Access directly to the MySQL DB as described here. I'm assuming, though, that this is not an option for you.
Assuming you can't do that for whatever reason you can always put together a script to connect to both the MySQL and MSAccess databases via PHP+SQL. This link has a guide to connecting to an Access DB via PHP.

Related

Mysql SELECT query statement using remote connection

I wanted to know if this was possible. Hope I'm asking this question the right way.
Can you write SELECT query locally without using the server? I can connect using certificate key and MySQL workbench but can't connect to the database on the server using the same credentials.
I'm using Php but don't know any other way to SELECT table and retrieve data for my React application without writing code on the server in a Php file to access the data?

Exctract database using php from MS SQL Server and import it into MySQL in realtime?

i have 2 servers one is using MS SQL database and it is under Windows OS and the other is using MySQL and it is under Ubuntu Server 14.04. Because the Windows server is active and it is using a software that i dont/cant change it or use other software i am stuck for now with using the MS SQL server for entering the data into the data base, but i need to use the data and expand the this data (data base) using a custom build website (php with mysql). So is there a way i can make a custom php function and extract the MS SQL data base on daily base and import it into the MySQL server? If this can be done i will be very greatful if someone can point me the way.
Alternativly: if someone can show/help me using the MS SQL code to connect and retrieve data from MS SQL server it will be great as well, but i prefer using the MySQL server if it can be done somehow.
Thank you!
I manage to do this by using 2 connections at the same time. One for the ms sql database and the other for mysql data base. I am using SQL Server 2005 for the ms sql data base and phpmyadmin for the mysql data base. i manage to do the connections using the functions:
for mssql:
mssql_connect, mssql_select_db, mssql_fetch_array and mssql_query
and for mysql:
mysqli
hope that helps someone in need! if u have questions let me know!

Is there a way to create a linked table in a mysql database?

I work often in MS Access and I always create linked tables to csv or txt files so that when some part of data changes in a source file the change appears in the dtb as well.
Is there a way to create linked tables in a mysql database used for storing data for php page?
Can phpMyAdmin in xampp do this?
MySQL supports a CSV storage engine.
Read the documentation here for more details:
http://dev.mysql.com/doc/refman/5.6/en/csv-storage-engine.html
So you can create a table that is linked to a CSV file, and if you modify the file, the new data will immediately become visible to SQL queries.
Yes, you can create a linked table to MySQL in Access. You will have to install the MySQL driver on the user's machine, and setup an ODBC. Then you can create a linked table to that ODBC connection.

How to Import Local MySQL Database to Web Server

I have a database with two tables in it, and I have exported them into a "dump.sql" file in my computer.
I am using a free web hosting service (000webhost.com) and I have a database named "username_newdb" and I want the two tables to be imported in that database.
I tried "Import" from phpmyadmin page, but it gives the error access denied for user, I don't know why. Moreover, I prefer to import the tables into new database, not to import (and create) the whole database. Can I do this? Maybe with PHP code?
If not, creating a new database would be accepted, too.
Any help would be appreciated.
if you can connect to that database from your computer directly, you can use any mysql manager to do the import, assuming your login/password is right as backup sql is just text file with bunch of INSERTs and CREATE TABLEs (so basically phpmyadmin should not even complain).

is it necessary to use php to connect to the MySQL

is it necessary to use php to connect to the MySQL
i am working the desktop application and do not have a knowledge of php either
is there any in build class or functionality that can be use to connect to the MySQL
although there are many programme present over the internet to do so but unablefind one without the use of php. is there any reference or can i have the step by step example regarding the work.
MySQL config has the default settings. like username is root and password is blank my server name is local host.
No. PHP is a programming language. MySQL is a database. Install MySQL and type mysql from the command line and you will be connecting to MySQL using mysql.
MySQL docs
If you're writing a desktop application, mysql probably isn't the database you want to use. If you want to store data locally, try something like an embedded sqllite database. If you want to store the data remotely, I STRONGLY recommend to put the database behind an API. That is where something like PHP would come into play. It doesn't have to be PHP though. It can be python, java, ruby, etc.
Whatever you do though, DO NOT talk directly to a remote mysql database from your desktop app. That's just asking to have your db hacked.
MySQL has nothing to do with PHP, except that they are often bundled together. If you need to access MySQL by itself you can download MySql workbench.
http://www.mysql.com/products/workbench/
If you need a driver for your language google 'language + MySql Driver'

Categories