2008/9/24 Duncan Booth [EMAIL PROTECTED]:
Python still wins hands down on this example both in verbosity and
readability:
But AFAICS, the Python version you give creates a temporary. One of
the advantages cited for LINQs functional programming paradigm is that
it specifies what is wanted at a
of lambda expressions has a neat trick
that is central to LINQ. A lambda expression compiles either to executable
code, or to an expression tree. If you are filtering some C# sequence
object then (as with Python lambdas) the LINQ code simply calls the
compiled lambda expression like any other
sturlamolden [EMAIL PROTECTED] wrote:
On Sep 24, 10:59 pm, Duncan Booth [EMAIL PROTECTED]
wrote:
Simple LINQ expressions like the one you gave map easily to Python
list comprehensions. What Microsoft have done though is provide a
consistent implementation which allows you to write complex
On 25 Sep, 10:08, Duncan Booth [EMAIL PROTECTED] wrote:
A lot of what LINQ does is already easy to do in Python, and most of the
rest can probably be added fairly easily, but it does provide a consistent
framework which may make it easier to do complex LINQ statements than
complex list
Hi
If i rephrase my question how will i do this in Python
http://informationr.net/ir/13-2/TB0806.html
Watch this query on the page Where he joins all different kind of things with
ease and elegance(as per my opinion)
[code]
var stoogeGuys =
Beginning with the XML source
from
Hi Grant
haha :-) i discounted that perspective :-)
regards
Hrishy
--- On Thu, 25/9/08, Grant Edwards [EMAIL PROTECTED] wrote:
From: Grant Edwards [EMAIL PROTECTED]
Subject: Re: Linq to Python
To: python-list@python.org
Date: Thursday, 25 September, 2008, 2:22 AM
On 2008-09-24, Bruno
Hi Roger
I am impressed (i always suspected Python programmers are smart no doubt about
it).
But what about the case where they join different sources like the one here
http://informationr.net/ir/13-2/TB0806.html
Thanks for teaching me :-) i am thankful for that
regards
Hrishy
names =
On 25 Sep, 12:06, hrishy [EMAIL PROTECTED] wrote:
var stoogeGuys =
Beginning with the XML source
from xmlGuys in xmlSource.Descendants(Stooge)
Join to the array on the common element stoogeName
join arrayGuys in familyFacts
on xmlGuys.Element(stoogeName).Value
Hi Tim
I am not a LINQ expert just a LINQ user and (was a little envious why the
langauge i fantasize doesnt have it (pardon my ignorance of python))
LINQ as far as i know allows you to query all sources using a consistent
interface .
You can query a message queue ,xml document ,array object
On 25 Sep, 12:06, hrishy [EMAIL PROTECTED] wrote:
[code]
var stoogeGuys =
Beginning with the XML source
from xmlGuys in xmlSource.Descendants(Stooge)
Join to the array on the common element stoogeName
join arrayGuys in familyFacts
on
Hi
Pardon my ignorance again but id ont see any join in python or did i miss
something ?
regards
Hrishy
--- On Thu, 25/9/08, sturlamolden [EMAIL PROTECTED] wrote:
From: sturlamolden [EMAIL PROTECTED]
Subject: Re: Linq to Python
To: python-list@python.org
Date: Thursday, 25 September
On 25 Sep, 13:08, hrishy [EMAIL PROTECTED] wrote:
Pardon my ignorance again but id ont see any join in python or did i miss
something ?
It's more Pythonic to use the syntax of dictionary lookups.
--
http://mail.python.org/mailman/listinfo/python-list
Hi
Thank you very much I appreciate taking the pain to explain this to me.
regards
Hrishy
--- On Thu, 25/9/08, sturlamolden [EMAIL PROTECTED] wrote:
From: sturlamolden [EMAIL PROTECTED]
Subject: Re: Linq to Python
To: python-list@python.org
Date: Thursday, 25 September, 2008, 12:16 PM
99 or your 1
million rows. The apis defined by LINQ allow that sort of optimisation
to happen transparently, the simple list would just test each element
but the database would run an appropriate query.
So what the 'can we have LINQ in Python' people are asking is to be able
to write things
On 25 Sep, 14:22, Duncan Booth [EMAIL PROTECTED] wrote:
No Python's syntax is fine. The api's aren't as consistent though:
Microsoft added a common set of extension methods which work on
databases, xml, builtin sequences and can be easily extended to include
other custom sequences.
That is
Duncan Booth:
Microsoft added a common set of extension methods which work on
databases, xml, builtin sequences and can be easily extended to include
other custom sequences.
When the processing is done in memory, LINQ may also work well with
multi-core CPUs, see PLINQ.
Bye,
bearophile
--
/9/08, Terry Reedy [EMAIL PROTECTED] wrote:
From: Terry Reedy [EMAIL PROTECTED]
Subject: Re: Linq to Python
To: python-list@python.org
Date: Tuesday, 23 September, 2008, 7:51 PM
Will LINQ be ported to Python ?
I have three suggestions:
1. When starting a new thread, start a *new* thread
Hi
Well wouldn't it be a lot easier to query and join a xml source with a
relational source with LINQ capabilites in Python.
Hmm what am i missing here is there a site that takes all LINQ examples and
does them using list comprehensions and makes them sound easy ?
wasn't python supposed
:
From: Thomas G. Willis [EMAIL PROTECTED]
Subject: Re: Linq to Python
To: python-list@python.org
Date: Tuesday, 23 September, 2008, 7:45 PM
But surely the idea behind it will eventually spread.
It's really
just comprehensions generalized over XML and
relational datasets, a
noble goal
On Wed, Sep 24, 2008 at 11:25 AM, hrishy [EMAIL PROTECTED] wrote:
Hi Tom
This is what i like and feel of the Python programmers smarter then every
other langauge i know of.
But i am not comfortable with your second statement XML i never need it
one day everybody would need it.
regards
On Sep 24, 5:22 pm, hrishy [EMAIL PROTECTED] wrote:
Well wouldn't it be a lot easier to query and join a xml source with a
relational source with LINQ capabilites in Python.
Hmm what am i missing here is there a site that takes all LINQ examples and
does them using list comprehensions
sturlamolden:
No, because Python already has list comprehensions and we don't need the XML
buzzword.
LINQ is more than buzzwords. Python misses several of those features.
So maybe for once the Python crowd may recognize such C# feature as
much better than things present in Python.
Said that, I
[EMAIL PROTECTED] wrote:
sturlamolden:
No, because Python already has list comprehensions and we don't need the XML
buzzword.
LINQ is more than buzzwords. Python misses several of those features.
So maybe for once the Python crowd may recognize such C# feature as
much better than things
On Wed, Sep 24, 2008 at 2:11 PM, [EMAIL PROTECTED] wrote:
sturlamolden:
No, because Python already has list comprehensions and we don't need the XML
buzzword.
LINQ is more than buzzwords. Python misses several of those features.
So maybe for once the Python crowd may recognize such C#
[EMAIL PROTECTED] wrote:
sturlamolden:
No, because Python already has list comprehensions and we don't need the XML
buzzword.
LINQ is more than buzzwords. Python misses several of those features.
So maybe for once the Python crowd may recognize such C# feature as
much better than things
hrishy a écrit :
(snip)
I apologise
(I thought Python programmers were smart and they did know what LINQ was)
Is there really any relation between being smart and knowing anything
about the latest MS fad ?
--
http://mail.python.org/mailman/listinfo/python-list
On Sep 24, 9:11 pm, [EMAIL PROTECTED] wrote:
In the meantime where I
live lot of people will keep using C# instead of Python and CLisp,
natural selection at work indeed.
Please explain to me what Linq can do that Python does not. Put you
emphasis on why this can't be done with a library, and
r0g [EMAIL PROTECTED] wrote:
OK so maybe I'm being naive here but it looks to me like this new
paradigm's big idea is to use a python + SQL type syntax to access data
in random objects. Big whoop. It's not that difficult to write a
generators that wraps XML files and databases is it?
What
On Sep 24, 10:59 pm, Duncan Booth [EMAIL PROTECTED]
wrote:
Simple LINQ expressions like the one you gave map easily to Python list
comprehensions. What Microsoft have done though is provide a consistent
implementation which allows you to write complex SQL like expressions which
will work
delegates less cumbersome). To someone other than a C# person, these
features are not new or revolutionary, it's just C# catching up. Kudos
to them for getting there before java.
After some more thought on what might conceivably be missing from
python that LINQ has, that someone might want
On 2008-09-24, Bruno Desthuilliers [EMAIL PROTECTED] wrote:
hrishy a écrit :
(snip)
I apologise
(I thought Python programmers were smart and they did know what LINQ was)
Is there really any relation between being smart and knowing anything
about the latest MS fad ?
God, I hope not -- or
Duncan Booth wrote:
r0g [EMAIL PROTECTED] wrote:
OK so maybe I'm being naive here but it looks to me like this new
paradigm's big idea is to use a python + SQL type syntax to access data
in random objects. Big whoop. It's not that difficult to write a
generators that wraps XML files and
Hi
Will LINQ be ported to Python ?
regards
Hrishy
--
http://mail.python.org/mailman/listinfo/python-list
hrishy wrote:
Hi
Will LINQ be ported to Python ?
Take a look at SQLAlchemy or SQLObject for python-based
ORM/SQL-abstractions.
Apart from that, python is already heavily based on concepts like iterators,
filtering. Take a look at itertools.
Diez
--
: Linq to Python
To: python-list@python.org
Date: Tuesday, 23 September, 2008, 4:06 PM
hrishy wrote:
Hi
Will LINQ be ported to Python ?
Take a look at SQLAlchemy or SQLObject for python-based
ORM/SQL-abstractions.
Apart from that, python is already heavily based on
concepts like
On Sep 23, 7:48 am, hrishy [EMAIL PROTECTED] wrote:
Hi
Will LINQ be ported to Python ?
regards
Hrishy
I think this question is more appropriate to ask on an IronPython
development list -- LINQ is pretty solidly intertwined with .Net, and
so you'll likely want to look at the .Net
On Sep 23, 2:07 pm, Jason Scheirer [EMAIL PROTECTED] wrote:
On Sep 23, 7:48 am, hrishy [EMAIL PROTECTED] wrote:
Hi
Will LINQ be ported to Python ?
regards
Hrishy
I think this question is more appropriate to ask on an IronPython
development list -- LINQ is pretty solidly intertwined
But surely the idea behind it will eventually spread. It's really
just comprehensions generalized over XML and relational datasets, a
noble goal. Besides, it's main purpose for .NET was to bring
functional programming to it. Python already has that, somewhat...
it's really any object out
On Sep 23, 4:48 pm, hrishy [EMAIL PROTECTED] wrote:
Will LINQ be ported to Python ?
No, because Python already has list comprehensions and we don't need
the XML buzzword.
--
http://mail.python.org/mailman/listinfo/python-list
for an
answer. If you mean the .NET component, googling 'Python LINQ' should
partly answer your question.
tjr
--
http://mail.python.org/mailman/listinfo/python-list
40 matches
Mail list logo