Open main menu

Pathology Education Instructional Resource β

Changes

Genesetdb

882 bytes added, 02:25, 26 October 2013
Created page with "<?php $con= mysqli_connect("localhost", "jrsinger", "U6d19lrBFC48z2fpF1K5PcRy80XS17QC", "genesetdb"); if(mysqli_connect_errno()) { die( "could not connect: " . mysqli_connect..."
<?php
$con= mysqli_connect("localhost", "jrsinger", "U6d19lrBFC48z2fpF1K5PcRy80XS17QC", "genesetdb");
if(mysqli_connect_errno())
{
die( "could not connect: " . mysqli_connect_error());
}
echo'
<html>
<head>
<title>genetable</title>
</head>
<body>
<h1> Genetable</h1>
<table border="1">
<tr>
<th>Experiment Number</th>
<th>Gene ID</th>
</tr>
';
$sql="SELECT * FROM `workaround`;";
$result= mysqli_query($con,$sql);
$pid=1;
$genes=0;
while ($row=mysqli_fetch_array($result))
{
for($i=0; $i<200; $i++)
{
mysqli_query($con,"INSERT INTO TABLE `finalgeneset` VALUES(BIGINT UNSIGNED AUTO_INCREMENT PRIMARY KEY" . $pid . ",". $row[$genes] . ");");
echo '
<tr>
<td>' . $pid . '</td>
<td>' . $row[$genes] . '</td>
</tr>
';
$genes++;
}
$pid++;
$genes = 0;
}
echo'
</table>
</body>
</html>
';
?>
4
edits