Results 1 to 4 of 4

Thread: Development continues. Lianja 5.6 supports full text queries across virtual tables

  1. #1
    Lianja Development Team barrymavin's Avatar
    Join Date
    Feb 2012
    Location
    UK, USA, Thailand
    Posts
    6,030

    Development continues. Lianja 5.6 supports full text queries across virtual tables

    Hot on the heels of Lianja 5.5.1, I am now working on 5.6 and I have added the remaining functionality in to support full text searches across virtual tables such as MSSQL and MySQL using instant selections.

    The Lianja database supports the contains("word1,word2,word3...") function which is specific to it.

    The new cursoradaptor.requery() method can now translate any contains() in the query for the syntax of the target database engine. Internally it uses the new cursoradaptor.translatequery() method.

    See below full text search across records in MySQL.

    Name:  Screen Shot 2020-11-17 at 4.08.10 PM.jpg
Views: 82
Size:  116.2 KB
    Last edited by barrymavin; 2020-11-17 at 23:34.
    Principal developer of Lianja, Recital and other products

    Follow me on:

    Twitter: http://twitter.com/lianjaInc
    Facebook: http://www.facebook.com/LianjaInc
    LinkedIn: http://www.linkedin.com/in/barrymavin

  2. #2
    Senior Member
    Join Date
    Oct 2012
    Posts
    130
    this is great! special thanks for the cursoradaptor.translatequery () method

  3. #3
    Lianja Development Team barrymavin's Avatar
    Join Date
    Feb 2012
    Location
    UK, USA, Thailand
    Posts
    6,030
    In Lianja 5.6, To allow further translation of the requery( cExpression ) (from native Lianja to MSSQL, MySQL,PosgreSQL etc) I have added an additional property to VTs and the cursoradaptor class.

    As a property or assigning to a Cursor adaptor property:

    translatequeryfunc=yourcustomtranslator

    Your custom translator function is called to translate any queries specified with requery(). It is passed two arguments and should be a database procedure so that it works with all clients without any special installation (resides in the database). It is not called for the Lianja native database.

    // File: yourcustomtranslator.prg
    parameters wherecondition, target_dbtype
    // you can parse and alter the wherecondition here based on the target database type e.g. MSSQL, MYSQL, POSTGRESQL, ORACLE etc
    return wherecond
    Last edited by barrymavin; 2020-11-17 at 23:33.
    Principal developer of Lianja, Recital and other products

    Follow me on:

    Twitter: http://twitter.com/lianjaInc
    Facebook: http://www.facebook.com/LianjaInc
    LinkedIn: http://www.linkedin.com/in/barrymavin

  4. #4
    Lianja MVP
    Join Date
    Feb 2012
    Location
    Berea, KY, USA
    Posts
    2,029
    Ah yes, those pesky DDM idiosyncrasies. Great to have a way to work around them, thanks.

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Journey into the Cloud
Join us