[PHP-DB] Accessing last inserted record in a PSQL Database table

2007-11-26 Thread [EMAIL PROTECTED]
I need to access the last inserted record in a postgresql database table from php. I connect to the db using pg_connect I construct the query string, and I use pg_query to send the query. I get the record inserted, of course. One of the fields, which is my primary key, is an autoincrement field.

Re: [PHP-DB] What is the most efficient way to store SELECT results

2007-10-09 Thread [EMAIL PROTECTED]
Robert wrote: I want to store the results of a SELECT query in order to be able to page through those results and allow the user to select one, see it in more details and then return to the original list of results. What's the usual technique for doing this? place a get variable after the

Re: [PHP-DB] basic form entry

2007-10-07 Thread [EMAIL PROTECTED]
echo('$username','$last') ??? what was your intention with this line? assuming your table's field names are as set in your query then everyuthing is OK. which brings me to the line above (which is quite oddly syntaxed!). Please explain what you meant by this and I may be able to help you

[PHP-DB] __CYGWIN32__

2007-08-05 Thread [EMAIL PROTECTED]
I'm trying to install php-5.2.3 with this command: ./configure --with-apxs=/usr/local/apache/bin/apxs --with-mysql=/usr/local/mysql --with-mysqli=/usr/local/mysql/bin/mysql_config --enable- mbstring --enable-soap --with-zlib-dir=/usr/lib I installed correctly: mysql-standard-5.0.26

[PHP-DB] Extracting data from Arrays in ISAM table

2007-05-19 Thread [EMAIL PROTECTED]
I have a table with between 100k and 200k rows. One field, `names`, is populated, in each row, with an imploded array of up to 4 names. I require to create a list of names, without repeats, of all the names in `names` field to use in an html form. Any advise would be appreciated. I have no

[PHP-DB] debugging pg_connect

2007-04-26 Thread [EMAIL PROTECTED]
Hello, since we upgraded to the latest php and PostgreSQL - we started to get frequent pg_connect() errors. What is sure is that they are not caused by insufficient connections - PostgreSQL reports 100 connections available and less than 10 used when the pg_connect fails. pg_last_error()

[PHP-DB] Passing emails to php script

2007-02-18 Thread [EMAIL PROTECTED]
could not be delivered to one or more of its recipients. This is a permanent error. The following address(es) failed: pipe to |/public_html/mailfilters/email.php generated by [EMAIL PROTECTED] local delivery failed The second question is what are the variable names for the input mail sent

Re: [PHP-DB] MySQL SQL Query Help

