Sorting Rows Doesn't Work, Please Help

H

Harlan Grove

(e-mail address removed) wrote...
yeah MS is a bunch of drunk CORNHOLERS that **CENSOR** what I say.
....

Microsoft employees can recognize wasted bandwidth when they see it.
 
A

aaron.kempf

they also recognize the inefficiency in having 500 people sitting
around on their ass. making the same report every week.
copy and paste the same report; copy and paste some new data into it.

COPY AND PASTE DOESNT MAKE A GOOD ETL STRATEGY ASSHOLES

-Aaron
 
H

Harlan Grove

(e-mail address removed) wrote...
....
COPY AND PASTE DOESNT MAKE A GOOD ETL STRATEGY . . .

And is that all you can conceive of trying to do in Excel?

ETL is more text processing than numeric calculation, so not well
suited to any spreadsheet. Odd that you didn't know that.
 
A

aaron.kempf

THEN WHY DO YOU KIDS USE IT FOR ETL?

i swear to god; every pulls data; cleans it and re-packages it...

etl isn't test processing.. it's mainly lookups and designing
components for ultra-high performance

normalizing; denormalizing

it just makes me sad to see you guys stuck in the first grade.. there
are betters tools than excel

I mean; you kids use it for reporting; you use it as 'portable
documents'; you use it for ad-hoc analysis.... you use it for data
entry and consolidation

it just makes me sick to my stomach to think of you conniving bastards
actually CASHING A PAYCHECK just because you think that you're such an
expert when it comes to copy and paste

just because you know how to take one formula; and make a billion
copies of the same formula; with different permutations?

it doesn't mean that you're worth a bloody dime.

you kids-- if you were serious about excel-- you would be learning MDX.
MDX is the only practical area in which spreadsheet developers have
_SOME_ value.

it's SQL _TIMES_ Excel.

of course; it's a 100 times more efficient because you can write MDX
formulas and equations.. I mean..

if you kids surrendered and said 'ok; im a worthless spreadsheet dork..
teach me mdx'

if I had a million spreadsheet developers outside my house tomorrow
am.. saying 'I have seen the light; let me use my current Excel
skillset to learn MDX'

you guys could really do something.. I mean.. MDX is the greatest
invention of all time.. and you kids are SOOOOO scared to be seen as a
geek... you're scared to become a REAL PROGRAMMER.. SQL people don't
need to learn Excel.... Excel people need to move upstream

sitting there; recording macros.. shit.. what a mess!!!

As it is; I call for the immediate execution of spreadsheet dorks;
throw them out the window or shoot them in the street for all i care.

You kids sit there and STEAL MONEY-- from your employers.
You sit there and YOU ARE THE REASON THAT WE HAVE TO IMPORT REAL
DEVELOPERS. BECAUSE YOU KIDS ARE ALL STUCK IN THE FIRST GRADE OF THE
TECHNOLOGY LADDER.

you spin your wheels.. you kids are Ferris Bueller trying to drive the
Ferrari in reverse.. sitting there spinning and waiting patiently..
waiting for the speedometer to start going backwards

ITS NOT GOING TO HAPPEN

Excel is WORTHLESS.

Run away while you still can.

Invest in real software development skills... Take some reporting
program-- Crystal Reports for ALL I CARE.

Broaden your horizons.

Start carrying your load.

You kids get 2/3rds of the payrolls in companies.. why is it that you
IDIOTS don't do _ANY_ of the real work?

If you kids applied yourselves; your companies could really begin to
LEVERAGE.. if you know what I mean.

you guys-- your companies-- could really go somewhere

It just makes me sick to think that you kids are contributing.. when
all you do is sit around; record macros and copy and paste
 
H

Harlan Grove

(e-mail address removed) wrote...
THEN WHY DO YOU KIDS USE IT FOR ETL?
....

Not me.

Who?

You?

Some unnamed spreadsheet users?

