Actually yes it is very simple to do...
I've wrote a couple of bits for PHP.net on the subject...
My answer below may scare you but its really not that hard if you know Oracle....
$connection = OCILogon('Username','Password','//Mypath');
$sql = "SELECT * FROM MyTable";
$statement = oci_parse($connection, $sql);
oci_execute($statement);
while ($row = oci_fetch_array($statement)) {
$MY_ID = $row['MY_ID'];
$Item1 = $row['Item1'];
$Item2 = $row['Item2'];
$Item3 = $row['Item3'];
}
There are little picky things in Oracle that will drive you up the wall...
Like LIMIT
instead of LIMIT use WHERE ROWNUM <= 2
remember to use <= because the documentation in Oracle is WRONG just = does not work... In fact I find Oracle has a lot of bad documentation...
however I do like Oracle Press Books....
also i like orafaq.com
Also Oracle uses a temp table called "dual" but you probably already know this...
And you have to use Sub Queries for more complicated things like,
$sql = "SELECT * FROM (SELECT Log_ID, Item_LVL, TO_CHAR(ASTS_ITEM.END_DTM, 'MM-DD HH24:MI') AS END_DTM, FROM LOG WHERE ITEM_ID = '$value' ORDER BY LOG_ID DESC) WHERE ROWNUM <= 1";
Just to bring back the max row.... MAX() is not always an option and usually a bad one although highly recommended by Ask Tom on OTN
So remeber to DESC your query WHERE ROWNUM <= 1 works the same as LIMIT 1 go figure...
Notice the TO_CHAR deal, this is how you format dates coming back from Oracle...
This sucks, but I have learned to like it....
Ah the big killer is that you have to use nextval on inserts... This will kill most MySQL guys as MySQL uses an autoincrement function and in Oracle you have to create either a Trigger or a Sequencer with Grant, Constraints and Synonyms...
If you know Oracle no big deal...
here's an example of an insert....
$sql = "INSERT INTO LOG (LOG_ID,ITEM_ID,CRE_BY,CRE_DTM,ITEM_LVL)
VALUES
(ASTS_LOG_S.nextval,$value,".$_SESSION['LoginID'].",sysdate,$lvl)
";
The above is a cut and paste minus a whole buck of variables...
I think that gives you a small idea of sysdate, nextval, etc...
Entering dates have to be done in a certain format...
sysdate will be your friend when entering the current date time, or if you need to add a month or a few years...
The best beginner book to learn Oracle is this one...
http://www.nerdbooks.com/item.php?id=0072255404
It will give you an awesome foundation....
As far as PHP you just have to play with what is on PHP.net, it does work but make sure you take a look at the user input... I have a few things on there where I had to correct what was previously mis documented by whoever....
Good Luck....
I still LOVE MySQL especially MySQL 5 I think it kills Oracle...
But my job requires me to use Oracle... atleast though I get to use PHP....
<grin>