如何使用golang和Go-echo导出Excel模板文件?

huangapple go评论73阅读模式
英文:

How to export a excel template file using golang and Go-echo?

问题

我需要将一个特定模板的 Excel 文件导出,并将其作为行导入到 PostgreSQL 中。我不知道如何使用 go-echo 和 gorm 来实现这一点。有人可以告诉我如何做吗?

英文:

I need to export a excel file of a specific template and import it back to insert into postgres as rows.
I don't know how to do this using go-echo and gorm.
Can someone tell me how i can do that?

答案1

得分: 0

首先,阅读Excel数据,然后将数据映射到结构体,最后通过gorm将其写入PostgreSQL。我不知道go-echo在这里的作用是什么。

英文:

First read the Excel data, then map the data to Struct, and finally write it to PostgreSQL through gorm,I don't know what go-echo does here

huangapple
  • 本文由 发表于 2022年5月31日 13:59:39
  • 转载请务必保留本文链接:https://go.coder-hub.com/72442857.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定