asked on May 5, 2014
I am trying to perform a wildcard search in LFQL using the LIKE operator. However, it appears it is not used in the conventional way. For example, here is a sample code snippet that would work in normal SQL but does not work the same way in LFQL:
session.LogIn( repository );
using( LfConnection connection = new LfConnection( session ) )
{
connection.Open();
// This works and returns results.
////string select = "SELECT entry_id, entry_name " +
//// "FROM lf.entry " +
//// "WHERE type = 'document' AND '1' = '1'";
// This doesn't work, it returns no results.
string select = "SELECT entry_id, entry_name " +
"FROM lf.entry " +
"WHERE type = 'document' AND '1' LIKE '1'";
using( LfCommand command = new LfCommand( select, connection ) )
using( LfDataReader reader = command.ExecuteReader() )
if( reader.HasRows )
while( reader.Read() )
{
// Create custom dataset from rows.
}
}
session.LogOut();
Does Laserfiche support the LIKE operator or am I just using it in an incorrect way? Thank you very much!
0
0