Contents
How to check your content search query for errors?
Or you can copy a query from Word or Excel, and then paste it in a plain text editor, such as Microsoft Notepad. Save the text file and select ANSI in the Encoding drop-down list. This will remove any formatting and unsupported characters. Then you can copy and paste the query from the text file to the keyword query box.
What causes a search query to return an error?
Unsupported characters are often hidden, and they typically cause a search error or return unintended results. Smart quotation marks – Smart single and double quotation marks (also called curly quotes) aren’t supported. Only straight quotation marks can be used in a search query.
How to prevent unsupported characters in content search?
Unsupported characters are typically added to a query when you copy the query or parts of the query from other applications (such as Microsoft Word or Microsoft Excel) and paste them in the keyword box on the query page of a Content Search. The best way to prevent unsupported characters is to just type the query in the keyword box.
Is there an encoding issue with SQL Server varchar?
We recently had an issue with encoding related to a field that’s being stored as a varchar (120) in SQL Server. In SSMS, the varchar appears as: “Who Killed JonBen‚t?” However, when it’s brought into python, it appears as:
What happens if a tag contains more than one thing?
If a tag contains more than one thing, then it’s not clear what .string should refer to, so .string is defined to be None: This is exactly your case. Your tag contains a text and tag. Therefore, the find gets None when trying to search for a string and thus it can’t match.
How to search by text inside a tag?
First let’s take a look at what text=”” argument for find () does. NOTE: The text argument is an old name, since BeautifulSoup 4.4.0 it’s called string. Although string is for finding strings, you can combine it with arguments that find tags: Beautiful Soup will find all tags whose .string matches your value for string.