[PHP-DB] Looking for a recent inserted record

2002-03-27 Thread Jairo Tcatchenco

Hi all!

I have two tables. One have the primary key, that is referenced in
the second. When I have to insert a record in both tables, I do this in
the first, following a select to catch the primary key generated. So
then I insert the rest of data in the second table, with the value to
the foreign key. There is a way to do this better. I'm using postgres.

Thanks.

--
Jairo Tcatchenco
[EMAIL PROTECTED]
Coordenadoria de Defesa Agropecuária - CDA
Secretaria de Agricultura e Abastecimento do Estado de São Paulo -
SAA/SP



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DB] Formating field type text in HTML

2002-02-26 Thread Jairo Tcatchenco

Hi all!

I have a table in postgres with a field type text, where I can
store a formated text. When I take this field to my page, there's no one
html tag inside the content displayed. Can I read the content of the
field, line by line, putting a  at the end? How can I do something
like this?
Inside the database, I used the option \H, to see the result in
HTML. It was ok, with the  in the right place. How can I use this
output in my page? Is it possible to pass the \H to the database using
php?

Thanks a lot.


--
Jairo Tcatchenco
[EMAIL PROTECTED]
Coordenadoria de Defesa Agropecuária - CDA
Secretaria de Agricultura e Abastecimento do Estado de São Paulo -
SAA/SP



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php