Skip site navigation (1) Skip section navigation (2)

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search archives
  Advanced Search

I give up.



I have a db wrapper.  Ok here is code and explanation :

Now the thing is the CONTENT part that I'm trying to print is text.

Oh and note in both version all ALL, other fields have the correct vaules in them.

ok. The slab of text contains about a paragraph and in side the pragraph is the following text ->
www:1{register}.

Now when I print out the array (from pg_fetch_row). I get with the non working code just the string "Register".

but with the working code i get the whole paragraph. about 50 words or so.

ALSO. if I put the working code inside the dbwrapper. e.g $recordset->getRow().
Inside the getRow() function I tried :

$f = pg_fetch_array($this->resultset,0);
          echo "<BR>INSIDEID:".$f[0]."<BR>";
          echo "<BR>INSIDEC:".$f[5]."<BR>";

and it still printed "Register" not "Welcome blah blah blah blah www:1{register} balh blah blah"


//  THIS DONT WORK.------------------------------------------------------
  $b = new dbObj;
  $b->init("");

  $morebs = new recordset;
  $morebs = $b->exec($query);
  $b->free();
  $bsarray = $morebs->getRow();
  echo "<BR>MYBSARRAYid:".$bsarray[0];
  echo "<BR>MYBSARRAYCONTENT:".$bsarray[5];
  $morebs->free();

//====================================================================
//THIS DO WORK
$datab = pg_connect("host=localhost user=sbe password='' port=5432 dbname=nexgen");
  $result = pg_exec($datab, $query);
  pg_close($datab);
  $thearray = pg_fetch_array($result,0);
  echo "<BR><BR>WORKFYA :".$thearray[0];
  echo "<BR><BR>WORKFYA :".$thearray[5];

//==============================================================




Home | Main Index | Thread Index

Privacy Policy | About PostgreSQL
Copyright © 1996 – 2012 PostgreSQL Global Development Group