Archive for the ‘English’ Category

How to install samba (aka smb) on Red Hat Linux /quick and easy guide

Well, well, well… Just a side thought: I am going to add new tag “Q&EG” (quick and easy guide) to all similar guides from now on. Step 1.1 – install samba via yum: yum install samba Step 1.2 – or via rpm: Obtain Samba rpm from rhn.redhat.com rpm -ivh samba*.rpm Step 2 – config file […]

Posted on February 15, 2012 at 15:49 by admin · Permalink · Leave a comment
In: English, Linux, Q&EG

Problems with mysql installation on Windows 7? Have been there…

Hi Folks! Today I run into an interesting problem with installation of MySQL on my new Windows 7 / 64bit. MySQL just didn’t want to be installed! And stopped during confuguration process. Tried many things, googled for solution, but in most of the cases people said something like this “as this is not your first […]

Posted on February 14, 2012 at 21:33 by admin · Permalink · Leave a comment
In: English, Fighting the system, mySQL

HowTo pg_dump with no password

Ever wanted to have pg_dump running via cron? Well… now you can! Create a file called .pgpass in your user directory and put following content inside: localhost:5432:db_name:db_login:db_pass**** Note: might also be useful to put permissions right: chmod 0600 ~/.pgpass

Posted on January 25, 2012 at 16:53 by admin · Permalink · Leave a comment
In: English, PostgreSQL

Restore PostgreSQL db from backup

psql -U username -h host1 dbname < infile_name_sql

Posted on January 20, 2012 at 10:25 by admin · Permalink · Leave a comment
In: English, PostgreSQL

Backup & Restore mySQL database | quick guide

Create a backup: mysqldump -u username -p password –databases database1 database2 db_name3 > multi_db_names.sql mysqldump –all-databases > alldatabases.sql mysqldump –all-databases | bzip2 -c > databasebackup.sql.bz2 mysqldump –all-databases | gzip > databasebackup.sql.gz Restore from a backup: mysql -u [username] -p [password] [database_to_restore] < [backupfile] gunzip < backup_name.sql.gz | mysql -u username -p password db_name If you […]

Posted on June 28, 2010 at 12:55 by admin · Permalink · Leave a comment
In: mySQL

mySQL csv import via LOAD DATA INFILE

Well it’s actually quite simple. That sample worked for me like a charm: LOAD DATA INFILE “C:\\\\us_mag_sizes.csv” INTO TABLE support_sizes_US FIELDS TERMINATED BY “,” OPTIONALLY ENCLOSED BY “””” LINES TERMINATED BY “\r\n” IGNORE 1 LINES LOAD DATA INFILE “C:\\\\time_pojas.csv” INTO TABLE pt_time FIELDS TERMINATED BY “,” OPTIONALLY ENCLOSED BY “””” LINES TERMINATED BY “\r\n” IGNORE […]

Posted on February 11, 2010 at 18:33 by admin · Permalink · Leave a comment
In: English, sql

New cool web site about… cats and fun :) And more!

Web site called www.mapikcha.com and everybody welcome to visit and create new funny pictures! Like this for example: see more funny pictures on www.mapikcha.com

Posted on January 18, 2010 at 12:05 by admin · Permalink · Leave a comment
In: English, Fun · Tagged with: , ,

RPM’s on Red Hat 5 and “yum”

RPM on Reh Hat Linux seems like a good solution, but sometimes it just gives you headakes and nothing else. Here are few good comand samples to use with RPM’s: To list all installed modules with “mysql-” name: rpm -qa | grep -i ‘^mysql-‘ Forced Update: rpm -Uhv –force MySQL-server-community-5.1.34-0.rhel5.i386.rpm And one more thing… don’t […]

Posted on May 7, 2009 at 12:01 by admin · Permalink · Leave a comment
In: English, Fighting the system · Tagged with: , ,

How to find duplicated values in MySQL (or/and probably any other RDBM)

As an example I take one real (almost) table I have in my db. Structure is very simple : Table name: “words”, field “filename” name of the file and “words” just some information about each file. +—————–+———————+ |   filename     |     words         | +—————–+———————+ Suddenly we had a few files with exactly same name and […]

Posted on February 16, 2009 at 14:55 by admin · Permalink · Leave a comment
In: English, sql · Tagged with: , ,

Not very often used HTML tags

We all know <form> tag, as well as <ul><li> and so on… but how many of web developers used good old (and sometimes not just usefull, but VERY usefull) html tags in forms: <fieldset> <legend> and <optgroup label=”label”></optgroup> in <select> ? here are two good samples to use (taken from my new template engine version): […]

Posted on February 16, 2009 at 14:54 by admin · Permalink · Leave a comment
In: English, JavaScript, WEB2.0 · Tagged with: , ,