Re: [PHP-DB] PHP+ postgresql help?
print_r? Am I about to learn something new? Be still, my beating heart! On Tue, 21 Aug 2001, speedboy wrote: $conn = pg_connect (host=localhost user=username password=password bname=dbname); $sql = SELECT * FROM database where lower('$name%') order by last;; $result = pg_exec($conn, $sql); for ($i = 0; $i pg_numrows($result); $i++) { $row = pg_fetch_array($result, $i); echo pre; print_r($row); echo /pre; } -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP-DB] Stress tesing a DB
I'm gathering data on open-source databases... is there a program that can provide comparisons between databases, such as MySQL and PostgreSQL? -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] cites/states data
It's public info, so free, and Hah! Try to get the 9-digit ZIP code stuff. Developed with tax dollars and sold by (I believe) a private corporation. Isn't it great that we're not getting all of the government we're paying for? -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] Subtracting times?
check out http://www.php.net/manual/en/function.mktime.php If you still need assistance, I'm here. On Sun, 24 Jun 2001, Matthew Cothier wrote: I really need help here. What I am trying to do is the following. - $today = date(m.d.y); $time = date(g:i a); if($row[3] == $today){ if(($row[4] $time) and ($time $row[6])){ print(Now Showing); } else { print(Today at $row[4]); } } else { print($row[3] at $row[4]); } $row[3] -- Date stored in database i.e 06.23.01 $row[4] -- Start time stored in database i.e 7.00 pm $row[6] -- End time stored in database i.e 7.30 pm My problem is that when it looks for the difference in time it works fine with say : start time = 7:00 pm end time = 8:00 pm But as soon as I go into: start time = 7:00 pm end time = 7.35 pm it mucks up! Please help!! What do I need to do? _ Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] Testing MySQL failed ???
Mysql isn't up? On Sun, 1 Apr 2001, Szeto wrote: Hello The code below i use in testing the connection (written in php4) ? if(!mysql_connect("localhost","khaimun","akyweb")) { print "could not connect to mysql!"; } mysql_select_db("focalmail"); ? --- Warning: MySQL Connection Failed: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (111) in /var/www/html/test/test-db.php4 on line 2 could not connect to mysql! Warning: MySQL Connection Failed: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (111) in /var/www/html/test/test-db.php4 on line 5 Warning: MySQL: A link to the server could not be established in /var/www/html/test/test-db.php4 on line 5 Note : The above error i get in executing the code -- -- Any suggestions would be appreciated. Thank You Khai Mun, Ng -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] Testing MySQL failed ???
Excellent diagnosis, sir! However, it is woefully and pitifully short on curative information. On Sun, 1 Apr 2001, Felix Kronlage wrote: On Sun, Apr 01, 2001 at 06:50:24PM +0800, Szeto wrote: I am new to Linux environment so what. You could still read the error-message: | Warning: MySQL Connection Failed: Can't connect to local MySQL server | through socket '/var/lib/mysql/mysql.sock' (111) in this suggests, that you take a look at /var/lib/mysql to see if mysql.sock is there. -fkr -- gpg-fingerprint: 076E 1E87 3E05 1C7F B1A0 8A48 0D31 9BD3 D9AC 74D0 |http://www.hazardous.org/ | whois -h whois.ripe.de FKR-RIPE | |all your base are belong to us | shame on me | fkr@IRCnet | -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP-DB] Storing sensitive information in MySQL
Ahhh my favorite subject. Privacy. There are two PHP functions that do _exactly_ what you're looking for. Mcrypt_encrypt and mcrypt_decrypt. If you're looking for just enough encryption to keep the curious out, use a single password for all encryption. If you want military-grade encryption, have each person choose a (strong) password. I'd suggest Rinjdael or twofish as the encrypting algorithm. On Thu, 1 Mar 2001, Dreamvale wrote: Hi, I have a situation where some sensitive information need to be stored in a database, eg salary, medical info, etc. the data are only meant for the particular employees. however, the root user will have all the power to retrieve both the key (stored somewhere either in a file, or php scripts, or db), and the database too, hence can (not necessary will) read the sensitivie information. is there any techniques, or products to be used to solve this problem? thanks. -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]