/    Sign up×
Community /Pin to ProfileBookmark

Downloading MySQL Data To Excel

Hi all,

Wanted some advice on downloading data from MySQL into an Excel spreadsheet… The initial site I was working with was .NET but had to be changed to PHP. When I look at the .NET example page of ‘Download’, click it it donwloads to an Excel spreadsheet… When I open it up it’s all nicely layed out already even has the table names from the database as heading for the Excel columns…

I have been able to achieve a download of my data in a PHP page but when IT opens it’s not formatted at all, and doesn’t have the table names as the headings… Does anyone know if this can be done? Surely you must be able to neaten up the Excel file to some extent… I’ve hunted around but haven’t had much luck… Any ideas would be greatly appreciated!

to post a comment
PHP

2 Comments(s)

Copy linkTweet thisAlerts:
@stephan_gerlachMay 15.2007 — It can be done. Search for "php excel class" in google. There are a few nice classes which let you propperly format excel files.
Copy linkTweet thisAlerts:
@tomyknokerauthorMay 15.2007 — Hi Stephan... Thanks alot! Are there any in particular which you have used or would recommend? I did see a sitepoint article about a PEAR class... Would that be useful?
×

Success!

Help @tomyknoker spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.6,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...