I am practising with the AdventureWorks database for now and I will be receiving strings like the following: SalesOrderNumber=SOH123 and CustomerID=1. The strings may not always contain =, as they may be >, <, >=, <=, !=, <>. Ideally, I would like to split each string into 3 fields – the database column to query, the comparison (e.g. =, >,
Tag: text-parsing
Parse and reformat text with optionally occurring trailing characters
Due to horrible and inconsistent formatting by a certain website we are receiving data from, I need to parse the following string and print new strings after replacing/removing one or two substrings. Desired result: How can I parse a line with two ‘-‘ into the corresponding Owner: name format? My current code: Answer This will definitely fail in the future,