Changes:
- let analyzer analyze logs from java/hibernate access (executes of prepared (anonymous) plans)
- ignore “detail:" lines
SVN repo at: http://svn.depesz.com/svn/pgsql-tools/trunk
Changes:
SVN repo at: http://svn.depesz.com/svn/pgsql-tools/trunk
for quite some time i wanted to write about my experiences with combining smtp server with sql server.
this subject for some people might be too boring, for others – it might be seen as a simple howto. but in my opinion it clearly shows that when you combine 2 such technologies outcome is much better then it would seem (it's called synergy in merketoid-speak).
this subject will be divided into several parts, that will be posted separately (yeah, let's get some traffic to website 🙂
also, i hope to extend it in future if/when i'll find something else that can be added/changed in proposed solution.
so, without further ado, let's start:
Continue reading smtp + sql = more than it seems so (part 1)
(pgdba@[local]:5830) 21:45:26 [pgdba] # select version(); version ----------------------------------------------------------------------------------------------------------------------- PostgreSQL 8.3.0 on i686-pc-linux-gnu, compiled by GCC gcc (GCC) 4.1.3 20070929 (prerelease) (Ubuntu 4.1.2-16ubuntu2) (1 row)
well, actually it is not released yet, but at the very least it's named 8.3 in cvs head 🙂
z dosyć losowego powodu wszedłem dziś na google trends i coś sprawdziłem (trzeba kliknąć dalej, nie chciałem dawać wulgaryzmów na pierwszej stronie)…
Continue reading zastanawiająca popularność wulgaryzmów [polish only]
now, imagine a simple scenario:
simple? yes? well. it was. now, enter disaster: orm.
Continue reading how to check if given update is from trigger or why i hate orms?
Changes:
SVN repo at: http://svn.depesz.com/svn/pgsql-tools/trunk
i needed a way to generate ed2k urls based on existing files on my harddrive.
ed2k link looks like this:
ed2k://|file|FILENAME|FILESIZE|CHECKSUM|/
filename and filesize are of course known, but what about checksum? i tried to find some ready program to calculate them, but failed. it might be because i spent something like 3 minutes on it, but anyway – i didn't find it. so i tried to find algorithm description.
luckily there is a nice algorithms description. algorithms, as there apparently are two separate algorithms, not fully compatible with each other.
based on the information i was able to write a short perl script which does the job:
=> cat ed2ksum.pl #!/usr/bin/perl -l use Digest::MD4 qw(md4 md4_hex);open$f,pop or die$!;$c.=md4$b while sysread$f,$b,9728000;print uc md4_hex$c
yes, it is unreadable. but it works. first version was longer (about 15 lines), but then i decided to try to make it shorter. and shorter. and then even shorter. most probably it is not the shortest possible way, but i'm safisfied with it.
how does it work? simply:
=> ./ed2ksum.pl Slony-I-concept.pdf E8715CD212CD75E0EE4B6C526D5BF36A
hope you'll find it useful.
nixternal wrote about boost library for c++.
with it he was able to find the answer to title question in miliseconds (he didn't specify how many, but let's assume that is was less than 10 ms).
so i decided to check how fast can i do it in postgresql …
Continue reading how many 1sts of any month were sundays – since 1901-01-01?
just lately we found interesting case about shared_buffers settings.
the database in question is rather simple:
the server we run it on is not really fancy:
Continue reading shared buffers and their impact on performance