+ Start a Discussion
Priya AakankshaPriya Aakanksha 

I am doing traihead but its showing error.

global class SendReminderEmail implements Database.Batchable<sObject> {
    global Database.QueryLocator start(Database.BatchableContext bc) {
    global void execute(Database.BatchableContext bc, List<Speaker__c> scope) {
    global void finish(Database.BatchableContext bc) {
Compile Error: Missing return statement required return type: Database.QueryLocator at line 2 column 34    
Best Answer chosen by Priya Aakanksha
Neha AggrawalNeha Aggrawal
Hi Priya,

Please add a return statement to start method:
global Database.QueryLocator start(Database.BatchableContext BC){
return Database.getQueryLocator(query);

This is my constructor:
global SendReminderEmail(String q)
I hope you find the above solution helpful.
Thanks and Regards, 
Neha Aggrawal
www.initaura.com - Everything Salesforce (http://www.initaura.com)