Fijate si así te sirve.
Código PHP:
<?php
if(isset($_POST['hijo'])){
$conn= mysql_connect("localhost", "Usuario", "Contraseña");
mysql_select_db("Base de datos", $conn);
$hijo = $_POST['hijo'];
$result = mysql_query("SELECT PARAMNOMCOR FROM tabla WHERE PARAMNOMCOR LIKE '$hijo%'", $conn);
while($row = mysql_fetch_array($result, MYSQL_BOTH)){
echo $row['PARAMNOMCOR'];
}
}else{
?>
<form method="post">
<input type="text" value="Nombre del Hijo" onclick="this.value=''" name="hijo" size="16">
<input type="submit" value="Buscar Padre">
</form>
<? } ?>
Y al reves, para buscar hijos del padre:
Código PHP:
<?php
if(isset($_POST['padre'])){
$conn= mysql_connect("localhost", "Usuario", "Contraseña");
mysql_select_db("Base de datos", $conn);
$padre = $_POST['padre'];
$result = mysql_query("SELECT PARAMNOMCOR FROM tabla WHERE PARAMNOMCOR LIKE '%$padre'", $conn);
while($row = mysql_fetch_array($result, MYSQL_BOTH)){
echo $row['PARAMNOMCOR'];
}
}else{
?>
<form method="post">
<input type="text" value="Nombre del Padre" onclick="this.value=''" name="padre" size="16">
<input type="submit" value="Buscar Hijos">
</form>
<? } ?>