Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- std::ifstream inFile(filePath);
- std::vector <std::wstring> store;
- std::istream_iterator<std::wstring> in_iter(inFile);
- std::istream_iterator<std::wstring> eof;
- //inFile.open(filePath);
- const char* str1 = in_iter;
- const char* str2 = eof.operator++;
- while (in_iter != eof)
- {
- store.push_back(*in_iter++);
- }
- inFile.close();
- for (auto x : store)
- {
- int size = store.size();
- for (int i = 0; i < size; i++)
- {
- std::wstring * ptr = &store[i];
- long length = (*ptr).length();
- pgInsert(pg, (const pg_char_ptr)ptr, length, CURRENT_POSITION,
- data_insert_mode, 0, best_way);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement