Page 1 of 1

Use the escape string syntax...

Posted: Tue 09 Aug 2011 11:38
by alemstr
A problem with using special symbols:

Code: Select all

var names = new List{"\"}
using (var entities = new DataEntities())
{
	var names = entities.Names
		.Where(o => names.Contains(o.Name))
		.ToList()
}
In DbMonitor I see:

Code: Select all

SELECT 
"Extent1"."Id" AS "Id", 
"Extent1"."Name" AS "Name"
FROM public."Names" AS "Extent1"
WHERE (("Extent1"."Name") = '\)
PostgreSQL write warning in windows logs:

WARNING: nonstandard use of \ in a string literal at character 450
HINT: Use the escape string syntax for backslashes, e.g., E'\.

How to change the code so that PostgreSQL did not write this warning?

Thanks.

Posted: Wed 10 Aug 2011 11:15
by Shalex
Thank you for your report. We will investigate the issue and notify you about the results as soon as possible.

Posted: Wed 10 Aug 2011 12:40
by Shalex
The bug with escape symbols in the query is fixed. We will post here when the corresponding build of dotConnect for PostgreSQL is available for download (in 2-3 weeks).

Posted: Wed 07 Sep 2011 11:15
by Shalex
New version of dotConnect for PostgreSQL 5.50 is released!
It can be downloaded from http://www.devart.com/dotconnect/postgr ... nload.html (trial version) or from Registered Users' Area (for users with valid subscription only): http://secure.devart.com/ .
For more information, please refer to http://www.devart.com/forums/viewtopic.php?t=21944 .