diff --git a/core/src/main/java/com/yahoo/ycsb/Client.java b/core/src/main/java/com/yahoo/ycsb/Client.java
index 5b2c827e068c32a8ddda38173cb31fb6c871ff21..bcf33c2e0a485c7c18488a2cf799380037d96898 100644
--- a/core/src/main/java/com/yahoo/ycsb/Client.java
+++ b/core/src/main/java/com/yahoo/ycsb/Client.java
@@ -743,7 +743,15 @@ public class Client
 			}
 
 			
-            Thread t=new ClientThread(db,dotransactions,workload,threadid,threadcount,props,opcount/threadcount, targetperthreadperms);
+            int threadopcount = opcount/threadcount;
+
+            // ensure correct number of operations, in case opcount is not a multiple of threadcount
+            if (threadid<opcount%threadcount)
+            {
+              ++threadopcount;
+            }
+
+            Thread t=new ClientThread(db,dotransactions,workload,threadid,threadcount,props,threadopcount, targetperthreadperms);
 
 			threads.add(t);
 			//t.start();