> One way I thought to do this is to install the VIEW selected by the user is by ALTER
> VIEWing a fixed name VIEW already installed on SQL Server 2005.
Changing one already installed would be very confusing (not to mention
"thread race"), and hard frmo a security perspective. It would be
better to create a temporary view for the user - or lose the "VIEW"
completely and just use the SELECT. But this isn't really LINQ -
you're juts talking raw commands now
> the UDF is set as the DataSource for a DataGridView.
As you've found - this isn't going to work. LINQ (and other ORM tools)
demand the schema is well known.
Basically, you can't use LINQ for this. I recommend just SqlCommand
and the SELECT, since the VIEW and UDF aren't helping you at all. This
might be one of the rare occasions when I suggest a DataTable as the
data-store. I'm not a fan of DataTable, but it might do the job nicely
here...
Marc
viepia@nospam.com - 09 Mar 2008 13:16 GMT
Using a DataTable made it easy, thanks very much.
Viepia
>> One way I thought to do this is to install the VIEW selected by the user is by ALTER
>> VIEWing a fixed name VIEW already installed on SQL Server 2005.
[quoted text clipped - 15 lines]
>
>Marc