phat_hip_prog Posted July 20, 2007 Share Posted July 20, 2007 Hi, I'm wanting to count the number of rows in a table but without having to execute a query first... i.e. to cut down on data transfered... At the moment it's lucky that the table in question has an 'id' field which is small, but when there's thousands of entries, this will still be large. Sorry this does it: $s = "SELECT COUNT(*) as num FROM ".$tn.""; Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.