Spreadsheets are misused for lots of things. There've been newsgroup
postings asking for help making Excel generate temporary usernames and
passwords for students in courses that require computer work. That's a
task for which there have been much better, more robust tools (shell
scripts) available for decades.

SOME people will continue to misuse spreadsheets for the forseeable
future. Most of them will do so because they don't know anything else
that could automate their tasks. A few will do so because spreadsheets
are the only tool they have that could allow them to automate their
tasks.

If you want to show them IN DETAIL how their tasks would be easier in
Access or some other database, go ahead and do so (for a change). Just
telling that Access would be easier without showing them how isn't
going to change anyone's mind. But you're not here to change any minds,
are you? You're just here to rant.
etl isn't test processing.. it's mainly lookups and designing
components for ultra-high performance
....

You mean TEXT processing? Since when are lookups calculations?
Associative arrays, aka hashes, provided by all scripting languages are
more efficient than spreadsheet lookup functions.

Use the best tool for the task. Spreadsheets aren't ideal for ETL.
of course; it's a 100 times more efficient because you can write MDX
formulas and equations.. I mean..
....

To repeat from months ago, there have been attempts to sell 'financial
modeling packages' for years. Lotus Improv was the first. Then there
was Advance. Now there's Quantrix. They don't sell in large volume
because they're inflexible and difficult to learn. Same can be said of
MDX. This doesn't mean they don't have their uses, but they're not for
everyone. They're certainly not the panacea you think they are.
 
J

Jay Petrulis

I don't need a solution.
You don't get that crazy "spreadsheet" contraption, and you don't get
this newsgroup help forum thingamajig, either, do you?

RIGHT CLICK SORT

It's in Access.. but Excel can't do this??
Are you suggesting that Excel does not have the capability to sort?
Are you really suggesting this? Really? Or, did I misread what you
wrote?

Is the fact that it is not part of the right click the point you are
stressing?

Lemon juice.
 
A

aaron.kempf

do u want to know WHY Access is more powerful?

RIGHT-CLICK SORT.
RIGHT-CLICK FILTER.

RIGHT-CLICK EXCLUDE.

That's all the 'technical explanation' that you NEED with Access.

Can excel even digest data at different granularities?

Everything that was useful in Excel has been inside of Access for 5-6
years now.

Excel is completely obsolete.

-Aaron
 
H

Harlan Grove

Harlan Grove wrote...
....
Really? How does one sort fieds in each record separately in any
database? That is, given the OP's sample data as a table,

F1____F2____F3____F4____F5____F6
37____36____26____42____10____23
_2____48_____3_____1____13____28 ....

show us a query that could transform this into

F1____F2____F3____F4____F5____F6
10____23____26____36____37____42
_1_____2_____3____13____28____48
....

So, Aaron, I take it by your silence on this specific question that you
have NO CLUE how to do this with ANY sort of query. Guess this just
goes to show that one thing databases don't handle easily is swapping
values between fields in the same record.

There may be a way to do this with databases. First you'd need to
convert the first table above to something like

OrigRecNum__ColNum__Value
_____1__________1_____37
_____1__________2_____36
_____1__________3_____26
_____1__________4_____42
_____1__________5_____10
_____1__________6_____23
_____2__________1______2
_____2__________2_____48
_____2__________3______3
_____2__________4______1
_____2__________5_____12
_____2__________6_____28

Then sort this new table by OrigRecNum then Value, both in ascending
order to get

OrigRecNum__ColNum__Value
_____1__________5_____10
_____1__________6_____23
_____1__________3_____26
_____1__________2_____36
_____1__________1_____37
_____1__________4_____42
_____2__________4______1
_____2__________1______2
_____2__________3______3
_____2__________5_____12
_____2__________6_____28
_____2__________2_____48

Then update the ColNum field to show the count of records with the same
OrigRecNum and Value <= the current record's Value. The result would
look like

