On Jan 4, 4:55 pm, [EMAIL PROTECTED] wrote:
> Petr thanks so much for your input. I'll try to learnSQL, especially
> if I'll do a lot of database work.
>
> I tried to do it John's way as en exercise and I'm happy to say I
> understand a lot more. Basically I didn't realize I could nest
> dictiona
Petr thanks so much for your input. I'll try to learn SQL, especially
if I'll do a lot of database work.
I tried to do it John's way as en exercise and I'm happy to say I
understand a lot more. Basically I didn't realize I could nest
dictionaries like db = {country:{genre:{sub_genre:3}}} and cal
On Jan 3, 3:41 pm, [EMAIL PROTECTED] wrote:
> Yes in the sense that the top part will have merged cells so that
> Horror and Classics don't need to be repeated every time, but the
> headers aren't the important part. At this point I'm more interested
> in organizing the data itself and i can worry
Yes in the sense that the top part will have merged cells so that
Horror and Classics don't need to be repeated every time, but the
headers aren't the important part. At this point I'm more interested
in organizing the data itself and i can worry about putting it into a
new excel file later.
--
h
> So the data comes in as a long list. I'm dealing with some
> information on various countries with 6 pieces of information to
> pivot. Just to make it simple it's like a video store database. The
> data is like [Country, Category, Sub Category, Film Title, Director,
> Number of Copies]. data
Sorry for the delay in my response. New Year's Eve and moving
apartment
> - Where the data come from (I mean: are your data in Excel already
> when you get them)?
> - If your primary source of data is the Excel file, how do you read
> data from the Excel file to Python (I mean did you solve this
> Yes, I realize Excel has excellent support for pivot tables. However,
> I hate how Excel does it and, for my particular excel files, I need
> them to be formated in an automated way because I will have a number
> of them over time and I'd prefer just to have python do it in a flash
> than to do
On Dec 29, 3:00 pm, [EMAIL PROTECTED] wrote:
> Patrick,
>
> in your first posting you are writing "... I'm trying to learn how to
> make pivot tables from some excel sheets...". Can you be more specific
> please? AFIK Excel offers very good support for pivot tables. So why
> to read tabular data fr
Patrick,
in your first posting you are writing "... I'm trying to learn how to
make pivot tables from some excel sheets...". Can you be more specific
please? AFIK Excel offers very good support for pivot tables. So why
to read tabular data from the Excel sheet and than transform it to
pivot tabel
On Dec 29, 11:51 am, [EMAIL PROTECTED] wrote:
> John would you mind walking me through your class in normal speak?
Yes.
> I
> only have a vague idea of why it works and this would help me a lot to
> get a grip on classes and this sort of particular problem.
It's about time you got a *concrete*
Petr, thanks for the SQL suggestion, but I'm having enough trouble in
Python.
John would you mind walking me through your class in normal speak? I
only have a vague idea of why it works and this would help me a lot to
get a grip on classes and this sort of particular problem. The next
step is to
On Dec 29, 9:58 am, [EMAIL PROTECTED] wrote:
> What about to let SQL to work for you.
The OP is "trying to learn how to make pivot tables from some excel
sheets". You had better give him a clue on how to use ODBC on an
"excel sheet" :-)
[snip]
> SELECT
> NAME,
> sum (AMOUNT) as TOTAL,
> sum (case
What about to let SQL to work for you.
HTH
Petr Jakes
Tested on Python 2.5.1
8<--
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import sqlite3
con = sqlite3.connect(":memory:")
cur = con.cursor()
inputData=(
('Bob', 'Morn', 240),
('Bob', 'Aft', 300),
('Joe', 'Morn', 70),
('
Wow, I did not realize it would be this complicated! I'm fairly new
to Python and somehow I thought I could find a simpler solution. I'll
have to mull over this to fully understand how it works for a bit.
Thanks a lot!
On Dec 28, 4:03 am, John Machin <[EMAIL PROTECTED]> wrote:
> On Dec 28, 11:4
On Dec 28, 11:48 am, John Machin <[EMAIL PROTECTED]> wrote:
> On Dec 28, 10:05 am, [EMAIL PROTECTED] wrote:
>
>
> > If you have any ideas about how to solve this pivot table issue, which
> > seems to be scant on Google, I'd much appreciate it. I know I can do
> > this in Excel easily with the auto
On Dec 28, 10:05 am, [EMAIL PROTECTED] wrote:
> On Dec 27, 10:59 pm, John Machin <[EMAIL PROTECTED]> wrote:
>
> > On Dec 28, 4:56 am, [EMAIL PROTECTED] wrote:
>
> > > from itertools import groupby
>
> > You seem to have overlooked this important sentence in the
> > documentation: "Generally, the it
On Dec 27, 10:59 pm, John Machin <[EMAIL PROTECTED]> wrote:
> On Dec 28, 4:56 am, [EMAIL PROTECTED] wrote:
>
> > from itertools import groupby
>
> You seem to have overlooked this important sentence in the
> documentation: "Generally, the iterable needs to already be sorted on
> the same key functi
On Dec 28, 4:56 am, [EMAIL PROTECTED] wrote:
> from itertools import groupby
You seem to have overlooked this important sentence in the
documentation: "Generally, the iterable needs to already be sorted on
the same key function"
--
http://mail.python.org/mailman/listinfo/python-list
Hi all,
I tried reading http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/334695
on the same subject, but it didn't work for me. I'm trying to learn
how to make pivot tables from some excel sheets and I am trying to
abstract this into a simple sort of example. Essentially I want to
take in
19 matches
Mail list logo