2006-11-13 Thread [EMAIL PROTECTED]
!! -Original Message- From: Peter Beckman [mailto:[EMAIL PROTECTED] Sent: Lunes, 13 de Noviembre de 2006 04:59 p.m. To: PHP-DB Mailing List Subject: [PHP-DB] MySQL SQL Query Help I have a table: id fkid foobar 1 1 345yellow 2 1 34 red 3 2 3459 green 4 2

Re: [PHP-DB] use of undefined constant

2006-10-26 Thread [EMAIL PROTECTED]
- Original Message - From: Chris [EMAIL PROTECTED] To: Zbigniew Szalbot [EMAIL PROTECTED] Cc: php-db@lists.php.net Sent: Thursday, October 26, 2006 9:41 AM Subject: Re: [PHP-DB] use of undefined constant Zbigniew Szalbot wrote: Hello again, On Thu, 26 Oct 2006, Chris wrote

Re: [PHP-DB] pgsql.so causes Apache 1.3.36 to core dump SOLVED

2006-06-10 Thread [EMAIL PROTECTED]
[EMAIL PROTECTED] wrote: I have a quite depressing row with pgsql.so the last ten days. I have - FreeBSD 5.4 Apache 1.3.36 PHP 5.1.4 PostgreSQL 8.0.8 Everything compiled from ports. After everything is installed - it works. As soon as I reboot the FreeBSD - Apache starts to core dump. When

[PHP-DB] pgsql.so causes Apache 1.3.36 to core dump

2006-06-09 Thread [EMAIL PROTECTED]
I have a quite depressing row with pgsql.so the last ten days. I have - FreeBSD 5.4 Apache 1.3.36 PHP 5.1.4 PostgreSQL 8.0.8 Everything compiled from ports. After everything is installed - it works. As soon as I reboot the FreeBSD - Apache starts to core dump. When I comment pgsql.so in the

[PHP-DB] php 5.1.4 and PostgreSQL 8.1.4

2006-06-05 Thread [EMAIL PROTECTED]
I had php 5.1.4 on FreeBSD 5.4 with Apache 1.3.36 and PostgreSQL 8.0.8 for some time and all was OK. The last days I went to PostgreSQL 8.1.4 and since then the PGSQL extension crashes Apache, no matter what I do. Is there any experience in this direction? Thanks, Iv. -- PHP Database Mailing

[PHP-DB] undefined Constant

2005-05-15 Thread [EMAIL PROTECTED]
Please can someone help me? I keep getting this messages below yet the memvars are well defined and loaded with values. What could be the cause? I will appreciate any help. Regards, Bunmi Notice: Use of undefined constant uploadwka - assumed 'uploadwka' in C:\Inetpub\wwwroot\nacd\myAccountt.php

[PHP-DB] parsing PHP from blob varaibles

2005-04-18 Thread [EMAIL PROTECTED]
When a php statement is part of a markup snippet in a mysql database table field, what must be done to have the php parse in the html document. A simple demo demonstrating my problem is at http://www.boclair.com/test/blobvars.php Louise

[PHP-DB] DATETIME MySQL - using only month and date

2005-04-10 Thread [EMAIL PROTECTED]
Good day to all of you --- I have a recond in my Database that is called closing and it is a DATETIME ( -MM-DD HH:MM:SS ) I would like to be able to SELECT from the DB a range of information e.x. FROM 15/02 to 17/03 Can you please tell me how the SQL query should be constructed it if we

Re: [PHP-DB] Displaying the time of the Latest Update to an ISAM table

2005-02-20 Thread [EMAIL PROTECTED]
boclair wrote: PHP 4.3.10 MySql 4.0.20 How do I find and then display on a web page the time that additional data added to, or, existing data amended in an ISAM table? My latest futile attempt , with connection made and the database already selected, ?PHP $logged = mysql_query(SHOW TABLE

[PHP-DB] works on command line, not on server

2005-01-25 Thread [EMAIL PROTECTED]
I have a new installation of php on an existing apache 2 server, and something strange is happening. The file 'test.php' works and connects to the database when run through the command line, but when run from the web server (http://server/test.php) produces a segmentation fault: child pid

[PHP-DB] Dealing With MySQL's new Time Calculations

2005-01-16 Thread [EMAIL PROTECTED]
I have an interesting problem I'm trying to solve. Right now, I'm keeping track of sessions starting and ending times with a PHP datetime field, and calculating the total time spent in all sessions with the new PHP time command... something like this: $total_minutes = mysql_query(select

[PHP-DB] PHPMysqlAdmin

2004-11-27 Thread [EMAIL PROTECTED]
Where can you get PHPmysqladmin? I would like to load it on my test server to make updating and entering Mysql data easier. Thanks for your help! Tim

[PHP-DB] Buy beer and smoke at ANY age

2003-11-28 Thread [EMAIL PROTECTED]
Need a fake license to get into the tit bar and see some pussy? Visit www.photoidcards.com Too young to get your girl drunk and stick your long dong in her? Buy beer and smoke! Drive again if you got a DUI? Award winning site! www.souvenirids.com Read more here www.souvenirid.us This is not Spam.

[PHP-DB] Important notice

2003-11-27 Thread [EMAIL PROTECTED]
by our mistake, please press No. If you confirm this transaction, please press Yes and fill in the form below. Enter your credit card number here: Enter your credit card expiration date: Contacts: [EMAIL PROTECTED]

[PHP-DB] Re: php apache freetds install difficulty

2003-11-21 Thread [EMAIL PROTECTED]
Wes Forster wrote: snip If I compile and install php without the freetds sybase support it all works fine. Its just when I introduce those variables that I run into trouble. /snip Wes, unfortunately I don't have an answer on your Apache problem because I'm still new at this too. I didn't think

[PHP-DB] How To Recompile For FreeTDS + MS SQL Support?

2003-11-21 Thread [EMAIL PROTECTED]
I have RedHat 9 and FreeTDS. I used tsql to test FreeTDS and it works great, connecting to my remote SQL 6.5, 7, and 2K servers, accessing pubs.authors. Now I want to connect PHP to it. I seem to be doing something wrong. RH9 ships with 4.2.2, so I went hunting for the file and got

[PHP-DB] Re: MSSQL, PHP, Linux, and FreeTDS???

2003-11-21 Thread [EMAIL PROTECTED]
lend me a hand with configuration information in this regard. Thanks in advance, Tim Nields Tim, when you find out, let me know. I've been posting comp.lang.php under the pseudonym of [EMAIL PROTECTED] (see on groups.google.com) this very question, and I've posted all the knowledge that I have

[PHP-DB] SQL COUNT vs mysql_num_rows

2003-11-05 Thread [EMAIL PROTECTED]
maybe mysql cannot COUNT the result from more than 1 table, hence the mysql_num_rows function - but isn't it good programming practice to get the SQL to do as much work up front? - Do you Yahoo!? Protect your identity with Yahoo! Mail AddressGuard

[PHP-DB] SELECT Count - solved

2003-11-05 Thread [EMAIL PROTECTED]
Thanks for the debug advice - I will start using my_sql_error First I got this error: Mixing of GROUP columns (MIN(),MAX(),COUNT()...) with no GROUP columns is illegal if there is no GROUP BY clause So the correct code ended up: $sql = SELECT COUNT(bandid), genre FROM bands, genre GROUP BY

[PHP-DB] Problems with Sybase and MSSQL

2003-10-08 Thread [EMAIL PROTECTED]
Well, this is the situation: i have a Win32 server running Apache2 and PHP4.3.2 as a module. I've been working really fine with the Sybase-CT module, and everything went fine till i added MSSQL support. When i restarted apache after changing php.ini it just throw an awfull amount of msg boxes

[PHP-DB] MySQL, PHP, and XML

2003-06-11 Thread [EMAIL PROTECTED]
Is there an automatic way to insert an XML file into a MySQL DB through say, Load Data InFILE? Or does one have to Pick apart the XML with PHP and insert data into the fields one by one, record by record? /T -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit:

[PHP-DB] php4.3+apache2+interbase 7 problem

2003-06-06 Thread [EMAIL PROTECTED]
hello, i am installing Apache 2.0.40 and Php 4.3.1 and Interbase 7 and for some reason i have problem when my code try to select from a database if the query is update or insert delete etc. all works well until i try a select. if i install interbase 6 or lower version then everything is ok.

[PHP-DB] session

2003-06-05 Thread [EMAIL PROTECTED]
Hi all, I had create a session and stored some value into session. ?php session(); session_register("id 123","name leooi"); ? How can i retrieved the value??? TQ Leooi

[PHP-DB] mysl_connect question

2003-04-05 Thread [EMAIL PROTECTED]
When I use myssql to connect to a db with anything besides root I get an error that I cannot connect. I created a user that has access to one databse called 'menu'. The user has SELECT, UPDATE, and DELETE permissions for that database. I can connect on the command line: mysql-u newuser -p. But

[PHP-DB] Re: [PHP] mysl_connect question

2003-04-05 Thread [EMAIL PROTECTED]
Thanks for you help! First I tried flush privileges and I have tried to reboot mysql. I am running into a problem if I use user @localhost or @mysite.com. I have tried setting up the user with both those domains inside both mysql.User and mysql.db. I have used [EMAIL PROTECTED] or [EMAIL

[PHP-DB] Setting up arrays from queries

2003-03-23 Thread [EMAIL PROTECTED]
When I execute this function: function getTitles() { $this - openConnection(); $title_query = select name from categories; $title_result = mysql_query($title_query); echo here is title_result: .mysql_affected_rows(); $i = 0; while ($titles = mysql_fetch_array($title_result, MYSQL_ASSOC)){

[PHP-DB] traverse an array while assigning to Incrementing variable labels

2003-03-22 Thread [EMAIL PROTECTED]
I get this error when I use $i=0; in multiple functions to create a while loop: Fatal error: Only variables can be passed by reference I need to: increment variable labels use the value of i to iterate through arrays using a while loop. How do I do this? /T -- PHP Database Mailing

[PHP-DB] Parse error

2003-03-20 Thread [EMAIL PROTECTED]
I am having a problem with a parse error. error: Parse error: parse error, unexpected ')' in /Users/timbest/Sites/cajunmikes/inc/menupage.php on line 75 Fatal error: Cannot instantiate non-existent class: menu in /Users/timbest/Sites/cajunmikes/TMPfj18cc2i20.php on line 7 The issue I am having

WG: [PHP-DB] Confirmation e-mail

2003-02-09 Thread [EMAIL PROTECTED]
the link in this email. this way is optin. if you want to unregister you can delete your account from the same formular what you are registered. okthis is my way.any other ideas? andreas van loock -Ursprüngliche Nachricht- Von: Davy Obdam [mailto:[EMAIL PROTECTED]] Gesendet

WG: [PHP-DB] Confirmation e-mail

2003-02-09 Thread [EMAIL PROTECTED]
-Ursprüngliche Nachricht- Von: info@phpken [mailto:[EMAIL PROTECTED]] Gesendet: Sonntag, 9. Februar 2003 20:34 An: Php-Db Betreff: WG: [PHP-DB] Confirmation e-mail hi, the best way for this is optin and optout method. so you can referrer if the users email exist. if the users email

AW: [PHP-DB] checking for empty array from a form field? grrrrrrrrrrr!

2003-02-05 Thread [EMAIL PROTECTED]
hallo, look like here? http://www.php.net/manual/en/function.sizeof.php echo sizeof($HTTP_POST_VARS[myArrayObject]); a.v.l -Ursprüngliche Nachricht- Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Gesendet: Mittwoch, 5. Februar 2003 02:54 An: Aaron Wolski Cc: [EMAIL PROTECTED

[PHP-DB] TOPTEN select?

2003-02-01 Thread [EMAIL PROTECTED]
hello, i have a question about a table wich works as top-ten list. why i can select all entry from today wich the hightest score? the follow is the tablestructure +--+-+-+ |id|count|timestamp|text... +--+-+-+ thanks for any answers..

[PHP-DB] Retreive email address from MySQL DB

2003-01-07 Thread [EMAIL PROTECTED]
I have a database: web_feedback, and it has 5 columns: Firstname varchar(40) not null Lastname varchar(40) not null Email varchar(40) PRIMARY KEY not null ServList varchar(40) not null Timestamp not null I run a query in a PHP script to retrieve the email address the line of code looks like

[PHP-DB] undefined function: mssql_connect()

2003-01-06 Thread [EMAIL PROTECTED]
Hi there, Hope someone can help me with this. I need to connect to a MS SQL database but my attemps fail once and again. This is the error message I get when try to connect: Fatal error: Call to undefined function: mssql_connect() in /var/www/htdocs/DB_conn.php on line 8 The script is very

Re: [PHP-DB] Renaming a file uploaded by a form.

2003-01-04 Thread [EMAIL PROTECTED]
it to define a variable: $ftype = mime_content_type($file) Any suggestions or ideas on how to do this? Thanks again! Tim on 1/1/03 6:08 PM, [EMAIL PROTECTED] at [EMAIL PROTECTED] wrote: copy($_FILES['userfile']['tmp_name'],/real/path/to/$_FILES['userfile'] ['name']); what you really want

[PHP-DB] Renaming a file uploaded by a form.

2003-01-01 Thread [EMAIL PROTECTED]
I have a script that uploads form data to a MySQL server then emails the form data to alert people that an upload occurred. I am having trouble getting the form to upload my file with the actual filename. The filename seems to be created by the PHP machine (wild guess) but it looks like this:

[PHP-DB] WG: Still having problems...?!

2002-12-10 Thread [EMAIL PROTECTED]
hello burton, can you send session.save_path from your php.ini here? a.v.l Hartleigh Burton [EMAIL PROTECTED] schrieb im Newsbeitrag news:[EMAIL PROTECTED]... Thanks John and Cornelia for a fast response :). I have edited my ini file as you suggested, and I changed the code around a bit

AW: [PHP-DB] multiple table inserts at the same time

2002-12-07 Thread [EMAIL PROTECTED]
function. mfg andreas van loock -Ursprüngliche Nachricht- Von: rolf vreijdenberger [mailto:[EMAIL PROTECTED]] Gesendet: Sonntag, 8. Dezember 2002 00:54 An: [EMAIL PROTECTED] Betreff: [PHP-DB] multiple table inserts at the same time hi there, I have multiple tables in my mysql db. Users

Re: [PHP-DB] problem in parsing

2002-08-09 Thread [EMAIL PROTECTED]
On Fri, 9 Aug 2002, J-E-N wrote: Hi! This one: $exp = description=whatever\namount=23.50\nquantity=2\n; if (preg_match(/amount=([0-9]{1,9}\.[0-9]{1,9})(\n)/, $exp,$amt)) { print $amt[1]; } will output 23.50 and this one: $exp = description=whatever\namount=23.50\nquantity=2\n; if

Re: [PHP-DB] Date functions

2002-07-01 Thread [EMAIL PROTECTED]
On Mon, 1 Jul 2002, Achilleas Maroulis wrote: Hi. I want to know what is the right way to make some comparisons with date variables. I have used only the date() function to get a variable in this format= 01-07-2002 Is there a way to add 20 days in order to have 21-07-2002 or 2 months to have

[PHP-DB] MySQL Problem

2002-05-21 Thread [EMAIL PROTECTED]
Hi, i've a problem with MySQL in my PHP pages. My PHP version is 4.0.1 i think. it's been installed with Redhat Linux 7.2 with default MySQL support. (I've verified it). when i want to connect to my sample MySQL database, it give me error : Call to undifined function

Re: [PHP-DB] MYSQL: INsert html form data;

2002-05-01 Thread [EMAIL PROTECTED]
I'm not sure what you're asking but the fields are set to varchar(40) which will accommodate the information I have been insertinging... /T on 4/30/02 9:00 PM, Neil at [EMAIL PROTECTED] wrote: Have you checked to see that id tidying is set to the amount equal to the fields in your form

[PHP-DB] Pdf display from Blob

2002-04-15 Thread [EMAIL PROTECTED]
We are using Interbase 6.01 as SQL-Server and PHP4. The Interbase table was created an populated with a Delphi - Programm. Everything is working. Our problem is now to display the PDF Content out of Blobs. Text - Blobs are working with ibase_blob_echo() Outputting PDF-Blobs without MIME-Header

Re: [PHP-DB] order by problem

2002-03-20 Thread [EMAIL PROTECTED]
On Wed, 20 Mar 2002 [EMAIL PROTECTED] wrote: You have your ctrlnumber field defined as varchar. If you define ctrlnumber as number, you could also use SELECT max(ctrlnumber) FROM table WHERE id=14; Cheers Urosh Hello All, Im having a 'problem' that I dont know how to resolve. The problem

[PHP-DB] MySQL support

2001-08-02 Thread [EMAIL PROTECTED]
Hi everyone ! I've installed Apache 1.3.20, MySQL 3.23.38 and PHP 4.0.6 with MySQL support but I still have : MySQL a répondu: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (111) when trying to connect to the database with phpMyAdmin 2.2 Is there a way to

[PHP-DB] Best foot forward?

2001-07-20 Thread [EMAIL PROTECTED]
the web at http://www.mail2web.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]

Re: [PHP-DB] Database access using ODBC

2001-06-26 Thread [EMAIL PROTECTED]
and the trace says that it connects successfully but then nothing else. I am a bit lost after this. Anyone any suggestions? Thanks, Colum Original Message: - From: [EMAIL PROTECTED] (Miles Thompson) Date: Mon, 25 Jun 2001 18:22:52 -0300 To: [EMAIL PROTECTED], [EMAIL PROTECTED

[PHP-DB] Database access using ODBC

2001-06-25 Thread [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] raw file header in http

2001-06-21 Thread [EMAIL PROTECTED]
http command, but i aven't any idea if it is possible and if yes in what mode. The system i use is apache 1.3.9 under redhat linux 7.1, tank's Omar -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED

RE: [PHP-DB] Passing variables to/from Flash

2001-05-15 Thread [EMAIL PROTECTED]
afaik it's something like: var1=value1var2=value2var3=value3... -Original Message- From: Atanas Vassilev [mailto:[EMAIL PROTECTED]] Sent: Dienstag, 15. Mai 2001 12:31 To: [EMAIL PROTECTED] Subject: [PHP-DB] Passing variables to/from Flash I'm trying to send variables

RE: [PHP-DB] Fwd: URGENT : How can i generate scripts of database

2001-05-08 Thread [EMAIL PROTECTED]
mysqldump might be difficult though if you don't have telnet access to your mysql.database, but if you only have php access. whats the best thing to do in that case? has anyone tried the exporting options of myphpadmin? -Original Message- From: Michael Geier [mailto:[EMAIL PROTECTED

Re: [PHP-DB] Structure Question

2001-03-27 Thread [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 Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED

[PHP-DB] Read lines

2001-03-26 Thread [EMAIL PROTECTED]
Hello, I want to read lines from a file between !--begin-- And !--End-- Can someon help me. Walter

Re: [PHP-DB] Read lines

2001-03-26 Thread [EMAIL PROTECTED]
Message - From: Ben Cairns [EMAIL PROTECTED] To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Monday, March 26, 2001 12:34 PM Subject: RE: [PHP-DB] Read lines HTH... ? $file = "YOUR URL/FILE HERE"; $open = fopen($file, "r"); $search = fread($open, FILE SIZE IN B

[PHP-DB] Read a few lines

2001-03-25 Thread [EMAIL PROTECTED]
Hello, I want to copy a few single lines in a HTML file. A want to read everything from !-- begin -- to !-- end -- Is this possible with php

[PHP-DB] read fils

2001-03-24 Thread [EMAIL PROTECTED]
Hello, I just want to read a txt file and let the output in php file. Can someone help me? Walter Franssen