locked
How to query a Unicode file name in ADO? RRS feed

  • Question

  • I have a connection

    Provider=Microsoft.ACE.OLEDB.12.0;Data Source=F:\blah;Extended Properties='text;HDR=Yes;FMT=Delimited;Characterset=65001;IMEX=1;ImportMixedTypes=Text'

    and a recordset query rs.Open sSQL, Conn, adOpenStatic where sSQL contains:

    SELECT * from [Σχόλιο UTF-8-BOM - Copy.csv];

    Which throws an error -2147217865   The Microsoft Access database engine could not find the object 'S????? UTF-8-BOM - Copy.csv'. 

    As you can see it does not recognise the Greek file name. How do I do that?

    Wednesday, December 9, 2020 5:37 PM

All replies

  • For the archives, the solution is to use backticks instead of square brackets around the file name.

    This question got no reply, which is not unexpected, 32 of my 60 threads are unanswered.

    I wonder will Microsoft Q & A be any better as a resource?

    Wednesday, December 30, 2020 4:54 PM