₦airaland Forum

Welcome, Guest: RegisterLoginWith GoogleTrendingRecentNew

Stats: 3,330,978 members, 8,448,064 topics. Date: Sunday, 19 July 2026 at 04:52 PM

Toggle theme

Pros $ Cons Of PDO And Mysqli - Webmasters (2) - Nairaland

Nairaland ForumScience/TechnologyWebmastersPros $ Cons Of PDO And Mysqli (7349 Views)

1 2 Reply (Go Down)

Re: Pros $ Cons Of PDO And Mysqli by exHuman: 12:58pm On May 06, 2015
Will comment in......
Re: Pros $ Cons Of PDO And Mysqli by abeltolu: 3:58pm On May 06, 2015
Thats why I love my CakePHP. No need for all this code jargons. I can build most apps half the time it will take you to do raw php.
Re: Pros $ Cons Of PDO And Mysqli by nwadiuko1(m): 4:01pm On May 06, 2015
What in blackberry's name are all ya niggies talkin about?
Re: Pros $ Cons Of PDO And Mysqli by udokpuenyi(m): 5:51pm On May 06, 2015
abeltolu:
Thats why I love my CakePHP. No need for all this code jargons. I can build most apps half the time it will take you to do raw php.
Inasmuch as frameworks accelerate the programming job, but knowing the core php codes, functions syntax and functionalities is very important in case if you run into issues that may require a custom logic. Many a times, the is always the case
Re: Pros $ Cons Of PDO And Mysqli by olareed(m): 6:04pm On May 06, 2015
Confused
Re: Pros $ Cons Of PDO And Mysqli by Nobody: 6:13pm On May 06, 2015
Usually,
$db = mysqli("host", "username", "password", "db" );

if($db->connect_errno) die('Connection failed:' .connect_error);

$sql_query = "SELECT * FROM 'tableName'";

$result = $db->query($sql_query);

while ($row = $result->fetch_array()){
//process rows here
}

$result->close();
$db->close();
Re: Pros $ Cons Of PDO And Mysqli by osile2012(op): 9:33am On May 07, 2015
lordjay:
OP, except i don't understand what you're talking about, but I use rowCount() to fetch number of rows in PDO and it works perfectly for me.
Returns the number of affected rows in Delete, Insert and Update statement not select in most dbases.
Re: Pros $ Cons Of PDO And Mysqli by osile2012(op): 1:40pm On May 07, 2015
olukenzo:
Usually,
$db = mysqli("host", "username", "password", "db" );

if($db->connect_errno) die('Connection failed:' .connect_error);

$sql_query = "SELECT * FROM 'tableName'";

$result = $db->query($sql_query);

while ($row = $result->fetch_array()){
//process rows here
}

$result->close();
$db->close();
This will work, but not for prepared statements
1 2 Reply

What Are The Pros And Cons Of Using An Online Payment GatewayWhat Are The Pros And Cons Of Sharing Adsense With A FriendPros And Cons Of Buying Facebook Likes & Twitter Followers234

How To Download Any Skillshare Course For Free -skillshare Account Not Needed-4 Things Any Blogger Who Want To Be The Next rated Should Aim - TechinfoChoosing A Reliable And Efficient Web Hosting And Domain Registration platform.