|
Posted by Neil on 10/30/05 22:58
I'm using varchar. Don't think that should make a difference, especially
since the view seems to work fine otherwise. But, anyway, I'll try nvarchar
and will let you know if it makes a difference.
If you reply to this, please reply in the "Problem with HOST_NAME Function
with Linked View" as noted in my other message. Thanks! And thanks again for
your help!
Neil
"Erland Sommarskog" <esquel@sommarskog.se> wrote in message
news:Xns96FFBFF7AC668Yazorman@127.0.0.1...
> Neil (nospam@nospam.net) writes:
>> Had strange results with using HOST_NAME. I added "=HOST_NAME()" to the
>> criteria column of the view's MachineName field. The view worked fine.
>> Similarly, if I open the view using a pass-through query in the front
>> end, it opens fine. But if I link the view to the front end, it opens
>> with "#Deleted" showing in each field (that's what Access displays when
>> records in a recordset have been deleted, but the recordset hasn't been
>> requeried).
>>
>> If, on the other hand, I hard-code the machine name into the view, then
>> it opens fine when linked to the front end. But something about the
>> HOST_NAME function that's causing it to not be able to get the records
>> (or it gets the records and then loses them).
>
> Not sure I understand this (I still haven't learn Access :-), but there
> is a gotcha here: which datatype is MachineName? I should be nvarchar
> to avoid implicit conversions that precludes use of indexes. Not that I
> can see that this explains behaviour you see above.
>
>
> --
> Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se
>
> Books Online for SQL Server SP3 at
> http://www.microsoft.com/sql/techinfo/productdoc/2000/books.asp
>
[Back to original message]
|