From: Erland Sommarskog on
jh (NIE_SPAMUJ_jh(a)radio.kielce.pl) writes:
> dUzytkownik "Erland Sommarskog" <esquel(a)sommarskog.se> napisal w
> wiadomosci
> news:Xns9CC0EFA296CCFYazorman(a)127.0.0.1...
>> I'm not sure that I see the point with this. Or even if it is a good
>> idea. What if SQL Server decides to reorganize the data and make the
>> path invalid?
>
> Well, the path is build on FILESTREAM file group allocation and the
> server cannot change it like in any other database files. Server share
> path cannot be change - you can change it in server service settings.
> File name cannot be change because it's based on GUID stored in the
> table... So I can't see no reason for changing the path by the server
> itself. What's more, it's only for testing purpose and finally I plan to
> access the data via view, when I can call for FilePath() method instead
> of an additinal column in a table.

But did you test calling PathName() directly, rather than using the value
you computed in the trigger?

Also, did you store any values before you made the configuration changes?

One operation that definitely can change the path is if you backup
the database and restore it elsewhere.


--
Erland Sommarskog, SQL Server MVP, esquel(a)sommarskog.se

Links for SQL Server Books Online:
SQL 2008: http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx
SQL 2005: http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx
SQL 2000: http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx

From: jh on
Uzytkownik "Erland Sommarskog" <esquel(a)sommarskog.se> napisal w wiadomosci
news:Xns9CC15A656833DYazorman(a)127.0.0.1...
> But did you test calling PathName() directly, rather than using the value
> you computed in the trigger?

Yes, the same problem.

> Also, did you store any values before you made the configuration changes?

No, I've recreated the tabel and inserted the data once more.

I've installed Visual Studio 2008 Express on my (developer) machine to test
if it's a problem in my library it but unfortunatelly it cannot connect
remote database - only local connections :(

Regards,
Jacek

From: Erland Sommarskog on
jh (NIE_SPAMUJ_jh(a)radio.kielce.pl) writes:
> Uzytkownik "Erland Sommarskog" <esquel(a)sommarskog.se> napisal w wiadomosci
> news:Xns9CC15A656833DYazorman(a)127.0.0.1...
>> But did you test calling PathName() directly, rather than using the value
>> you computed in the trigger?
>
> Yes, the same problem.

OK. Then my main suspicion is that you pass a pointer to an ANSI string
and not a Unicode string for the filename. But that is really a guess.
--
Erland Sommarskog, SQL Server MVP, esquel(a)sommarskog.se

Links for SQL Server Books Online:
SQL 2008: http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx
SQL 2005: http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx
SQL 2000: http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx