I have used a join statement so I don't seem to be able to use the parent/child page relationship so I have been trying to put the id from one table into another
I have tried
function BeforeAdd(&$values,&$message,$inline)
{
global $conn,$strTableName;
$strSQLInsert = "insert into user_profile (user_access_id) values (".$values["id"].")";
db_exec($strSQLInsert,$conn);
}
and
function BeforeAdd(&$values,&$message,$inline)
{
global $conn,$strTableName;
$strSQLInsert = "insert into user_profile (user_access_id) values (id)";
db_exec($strSQLInsert,$conn);
}
and
function BeforeAdd(&$values,&$message,$inline)
{
global $conn,$strTableName;
$strSQLInsert = "insert into user_profile (user_access_id)
SELECT `id`
FROM ".$strTableName." where ".$where;
db_exec($strSQLSave,$conn);
return true;
}
and
function BeforeAdd(&$values,&$message,$inline)
{
global $conn,$strTableName;
$strSQLInsert = "insert into user_profile (user_access_id)
SELECT `id`
FROM ".$strTableName." where id=".$values["id"].";
db_exec($strSQLSave,$conn);
return true;
}
and
function BeforeAdd(&$values,&$message,$inline)
{
global $conn;
$strSQLInsert = "insert into user_profile (user_access_id)
SELECT `id`
FROM user_access where id=".$values["id"].";
db_exec($strSQLSave,$conn);
return true;
}
any thoughts?