View Single Post
Old 02-02-2007, 01:54 AM   #1 (permalink)
tommyboy123x
 
Ultra Techie

Join Date: Sep 2005

Posts: 638

tommyboy123x is on a distinguished road

Send a message via AIM to tommyboy123x
Default A quicker question

go to next post for details

code:

PHP Code:
<?php
$link 
mysql_connect("server""username""password") or die(mysql_error());
mysql_select_db("database") or die(mysql_error());

$x 0;
$y 0;

mysql_query("CREATE TABLE temp(
id INT NOT NULL AUTO_INCREMENT,
PRIMARY KEY(id),
    username VARCHAR(30),
    referralcommision INT)"
)
    or die(
mysql_error());

while (
$x >= 101){
    while (
$y >= 101){
        
$afs2 'afs'.$x.$y;
        
mysql_query("ALTER TABLE 'temp' ADD '$afs2' VARCHAR(30) NULL DEFAULT NULL") or die(mysql_error());
        
$y++;
        }
    
$x++;
    }
echo 
'Table Updated!';
?>

__________________

Some real (as in actual) surveys that pay money!
tommyboy123x is offline