Is this the second query that is failing? It looks like your syntax is for SQL Server, using wildcard %. If you are trying to wildcard it, and you are using Access your query needs to say: select * from configuracion where componente like '*s' Otherwise the query will never return any records.