Profile

Cover photo
Sami Lehtinen
Works at Oy Winpos Ab
Lived in Helsinki
1,231,351 views
AboutPostsPhotos

Stream

 
Good tips how to use Peewee ORM to query different stuff efficiently.
#python #database #databases #orm #peewee #sql #querybuilding  
In this post I'd like to share some techniques for querying the top item by group using the Peewee ORM. For example,. List the most recent tweet by each of my followers. List the highest severity bug for each of my open source projects. List the latest story in each section of a news site.
2
1
Sami Lehtinen's profile photoDennis Catt's profile photoJohn Collins's profile photo
3 comments
 
+Sami Lehtinen 
Well the use case I had to cover I needed to not care about the data models and needed an ORM that was willing to let me tell it what to do.  I actually looked into PeeWee first because I liked what I saw, but I found that PeeWee was akin to Ruby's ActiveRecord where it already has an expectation of knowing about your data models beforehand in order to do its magic.  I had a similar use case for a Ruby project sometime back and used a toolkit called Sequel that is much like Dataset.
Add a comment...
 
I just barfed some of my lastest stuff to blog. Sorry. ;) It's truly just a weblog of stuff what I'm doing.
#blog #blogging #personal  
2
Add a comment...
 
Really nice post by Charles Leifer about Peewee. That's the ORM I've been using with my Python Database stuff. It's just faster and simpler to use than plain SQL. Yet some complex operations might be too much for it. Of course you can run the manually written SQL query and then just use ORM to map the results to objects.
#peewee #python #databaseadministrator #databasedeveloper #databases #database #sql #orm  
1
Add a comment...
 
Excellent observations about Asynchronous Python and Databases. I personally select solution being used based on use case. Sometimes async is needed at times it just makes performance poor and program more complex. Same applies to multithreading and multiprocessing approaches.
#asynchronous #python #database #databases  
The asynchronous programming topic is difficult to cover. These days, it's not just about one thing, and I'm mostly an outsider to it. However, because I deal a lot with relational databases and the Python stack's interaction with them, I have to field a lot of questions and issues regarding ...
29
16
Benedikt Stehno's profile photoPoChien Wang's profile photo
Add a comment...
 
It seems that hubic.com hasn't yet fixed the annoying UX fail. If you upload too large file. Guess what, they'll just fail it at the end and restart the upload because it failed. That's just so ... awww.... Uploading 2 GB file can consume 20 gigs of bandwidth when you just leave it running for several hours in background tab and wonder when it's getting completed.
#hubic #filehosting #userexperience #ux #javascript #programming #usabilitymatters #usability #fail #badux  
1
Add a comment...
 
I couldn't agree more! I see all the time that even businesses are absoultely full of seriously flawed and fatally misconfigured systems. IoT will make things at least 100x worse, even if we don't count the NSA  / intelligence agency tinfoil factor in.
#iot #internetofthings2015 #internetofthings #security #privacyandsecurity #privacy +Kaspersky Lab 
There is a flood of appliances which could be connected - and some are connected - without a second thought as to whether or not it's necessary or secure.
21
3
Samuel Salminen's profile photoPierre Bellet's profile photoo ak's profile photoMichael Butler's profile photo
 
Nothing new, the internet has allways been full of crap in varying shades. Just because it's brown, doesn't mean it's chocolate! ;)
Add a comment...
 
All that talk about high security, theoretical attacks like cracking ciphers and stealing data via cache timing attacks. And then there's the actual reality.
#mongodb #security #databaseadministrator #database #programming #websitedevelopment  
9
3
ṤⱧǠ ᴆŐƜ's profile photoSuvi-Tuuli Allan's profile photoGabriel Sfestarof's profile photoAntti Vainiola's profile photo
 
+Sami Lehtinen Nice post
Add a comment...

Communities

26 communities

Sami Lehtinen
owner

Discussion  - 
 
Good peewee ORM stuff.
In this post I'd like to share some techniques for querying the top item by group using the Peewee ORM. For example,. List the most recent tweet by each of my followers. List the highest severity bug for each of my open source projects. List the latest story in each section of a news site.
1
Add a comment...
 
Ok, pretty normal stuff for advanced CS guys. But others who haven't studied this stuff so deeply might greatly benefit from these ideas. #python #programming #datastructure #datastructures  
Fast Non-Standard Data Structures for Python. Sat 01 September 2012. By Mikhail Korobov. Python provides great built-in types like dict, list, tuple and set; there are also array, collections, heapq modules in the standard library; this article is an overview of external lesser known packages ...
24
9
David Suárez's profile photoJun Wang's profile photoLevente Varga's profile photoMike Fleming's profile photo
3 comments
 
From a non computer science background some of these are useful I found this page only a month or two ago a good read 
Add a comment...
 
Really nice post by Charles Leifer about Peewee. That's the ORM I've been using with my Python Database stuff. It's just faster and simpler to use than plain SQL. Yet some complex operations might be too much for it. Of course you can run the manually written SQL query and then just use ORM to map the results to objects. Also see Peewee Users Community: https://plus.google.com/u/0/communities/108918975824733528312
3
victor noagbodji's profile photoSami Lehtinen's profile photoDavid Ford's profile photo
3 comments
 
sqlalchemy
Add a comment...
 
It seems that I found two computers affected by #superfish one Lenovo Yoga 2 and one #MIIX tablet. Thank you #lenovo . You can't simply trust anything nowadays.
1
Samuel Salminen's profile photo
 
The world today is seriously low on trust. Format, reinstall, linux, cyanogenmod. OTOH the only safe computer is the one with shotgun-holes.
Add a comment...
 
Noticed similar issue while I took Norwegian flight. Yet I'm not sure if they were using Gogo, if not, they're still doing the same stuff.
#norwegian #ssl #inflightinternet #inflight #internet #mitm #privacy #gogo  
2
Andrew Wilson's profile photoSami Lehtinen's profile photo
2 comments
 
+Andrew Wilson
Well, you just need to add one more encryption layer. Then hacking TLS / SSL solves nothing.
Add a comment...
Communities
26 communities
Work
Occupation
IT professional, Point Of Sale sector
Employment
  • Oy Winpos Ab
    Product manager, 1997 - present
Basic Information
Gender
Male
Other names
samilehtinen, samleh
Story
Tagline
Techie @ Helsinki, Finland
Introduction
See my homepage for more information.
www.sami-lehtinen.net
You might like to take a look at my blog.
www.sami-lehtinen.net/blog
Bragging rights
I'm being sent when others fail
Places
Map of the places this user has livedMap of the places this user has livedMap of the places this user has lived
Previously
Helsinki
Links
Other profiles
Contributor to