In Microsoft Entity Model Framework, how to run a SQL Raw Query

c# entity-framework linq-to-entities search

Question

I'm using Microsoft Entity model framework to access my database. I get an issue while i use this execute query command for executing Sql raw query. Let me know how could i resolve it.

svdc.CreateQuery<VideoMasterTable>(
    "select * from videomastertable WHERE FREETEXT(*, '"+keyword+"')"
    ).ToList();

Thanks in Advance,

Kanal

1
2
4/30/2010 12:54:27 PM

Popular Answer

CreateQuery takes ESQL, not T-SQL. In EF 4 (only), you can use ExecuteStoreQuery instead.

4
4/30/2010 1:02:56 PM


Related Questions





Related

Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow
Licensed under: CC-BY-SA with attribution
Not affiliated with Stack Overflow