aboutsummaryrefslogtreecommitdiff
path: root/client/csv_import.cpp
diff options
context:
space:
mode:
authorUnavailableDev <69792062+UnavailableDev@users.noreply.github.com>2022-10-29 14:19:51 +0200
committerUnavailableDev <69792062+UnavailableDev@users.noreply.github.com>2022-10-29 14:19:51 +0200
commit6d9df6fe97502a852b68c8c8e6781d7208170cae (patch)
tree2485788cf73e7ccaaa02288285cd2f536d65f600 /client/csv_import.cpp
parent28af8ed412224bd8969db98521b67e0f4027ddf7 (diff)
test version
Diffstat (limited to 'client/csv_import.cpp')
-rw-r--r--client/csv_import.cpp32
1 files changed, 32 insertions, 0 deletions
diff --git a/client/csv_import.cpp b/client/csv_import.cpp
new file mode 100644
index 0000000..5507754
--- /dev/null
+++ b/client/csv_import.cpp
@@ -0,0 +1,32 @@
+#include "csv_import.h"
+
+CSV_Import::CSV_Import()
+{
+
+}
+
+
+#include <QString>
+#include <QVector>
+
+QString CSV_Import::csvToSql(QString input){
+
+ QVector<QString> data;
+ QString output = "(";
+
+ data = input.split(",");
+
+ for (int i = 1; i < data.size(); ++i) {
+
+ bool valid;
+ output.append(QString::number(data[i].toInt(&valid, 16)));
+
+ if (i <= data[i].size()) {
+ output.append(",");
+ }
+
+ }
+ output.append(")");
+
+ return output;
+}