Successfully extract contents from word document, but how can we save this as CSV file – where all data extracted goes in one row in csv
Document content is like this, which we want to save as one row in sql server Description about the document :
You'll need to parse the text into an object. Each property in the object becomes a column in the CSV. You can then pipe the objects to Export-CSV to create a CSV file.
You might play with ConvertFrom-String – it's able to take a "template" of what your data looks like, and then parse other data into objects based on the template. There are numerous tutorials, as well as the command help, on Convert-FromString.
You must be logged in to reply to this topic.