OrigRecNum__ColNum__Value
_____1__________1_____10
_____1__________2_____23
_____1__________3_____26
_____1__________4_____36
_____1__________5_____37
_____1__________6_____42
_____2__________1______1
_____2__________2______2
_____2__________3______3
_____2__________4_____12
_____2__________5_____28
_____2__________6_____48

And finally put this back into crosstab layout.

F1____F2____F3____F4____F5____F6
10____23____26____36____37____42
_1_____2_____3____13____28____48

Does this help you? Why don't you show us what the queries would look
like? Dazzle us with how 4 nontrivial queries would be oh, so much more
efficient than the Excel equivalent of a single array formula filled
down (one moderately somplicated formula followed by one simple
operation).
 
A

aaron.kempf

you keep your data properly normalized.

having columns named F1, F2, F3, F4, F5, F6 isn't acceptable to ANY
real developer.

it's time that u excel dorks learn some real tools.. and it's time that
companies start enforcing real SDLC 'best practices' inside of Excel.

2/3rds of companies paychecks go to idiots that spend all day copying
and pasting.

You CON-ARTISTS can lick my nuts.

Do something productive. Learn Crystal Reports.

-Aaron
 
A

aaron.kempf

inflexible and difficult to learn?

you WIMPS need to bite the bullet and learn some real skills.

It took me YEARS to be able to learn how to build a responsive
database.

but I stuck with it. I read books on it. I took classes on it in
college.

And I slaved and slaved until I could do it.

MDX is 10 times more powerful and complex than SQL. I don't mean SQL
Server; I mean all dialects of ANSI-SQL.

Yes. It is a FRIGGIN BITCH to learn.

But Excel was too.

Excel is harder to use than any other product on the market.

Why is it popular?

Because you idiots DONT HAVE THE BALLS to learn a real program.

It's laughable.

What did Opperheimer say when FDR said 'build me a nuclear bomb'

did he shiver and say 'oh but its TOO HARD'

Did Michael Jordan stop practicing because it was 'TOO HARD'?

Grow some balls kids; you're all stuck in the first grade of the
technology ladder.

-Aaron
 
J

Jay Petrulis

blah, blah, blah

-Aaron

F1...F6 represent variable field names. Call them whatever you'd like.
Harlan gave you an outline of a possible solution using a database
(far more than you can do). That you chose to interpret his post to
mean that he doesn't know how to give descriptive names says a lot
about your ability to work with databases.

Grapefruit juice.
 
A

aaron.kempf

lottery pick #1 shouldn't go in column 1 and lottery pick #2 shouldn't
go in column 2.

it should be ONE TABLE, 2 FIELDS.

then shit doesn't need to sort multiple columns.

if the OP knew how to put the data in ONE COLUMN instead of in 6? it
would be as simple as right-click SORT or SUM with a group by or
something.

to pul it from 6 columns into 1 column

of course; he would also need some sort of ticket # or something along
those lines to keep it straight.. but here's the general idea.

Select Column1 From MyLottery
UNION
Select Column2 From MyLottery
UNION
Select Column3 From MyLottery
UNION
Select Column4 From MyLottery
UNION
Select Column5 From MyLottery
UNION
Select Column6 From MyLottery
 
A

aaron.kempf

Harlan;

you don't need the '' column because it doesnt' TELL YOU ANYTHING.

if you wanted to -- you could use the RANK function to tell what
ordinal position it SHOULD BE IN.

But your design is flawed because it has information that is
unnecessary.

We don't care about what ordinal position the numbers were pulled in..
right?
so why would we store it?

Note: this ranking function might take a different shape; I would
probably change it to a query or 2 instead of tmpTables...

Select OrigRecNum, (select count(distinct value) from TmpLotteryNumbers
subQ Where SubQ.Value < TmpLotteryNumbers.Value + 1) as Rank
Into TmpLotteryNumbers
From
(
Select OrigRecNum, F1 as Value
UNION
Select OrigRecNum, F2
UNION
Select OrigRecNum, F3
UNION
Select OrigRecNum, F4
UNION
Select OrigRecNum, F5
UNION
Select OrigRecNum, F6
) derived1

Select OrigRecNum,
(Select Value From TmpLotteryNumbers SubQ WHERE SubQ.OrigRecNum =
TmpLotteryNumbers.OrigRecNum AND Rank = 1) As F1,
(Select Value From TmpLotteryNumbers SubQ WHERE SubQ.OrigRecNum =
TmpLotteryNumbers.OrigRecNum AND Rank = 2) As F2,
(Select Value From TmpLotteryNumbers SubQ WHERE SubQ.OrigRecNum =
TmpLotteryNumbers.OrigRecNum AND Rank = 3) As F3,
(Select Value From TmpLotteryNumbers SubQ WHERE SubQ.OrigRecNum =
TmpLotteryNumbers.OrigRecNum AND Rank = 4) As F4,
(Select Value From TmpLotteryNumbers SubQ WHERE SubQ.OrigRecNum =
TmpLotteryNumbers.OrigRecNum AND Rank = 5) As F5,
(Select Value From TmpLotteryNumbers SubQ WHERE SubQ.OrigRecNum =
TmpLotteryNumbers.OrigRecNum AND Rank = 6) As F6
From
(Select Distinct OrigRecNum From TmpLotteryNumbers) derived1


Altogether this would take me less than 30 seconds.
 
A

aaron.kempf

Binar;

it's a shame you don't learn how to use databases.

Excel isn't a tool for sorting.. it doesn't even support 'RIGHT-CLICK
SORT'.
 
A

aaron.kempf

it's not 4 untrivial queries.

it is ONE QUERY. MAYBE 2.

And for the record?? i woudln't have to properly normalize the data--
because it would come to me in that format.

-Aaron
 
A

aaron.kempf

you see harlan.. simple operations like re-sorting? they don't require
you to have a duplicate copy of the data.

and for the record; what percentage of Excel developers use Array
formulas?


5 percent?


-Aaron
 
H

Harlan Grove

(e-mail address removed) wrote...
....
Can excel even digest data at different granularities?

Got a specific case?
Everything that was useful in Excel has been inside of Access for 5-6
years now.

Maybe everything useful to you, since all you seem to need (be able to
understand?) is counting and summing.

So return to a question you haven't managed to answer, how would you
perform matrix multiplication or inversion in Access?
 
H

Harlan Grove

(e-mail address removed) wrote...
you see harlan.. simple operations like re-sorting? they don't require
you to have a duplicate copy of the data.

Reread your own query. It's reading data from one table and putting it
into a different table with a different number of fields. Wouldn't that
mean two copies of the data?

So you're even unclear on what goes on in databases too, aren't you?
and for the record; what percentage of Excel developers use Array
formulas?

5 percent?

Excel USERS? 5%'s about right. Excel DEVELOPERS, as in those people who
create workbooks intended for other people to use, at least 50% use
them and all understand what they do. Your ignorance of them serves as
proof you're no Excel developer.
 
J

Jay Petrulis

lottery pick #1 shouldn't go in column 1 and lottery pick #2 shouldn't
go in column 2.

it should be ONE TABLE, 2 FIELDS.

then shit doesn't need to sort multiple columns.

if the OP knew how to put the data in ONE COLUMN instead of in 6? it
would be as simple as right-click SORT or SUM with a group by or
something.
Have you ever used a database before? Unless I am misreading how you
set this up, this "solution" doesn't work.

If you mean mean that you would transform the OP's data from a n-row X
6-column grid to an (6n)-row X 1-column grid, that would work, but
wouldn't the data entry be even more difficult than if you used a field
for each of the items in a record? Also, wouldn't you be losing
something (which you could get back with some unnecessary work) by
having 6n records?

There is no way that you are a "professional" database developer if you
would do this. What a crock.

Excel would be a much better tool for this if your suggestion is the
way a "professional" would do it.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top