Get mysql_affected_rows() in Delphi

Forum related to the ZDBC API-Layer

Moderators: gto, cipto_kh, EgonHugeist

Post Reply
mparak
Senior Boarder
Senior Boarder
Posts: 81
Joined: 12.09.2005, 06:51
Location: Durban South Africa
Contact:

Get mysql_affected_rows() in Delphi

Post by mparak »

I am a newbie to this forum and am unsure of how all of this works.
What I need, is a little help with getting the results of my Insert, Update, Delete queries. The Mysql help forums suggest the mysql_affected_rows() function but I am unable to find a way to use this (PHP?) function using Zeoz in Deplhi (ver 5)
If some kind soul out there can help, it would be greatly appreciated.

Regards

M Parak
Durban South Africa
User avatar
mdaems
Zeos Project Manager
Zeos Project Manager
Posts: 2766
Joined: 20.09.2005, 15:28
Location: Brussels, Belgium
Contact:

Post by mdaems »

After executing the query using a ZQuery component (method ExecSql) you get the number of updated, inserted or deleted records in the 'RowsAffected' property.

Mark
Image
mparak
Senior Boarder
Senior Boarder
Posts: 81
Joined: 12.09.2005, 06:51
Location: Durban South Africa
Contact:

Thank you, It obviously helps to "phone a friend"

Post by mparak »

The answer you gave was elegant and simple. I am just surprised that I struggled with something that obvious.
Well I suppose we often "over think" a problem when in fact the solution is staring us in the face.

Warmest Regards

M Parak
Durban
South Africa
Post Reply