John is right. In fact one routinely calls two different $result(s) when
coding nested loops:
while( $details = mysql_fetch_array( $result ) ) {
while ( $Email = mysql_fetch_array( $result2 ) )
..
}
}
when executing the next instance of your loop:
while( $details = mysql_fetch_array( $
You have to create a table:
CREATE TABLE product_categ (
FK_productID ,
FK_categID
)
and list all relationships "productID belongs to categID"
Ignatius
- Original Message -
From: "Doug Coning" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: T
One possibility:
table questions( questionID, question_text, ...) PRIMARY KEY( questionID)
table answers( FK_questionID, individualID, answer_code, ...) PRIMARY KEY(
FK_questionID, individualID)
For very simple online polls, there is a nice tutorial in Devshed:
http://www.devshed.com/Server_Side
A mix-up in your loop. Try:
while ( $row = mysql_fetch_array( $result ) ) {
echo $row['Field'] ;
}
(you may just as well use the field names provided by SHOW COLUMNS - more
readable than numerical indexes)
HTH
Ignatius
- Original Message -
Hi Martin,
I am sure that many would love to help you, but really you must explain your
problem more clearly! Can you give more details?
Ignatius
- Original Message -
From: "Martin Allan Jensen" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent:
Why don't you want to do this with SQL?
Ignatius
- Original Message -
From: "Martin Allan Jensen" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, November 11, 2002 2:48 PM
Subject: [PHP-DB] arrays & db
Okey people, i try again!!
You can not do it directly.
You have to create a new table as a copy of the old one:
CREATE TABLE new_table
SELECT * FROM old_table
Your problem will be that the MySQL "PHP" user will probably not have the
CREATE rights.
Ignatius
"Rodrigo San Martin"
Just loop through the first index, then search on the second index:
while ( list( $key, $value ) = each( $my_arr ) ) {
// now $value is your ( [0] => 10 [1] => 40 [2] => 50 [3] => 80 [4] =>
130 [5] => 220 [6] => 320 ) array
// sort your array by values
sort( $value ) ;
// get the
Great piece of advice Mike. Thanks. Far from obvious. I was stuck with this
problem since a few days.
Will that also apply to n-dimensional array, like:
document.form["system[]"][0][1] ?
Ignatius
- Original Message -
From: "Ford, Mike [LSS]" <[
http://localhost/myscript.php?var1=blah&var2=blah2
Ignatius
- Original Message -
From: "Gavin Amm" <[EMAIL PROTECTED]>
To: "Php-Db (E-mail)" <[EMAIL PROTECTED]>
Sent: Wednesday, November 20, 2002 7:30 AM
Subject: [PHP-DB] $_get 2 variables
> H
Martin,
what you are experiencing is the normal way to call form variables. There is
no problem.
You should use
register_globals=Off
whenever possible. better security.
Ignatius
- Original Message -
From: "Beau Lebens" <[EMAIL PROTECTED]>
To:
You could create an auxiliary table nb_1_10 containing a field nb with all
integers from 1 to 10
Then perform a SELECT join:
SELECT nb_1_10.*
FROM ABC, nb_1_10
WHERE nb_1_10.nb NOT IN ABC.number
AND < some condition that returns only one row from ABC - like here
(1,4,6,10) >
Ignatius
___
Well, is there an input field in your form whose name corresponds to . ?
It is more likely that if you have a dynamic form your fields will be called
by a ID identifier, like
price is 12 EUR
Where 12 is the price of grommet with ID 1012 in your DB
So perhaps your javascript generator echoes the w
If you use MySQL:
SELECT DATE_ADD( $my_date, INTERVAL n DAY ) AS new_date ;
Ignatius
- Original Message -
From: "Dankshit" <[EMAIL PROTECTED]>
To: "PHP" <[EMAIL PROTECTED]>; "PHP1" <[EMAIL PROTECTED]>
Sent: Thursday, November 28, 2002 6:06 PM
S
Very simple procedurally (though not in SQL).
Here's the pseudo-code:
Execute:
SELECT * FROM Y WHERE U = 'me'
ORDER BY Y, X
$flag = "last_y" ; // flag indicating whether or not your
mysql_fetch_array() brings a new value of Y
Loop your query result {
if Y <> $flag['last_y'] {
// thi
DESCRIBE tbl_name col_name
Ignatius
- Original Message -
From: "Bastian Vogt" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, December 02, 2002 1:41 PM
Subject: [PHP-DB] mysql - enum
> Hi,
>
> is it possible to get all possible va
I do not understand your first question.
Your query in effect shows duplicates.
To prevent future duplicates, you can do it in two ways:
1. with MySQL:
create a unique index on what should be unique, most likely the email (it
looks like your business logic implies one entry per email)
in fact you
n submission. How do I go about
letting
> the user know they have entered an already existing address?
>
>
> "Ignatius Reilly" <[EMAIL PROTECTED]> wrote in message
> 030801c29b8b$8bd88ee0$015a@server">news:030801c29b8b$8bd88ee0$015a@server...
> > I do
Well, we can only offer very general guidelines at this stage.
What you can do is write a script that:
- call all the URLs showing paintball prices (btw what is a paintball?)
- extract the product name and price. this will require a specific REGEX for
each URL called, and regular testing vs change
Simply append a parameter to the URL:
action="same_page.php?selector=1"
your script will take various actions based on a switch:
switch $_POST['selector'] {
case 1 : etc.
Ignatius
___
- Original Message -
From: "Gavin Amm" <[EMAIL PROTECTED]>
To:
If you're on a Window$ system, try \r\n instead of \n
Ignatius
- Original Message -
From: "NIPP, SCOTT V (SBCSI)" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, December 05, 2002 5:28 PM
Subject: [PHP-DB] Newline help...
> I must
Test successful. Congratulations.
Ignatius
"You can't trust the Russians. They have no word for 'détente'".
- Original Message -
From: "Art Chevalier" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, December 05, 2002 8:38 PM
Subject
I would replace
$query = "SELECT * FROM accounts WHERE verifyurl='$safe_verify_string'";
by
$query = "SELECT * FROM accounts WHERE verifyurl='{$safe_verify_string}'";
to force interpolation of variable $safe_verify_string
HTH
Ignatius
- Original Me
Try:
$query = "INSERT INTO anagrafe (codice,nome, cognome, codicefiscale)
VALUES ('"
.strtoupper($codicefiscale)
."','{$NOME}','"
.strtoupper($cognome)
."','"
.strtoupper($co
dicefiscale)
."', etc"
then
mysql_query ( $query ) ;
Ignatius
- Original
Very likely you have to GRANT the CREATE permission to your PHP user
account.
Also investigate the CREATE TEMPORARY TABLE grant status available since
version 4+. Very convenient.
Ignatius
- Original Message -
From: "Jonathan" <[EMAIL PROTECTED
A typical way to use it is
mysql_***( *** ) or die( mysql_error() ) ;
> -Original Message-
> From: Ignatius Reilly [mailto:[EMAIL PROTECTED]]
> Sent: Friday, December 06, 2002 3:34 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [PHP-DB] CREATE TABLE QUERY PHP/MySQL
>
> Very
What do you mean by formatted text?
All you can enter in a textarea is a sequence of characters belonging to
your encoding schema (including non-printing characters).
Ignatius
- Original Message -
From: "Keith Spiller" <[EMAIL PROTECTED]>
To: <
Try:
SELECT DISTINCT F.question, F.answer
FROM Faqs AS F, FaqsRelatedToProducts Table AS FP
WHERE F.faqid = FP.faqid
DTH?
Ignatius
- Original Message -
From: "Michael Knauf/Niles" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, Decem
lots of excellent resources on www.devshed.com, notably a PHPShop tutorial
and a catalogue implementation.
Ignatius
- Original Message -
From: "Hynek Semecký ME" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, December 11, 2002 11:5
なるほど.
私も,そう言う問題に会った.
Ignatius
- Original Message -
From: "Martin Allan Jensen" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, December 12, 2002 2:26 PM
Subject: [PHP-DB] flytte bsd harddisk til anden pc
Hej Allesammen, har et strt
$SQL = " SELECT * FROM resources where unit_id='{$unit_id}' order by level
";
Ignatius
- Original Message -
From: "Alex Francis" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Saturday, December 14, 2002 8:37 PM
Subject: [PHP-DB] Selecting mo
You should write:
$myquery = "SELECT * FROM user WHERE username = '{$user}' ..." ;
As a bonus, it is much more readable.
Ignatius
- Original Message -
From: "David" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, December 16, 2002 2:
The difficulty you are being confronting could be alleviated by using an XML data
model (meaning non relational). Of course, I don't know about your requirements, but
it could be a direction worth investigating.
I use the php_xslt.dll (sablotron) extension, which I find works quite pleasantly.
Another possibility is after each page call to rewrite the client's cookie's validity
to, say, current time + 1800s:
session_start() ;
setcookie( session_name(), session_id(), time()+1800, "/" ) ;
ob_start() ;
// etc.
If the user does not call a page for more than 30', the cookie will be destroy
Hi Mignon,
it is really quite simple:
you can pack several screens (each containing for instance a form) in a same script.
each form contains a hidden field, say "selector"
now, the script begins by a switch:
if ( isset( $_POST['submit'] ) ) {
switch ( $selector ) {
// Switch 1: process the
You can do it very nicely with MySQL:
$query = "SELECT WEEKDAY( '{$mydate}' )" ;
Provided your date is correctly formatted ( -mm-dd )
Ignatius
- Original Message -
From: "Rodrigo Corrêa" <[EMAIL PROTECTED]>
To: "PHP1" <[EMAIL PROTECTED]>
Se
problem 1:
move the WHERE clauses to the ON clauses
problem 2:
Obviously your intent with " COUNT(ads_clickrate.date) " is to count the
number of non-null occurences of click. But COUNT() is not the appropriate
function to do this (it will simply give you the number of rows inside a
group).
Try r
as
an id, unique and required, instead of "name")
Ignatius
- Original Message -
From: "Lisi" <[EMAIL PROTECTED]>
To: "Ignatius Reilly" <[EMAIL PROTECTED]>; "PHP-DB"
<[EMAIL PROTECTED]>
S
m?"
D. Ivester, CEO, Coca Cola
- Original Message -
From: "Lisi" <[EMAIL PROTECTED]>
To: "Ignatius Reilly" <[EMAIL PROTECTED]>; "PHP-DB"
<[EMAIL PROTECTED]>
Sent: Thursday, January 09, 2003 1:11 PM
If you are using MySQL, you can't.
(none of my business, but why not simplifying your table names: "faqProduct"
instead of "faqRelatedToProduct" ?)
Ignatius
- Original Message -
From: "Michael Knauf/Niles" <[EMAIL PROTECTED]>
To: <[EMAIL PROTEC
table only.
Therefore:
WHERE YEAR(ads_displayrate.date) = '2003' AND MONTH(ads_displayrate.date) =
'01'
(if your table ads_displayrate has such date fields).
HTH
Ignatius
- Original Message -
From: "Lisi" <[EMAI
.
Ignatius
- Original Message -
From: "Henrik Hornemann" <[EMAIL PROTECTED]>
To: "Ignatius Reilly" <[EMAIL PROTECTED]>
Cc: "PHP-DB" <[EMAIL PROTECTED]>
Sent: Wednesday, January 15, 2003 10:56 AM
Su
The simplest seems to store the date normally in the DB.
When you need your special "Cinema" date, just do a modulo 7:
myDayOfWeek = ( WEEKDAY( '2003-01-17' ) + 3 ) % 7
HTH
Ignatius
- Original Message -
From: "Matthew Nock" <[EMAIL PROTECTED]>
Quite doable.
Check the IMAP functions.
Ignatius
- Original Message -
From: "Baumgartner Jeffrey" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, January 15, 2003 5:19 PM
Subject: [PHP-DB] Mail() and replies
> Is there any way to
Dunno.
I also remember once having a parse error, but it was on line 35.
Cheers
Ignatius
- Original Message -
From: "David Rice" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, January 23, 2003 8:53 PM
Subject: [PHP-DB] need help s
It is safe to test if the divisor is zero:
replace
columnB/columnC
by
IF( columnC = 0, 0, columnB/columnC )
(the "0" could be anything else; this depends on your business logic)
Ignatius
- Original Message -
From: "Jeremy" <[EMAIL PROTECTED]
What is your problem exactly?
Have you investigated the MySQL manual under:
LOAD DATA INFILE
SELECT ... INTO OUTFILE ?
Ignatius
- Original Message -
From: "Bruno Pereira" <[EMAIL PROTECTED]>
To: "PHP-db list" <[EMAIL PROTECTED]>
Sent: Friday, J
Doubly wrong PHP syntax.
Try instead:
$sql = "SELECT * FROM accessnums WHERE areacode='{$_POST['areacode']}' and
city='{$_POST['cityselected']}' ORDER BY network LIMIT 1";
Ignatius
- Original Message -
From: "jason wesley upton" <[EMAIL PROTECT
If you want to use WHERE clause, see the
INSERT table
SELECT ...
syntax.
Extremely convenient. You inherit all the flexibility of the SELECT
statement.
Ignatius
- Original Message -
From: "Doug Thompson" <[EMAIL PROTECTED]>
To: "Ike Austin" <
Or rather
SUBSTRING_INDEX(str,delim,count)
Because you want to use a custom delimiter (space, comma)
Ignatius
- Original Message -
From: "Peter Lovatt" <[EMAIL PROTECTED]>
To: "Bruce Levick" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Thur
It is not easy to design a SQL query that will repeat headers every 33 rows.
So this should be done in the PHP code.
Why not use a counter, that you increment at every mysql_fetch_array() and
test if !( $counter % 33 )
Side remarks: you could also define a CSS class for TH and use TH as
headers.
You can append to the URL a dummy variable that is sure to change every
time:
http://.../mypage?nocache=
This will force the refresh.
Ignatius
- Original Message -
From: "Philip Zee" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, Fe
Investigate PHP's IMAP functions.
Ignatius
- Original Message -
From: "Dave Carrera" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, February 25, 2003 8:09 AM
Subject: [PHP-DB] Grabbing emails into MySql
Hi All
How would I go about
If your array is multidimensional, you could store it in a javascript-style:
// get the print_r()
// replace (recursively) all instances of "Array( .. )" by "[...]"
If you ever plan to write a class or a function to do that, let me know!
Ignatius
-
Still not good. Try:
"SELECT a.item_id, a.subtotal, a.quantity
FROM shopping_cart a, orders b
WHERE b.session_id = ".session_id()."
AND b.customer_id = $customer_id
AND a.order_id = b.border_id"
session_id() must be interpolated.
Ignatius
- Original Message -
From: "Co
You must use absolute path names "c:\\..." in copy().
As a matter of personal hygiene, I would not recommend to use file/ dir
names containing spaces in your document root directory (or any place that
the PHP user must have access).
Why not try c:/apache/htdocs ?
Ignatius
- Original Message
Yes. You have to use the "subtype" relational design:
USER
user_id (PK)
|
|
| ||
| |
The way to go is:
${"tips_".$i} where $i is your increment control variable
HTH
Ignatius, Brussels
"Where the fuck is Belgium?" (D. Ivester, CEO, Coca-Cola)
- Original Message -
From: "David Rice" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, March 09, 2003 1:34 PM
Subject: [
Take a look at the MySQL DATE_FORMAT() function.
Ignatius
- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, March 13, 2003 2:43 PM
Subject: [PHP-DB] sorting problem...
> Hi All,
>
> I need to sort some da
The standard relational way is a relationship table:
children
-
FK_parentID (parent)
FK_childrenID (child)
PRIMARY KEY ( FK_parentID, FK_childrenID )
HTH
Ignatius
- Original Message -
From: "Alain Barthélemy" <[EMAIL PROTECTED]>
To: "ph
Largely off topic palso.
This mailing list does not care about what you have to say on this subject.
It is a great professional tool for many of us, and does not need to be
polluted.
Ignatius
- Original Message -
From: <[EMAIL PROTECTED]>
To: <
I have been using Dezign for Databases from Datanamic for several years.
http://www.datanamic.com/
Not free, but invaluably helpful. I strongly recommend it.
Ignatius
- Original Message -
From: "Snijders, Mark" <[EMAIL PROTECTED]>
To: <[EMAIL P
Another approach:
1. Load all results from the query in an array
2. Sort the array using a custom-defined user-defined comparison function
( usort() ). Study the example in the PHP manual.
Writing your own comparison function is easy:
- explode your IP addresses in 4 items each ( explode() )
- com
What you can do is replicate all s with hidden fields:
Al di Meola
John McLaughlin
...
...
But I fail to see why so doing would be useful. Your dynamic form is created
after some query; therefore why not simply call the same query after
submission to obtain all possible values of the options
Check the TIME_FORMAT(time,format) MySQL function.
Ignatius
_
- Original Message -
From: "Lisi" <[EMAIL PROTECTED]>
To: "PHP-DB" <[EMAIL PROTECTED]>
Sent: Tuesday, June 17, 2003 1:16 PM
Subject: [PHP-DB] time without seconds
> If I have a time stored in MySQL, and
Try also DBTools (forWindows). Very nice. Been using for 2 years, and happy
about it.
http://www.dbtools.com.br/EN/
Ignatius
_
- Original Message -
From: "Achilles Maroulis" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, June 19, 2003 10:46 AM
Subject:
$extract = preg_replace( "/[^0-9]/", "", $str )
// will extract the figures from your string
HTH
Ignatius
_
- Original Message -
From: "Jamie Saunders" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, June 26, 2003 1:04 PM
Subject: [PHP-DB] checking a s
I don't know the reason (perhaps OS-based, since tables are implemented as
eponymous files), but it was a pretty awful idea to allow special chars in
names in the first place.
you probably have only two options, equally unpleasant:
- rename your tables and columns
- back-tick all your non-standard
Your SQL looks legal (at least for MySQL). Probably a PHP error then.
Do a die( $query ) to see if the query is well-formed and $thisID correctly
interpolated.
Personnally I would rather write:
$query="
UPDATE Choice
SET visits = visits + 1
WHERE ID = {$thisID}
; "
[if ID is o
SELECT DISTINCT unit...
Ignatius
_
- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, August 07, 2003 3:37 PM
Subject: [PHP-DB] Breaking down a table field
> I have a table, wth many entries.
> Each entry has been asigned a
- Original Message -
From: "Dillon, John" <[EMAIL PROTECTED]>
To: "PHP-DB List" <[EMAIL PROTECTED]>
Sent: Tuesday, August 19, 2003 11:47 AM
Subject: [PHP-DB] Queries probably timing out
I'm doing queries on tables with 45,000 rows in one table and 1-2000 rows in
a
Sorry I don't seem to get it.
1. What is"the import function provided in PHPList" ?
2. What do you mean by "initialize each data record " ?
Ignatius
_
- Original Message -
From: "Creigh Shank" <[EMAIL PROTECTED]>
To: &
Read the MySQL manual.
"0" value is interpreted as 2000.
Your empty string is converted to an integer, thus 0.
HTH
Ignatius
_
- Original Message -
From: "Peter Beckman" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, August 27, 2003 3:39 AM
Subject: [P
e logical. I have no quarrel with this behaviour.
Ignatius
_
- Original Message -
From: "Peter Beckman" <[EMAIL PROTECTED]>
To: "Ignatius Reilly" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Wednesday, August 27, 2003 4:13 PM
hundreds of what? rows or columns?
Ignatius
_
- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, August 28, 2003 11:35 AM
Subject: [PHP-DB] Simple field replace...?
> Hi there,
> I need to take a field in my database, and remove
Then a simple substring will do:
UPDATE mytable
SET url = SUBSTRING( url FROM 5 )
btw your date column looks pretty awful.
HTH
Ignatius
_
- Original Message -
From: <[EMAIL PROTECTED]>
To: "Ignatius Reilly" <[EMAIL PROTECTED]>
Cc: &l
(I do not know
what SQL-92 says about this). Therefore data validation should be done
outside MySQL.
Ignatius
_
- Original Message -
From: "Martin Marques" <[EMAIL PROTECTED]>
To: "Ignatius Reilly" <[EMAIL PROTECTED]>; "Peter Bec
You may decide that another RDBMS may suit your needs better. Someone
told me that Oracle is quite nice.
Ig
_
- Original Message -
From: "Martin Marques" <[EMAIL PROTECTED]>
To: "Ignatius Reilly" <[EMAIL PROTECTED]>; "Peter
SUBSTRING()
_
- Original Message -
From: "Shaun" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, August 29, 2003 11:57 AM
Subject: [PHP-DB] SELECT Part of a Field
> Hi,
>
> How can I SELECT a portion of a field in a table for example the first
> charac
You should be very wary of the CREATE TABLE ... SELECT statement.
>From experience, the types created are not always conform to intuition -
I've had my share of nasty surprises
Much safer to do a CREATE TABLE statement defining the column types, then do
an INSERT INTO ... SELECT
Ignatius
What is your data load method? What is the type of your table(s)?
With LOAD DATA and text files, I load several million rows in about a
minute.
Also please don't cross-post. Better first find out what the most suitable
mailing list is.
Ignatius
_
- Original Message --
UNION appeared in MySQL 4.0.0
Mayhap your provider has not yet upgraded.
There is no such thing as disabling/ granting UNION.
HTH
Ignatius
_
- Original Message -
From: "John Ryan" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, August 31, 2003 8:58 PM
Sub
There are many good user-contribued examples in the online PHP manual at
function readdir()
Ignatius
_
- Original Message -
From: "FB" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, September 05, 2003 11:55 AM
Subject: [PHP-DB] all files in a directory
read the PHP manual and examples under the function mysql_fetch_array().
I find the MySQL manual is very well done and helpful. I've been using it as
a reference for 2 years. Take a harder look!
Ignatius
_
- Original Message -
From: "-{ Rene Brehmer }-" <[EMAIL PRO
Quotes missing around $value. Try instead:
mysql_query( "UPDATE tablename SET {$name} LIKE '{$value}' WHERE ID={$id}")
Of course, even though the code does not show, you have properly validated
user input before firing this query...
HTH
Ignatius
_
- Original Message -
Yeah, banking is too serious a business in Argentina, as everybody knows, to
entrust to MySQL.
Ignatius
_
- Original Message -
From: "Martin Marques" <[EMAIL PROTECTED]>
To: "nabil" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]>
Sent: Wednesday, September 24, 2003 9:24 PM
If your mail server supports IMAP, you should use the PHP IMAP functions.
Very convenient.
Ignatius
_
- Original Message -
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, September 24, 2003 11:42 PM
Subject: [PHP-DB] Re: Email Application
> Hey
SELECT
TRIM( TRAILING
'.'
FROM TRIM( TRAILING '0' FROM mycol )
)
Ignatius
_
- Original Message -
From: "Shaun" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, October 03, 2003 5:12 PM
Subject: [PHP-DB] Round a number
> Hi,
>
> I have a query that r
l Message -----
From: "Ignatius Reilly" <[EMAIL PROTECTED]>
To: "DB list PHP" <[EMAIL PROTECTED]>; "Shaun" <[EMAIL PROTECTED]>
Sent: Friday, October 03, 2003 5:27 PM
Subject: Re: [PHP-DB] Round a number
> SELECT
> TRIM( TRA
Can't you do without REGEX?
eg WHERE employ_id = '($employ_id)' OR company LIKE '($name)'
REGEXes are expensive.
Ignatius
_
- Original Message -
From: "Shannon Doyle" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, October 09, 2003 10:18 AM
Subject: [
Problem is, REGEX will only test for a match, not returning anything other
than 0|1
You can instead:
1. Use a UDF doing just that (counting occurences in a string):
http://www.tsc.ro/free/
(haven't tried it myself, because no Windows dll available)
2. Replace successively all figures by '' and c
Specify it only at function definition:
myFunction( &$var1, &$var2 ) {
// ...
}
$var = myFunction( $var1, $var2 ) ;
Ignatius
_
- Original Message -
From: "Jeremy Shovan" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, October 09, 2003 9:54 PM
Subjec
$time = "0900" ;
$time2 = substr( $time, 0, 2 ).":".substr( $time, 2, 2 ) ;
Ignatius
_
- Original Message -
From: "Delz" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Saturday, October 11, 2003 7:17 AM
Subject: [PHP-DB] TIME FORMAT USING PHP
> Hi All,
>
> We h
SELECT *
FROM table
WHERE column IN ( 'this', 'that', 'theother' )
Ignatius
_
- Original Message -
From: "Robbie Staufer" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, October 16, 2003 12:10 AM
Subject: [PHP-DB] query for multiple value
One solution is to use a javascript to set your hidden field to
"already_submitted" (or such) at the end of the last form page. Therefore
upon refresh, the user will come to the "already submitted" page. Add one
"already submitted" switch case.
BTW your construct
switch ( ) {
} else
is quite non-
mysql_fetch_array( $result )
_
- Original Message -
From: "Devon" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, October 20, 2003 3:30 PM
Subject: [PHP-DB] Using two colomns of mysql data as key/value pairs in
arrays
> I have been scouring the online do
Easy, old boys.
Nobody has "holed" or meant to hole anybody.
Let's keep this ML what it is, that is a great learning and working
instrument.
Ignatius
_
- Original Message -
From: "Jon Kriek" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Monday, October 20, 2003
have a look at the PEAR date package.
http://pear.php.net/package/Date
_
- Original Message -
From: "OpenSource" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Sunday, November 02, 2003 11:13 PM
Subject: [PHP-DB] date function
Hi guys,
This might not be the be
SQL. Backticks force reading the string as a SQL object (db, table, column),
as opposed to a string.
Eg you could in theory have columns called "select" or "Mes Documents", and
do:
SELECT * FROM `select` AS S, `Mes Documents`AS MD ...
of course it is wholly unadvisable to do so.
Best to steer cl
The jpgraph library is what you're looking for.
_
- Original Message -
From: "Hull, Douglas D" <[EMAIL PROTECTED]>
To: "Note To php mysql List (E-mail)" <[EMAIL PROTECTED]>
Sent: Monday, November 10, 2003 8:36 PM
Subject: [PHP-DB] dynamic graph on web site
In php/
101 - 200 of 200 matches
Mail list logo