src/SqlHandler.h
branchv_0
changeset 11 ccf19c7e7adf
parent 10 7da7173d84b0
child 12 0b38339b871b
equal deleted inserted replaced
10:7da7173d84b0 11:ccf19c7e7adf
   173 		else if (typeId == relpipe::reader::TypeId::INTEGER) return L"integer";
   173 		else if (typeId == relpipe::reader::TypeId::INTEGER) return L"integer";
   174 		else return L"text";
   174 		else return L"text";
   175 	}
   175 	}
   176 
   176 
   177 	void writeIdentifier(std::wstringstream& output, relpipe::writer::string_t identifier) {
   177 	void writeIdentifier(std::wstringstream& output, relpipe::writer::string_t identifier) {
       
   178 		output << L'"';
   178 		for (auto & ch : identifier) {
   179 		for (auto & ch : identifier) {
   179 			if (ch == L'"') output << L"\"\"";
   180 			if (ch == L'"') output << L"\"\"";
   180 			else output << ch;
   181 			else output << ch;
   181 		}
   182 		}
       
   183 		output << L'"';
   182 	}
   184 	}
   183 
   185 
   184 public:
   186 public:
   185 
   187 
   186 	SqlHandler(writer::RelationalWriter* relationalWriter, Configuration& configuration) : relationalWriter(relationalWriter), configuration(configuration) {
   188 	SqlHandler(writer::RelationalWriter* relationalWriter, Configuration& configuration) : relationalWriter(relationalWriter), configuration(configuration) {