473,387 Members | 1,585 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Export mysql datas to Excelsheet

mageswar005
hi,
I need one help, How can i Export the Datas from mysql to Excelsheet not csv in php coding.The excelsheet format should be comes under microsoft office excel spreadsheet format.i need all this should be in php.I already tried in google but that code has some problem in excelsheet format.

thanks
M.Mageswaran
May 9 '08 #1
2 2015
Atli
5,058 Expert 4TB
Hi.

PHP does not provide any functions that can handle Excel files.
You can probably find classes that can handle them however. Try a Google search for Spreadsheet_Excel_Reader. (See this thread for an idea how to use that)

If it is at all possible, I would recommend saving the data as XML, which PHP can handle easily.
May 10 '08 #2
dlite922
1,584 Expert 1GB
hi,
I need one help, How can i Export the Datas from mysql to Excelsheet not csv in php coding.The excelsheet format should be comes under microsoft office excel spreadsheet format.i need all this should be in php.I already tried in google but that code has some problem in excelsheet format.

thanks
M.Mageswaran
Your safest and reliable bet would be on CSV.

A few reasons:

CSV is automatically opened by Excel, you can manipulate the header with PHP so that windows doesn't open the file in the browser, but offers a Open/Save/Cancel dialogue to the user.

When exporting data from MySQL, your data does not have *any* formatting (bold, color, margins, font, etc) for you to worry about anyway.

If your user *does* actually change the formatting, upon save they are automatically prompted to save as a .xls file anyway.

export to CSV code is cleaner, simpler, and therefore less buggy and more reliable. Could be alot faster than some solutions you might be heading towards.

-Dan
May 10 '08 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

9
by: Bob Bedford | last post by:
Where to find a comprehensive document on how take datas from XML and put them in a Mysql Database. I've many sites sending us XML files. We have to parse datas and save those datas on Mysql. ...
7
by: phillip.s.powell | last post by:
We're looking at a GUI interface for our MySQL DB and I am interested in MySQL Administrator, however, one of our requirements is to be able to import/export databases. Is this possible or do I...
0
by: Jose Angel Campos | last post by:
Hi, I will like to know if you know how to do it. I have this code for read google news and I want to added to my DB MYSQL so I can store the news for reading went I want. Here is the code I use...
2
by: DurumDara | last post by:
Hi ! I want to create a database from datas. I want to store my datas in lists/dicts/normal variables. I thinking about that I can use the pickle to serialize/load my datas from the file. ...
2
by: sathyashrayan | last post by:
Dear group, I have a task where I have to fetch datas from mysql and display it in the multiple select list box. I have fetched the datas and it is getting diplayed correctly in the multiple...
6
by: vj83 | last post by:
Hi, I have a C#.net application in which i have read the datas from excel sheet and displayed in a datagrid in my Aspx form. The code is here private void Button2_Click(object sender,...
5
by: sarangbagul1985 | last post by:
can anyone tell me how to import database from excelsheet to mysql using php (i.e. to transfer abc.xls to database)
0
by: trtaan | last post by:
Hi all, This is trtaan. I wanted to export around 300000 records that are present in my MS Access 2003 version table to excelsheet version8. I had written a code to export to multiple sheets in...
1
by: baburmm | last post by:
Hi all, Can any one tell me, Export datas to a Excel file using query without openrowset method is there any other methods are posible for creating an Excel file to export it Thanks,...
0
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,...
0
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$) { } ...
0
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
0
BarryA
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...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
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,...
0
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...

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.