func (q *Queries) GetSavedByCreator(creator string) ([]SavedQuery, error) {
	var saved []SavedQuery
	if err := q.DB.Find(&saved).Error; err != nil {
		return saved, err
	}
	return saved, nil
}
GetSavedByCreator to get a saved query by creator
package queries
import (
	"fmt"
	"github.com/jinzhu/gorm"
)
type SavedQuery struct {
	gorm.Model
	Name    string
	Creator string
	Query   string
}