Export: support export in postgresql (#58553)

This commit is contained in:
Ryan McKinley
2022-11-10 14:16:31 -05:00
committed by GitHub
parent 47055561ec
commit f92d978386
13 changed files with 109 additions and 45 deletions
+1 -2
View File
@@ -3,7 +3,6 @@ package export
import (
"path"
"strconv"
"strings"
"github.com/grafana/grafana-plugin-sdk-go/data/sqlutil"
@@ -64,7 +63,7 @@ func exportUsage(helper *commitHelper, job *gitExportJob) error {
for _, usage := range dump {
rows, err := sess.DB().QueryContext(helper.ctx, usage.sql)
if err != nil {
if strings.HasPrefix(err.Error(), "no such table") {
if isTableNotExistsError(err) {
continue
}
return err