No, I can chime in, that I as well didn't know this. Out of curiosity, has anyone put together a unit test that I could run to demo the differences? Would this be something to add to hibernate, or is it too random?
What kind of difference are you looking to demonstrate?
I don't think hibernate can work around this since there's nothing (that I know) you can set differently on the prepared statement. It's just how the JDBC driver generates the SQL.
You can pull up SQL Profiler and watch the JDBC driver prepare with NVARCHAR or VARCHAR. Maybe it is MS's fault... if you have an index on a VARCHAR and you query with an NVARCHAR parameter, it won't use the index.
-- Serge Knystautas President Lokitech >>> software . strategy . design >> http://www.lokitech.com p. 301.656.5501 e. [EMAIL PROTECTED]
------------------------------------------------------- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 _______________________________________________ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel