Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
    T. B.
    @number005_twitter
    ah thanks! its just a param in the table! thanks!
    Emad Fani
    @EmadFani
    Hi
    i'm trying to make a fast connection to jsstore
    in my case i dont have the database schema
    but the database already exists
    so i need to connect to it and make a transaction
    let isExists = await connection.isDbExist('db')
    if (isExists) {
    return connection;
    }
    is it ok ?
    Ujjwal Gupta
    @ujjwalguptaofficial
    Hi - there is no concept of fast or slow connection . You have already established connection when you have created connection variable.
    Emad Fani
    @EmadFani
    @ujjwalguptaofficial thanks , i guess i didn't ask the right question but it was already solved thanks
    richard rose
    @manEatingFish_twitter
    Hi could any one help me with a query;
    from: "Entity"
    order: {by: "name", type: "asc"}
    where:
    status: { I want this to be a NOT LIKE : "Complete"}
    Ujjwal Gupta
    @ujjwalguptaofficial
    Hi @manEatingFish_twitter
    Do you mean not equal to or not like "%complete%" ?
    richard rose
    @manEatingFish_twitter
    not like "%complete%" please
    so return everything whoose status isn't complete
    there could be many stuses, complete is the only constant
    Ujjwal Gupta
    @ujjwalguptaofficial
    In that case - operators will work. Check out this : https://jsstore.net/tutorial/operators/
    richard rose
    @manEatingFish_twitter
    i tried != and it doesn't work, when I look at the query it tuned the != into a < so it only returned statuses alphabetically lower than Complete i.e Abandoned
    Ujjwal Gupta
    @ujjwalguptaofficial
    ok i see
    allow me some time, let me look into this.
    richard rose
    @manEatingFish_twitter
    Thanks. some more context
    $scope.searchQuery.where.status = {'!=': "Complete"};
    yielded
    Ujjwal Gupta
    @ujjwalguptaofficial
    In the mean time - could you add an issue on jsstore github page ? so that others people can look into it & take advantage of our conversation.
    richard rose
    @manEatingFish_twitter
    from: "Entity"
    skip: 0
    limit: 100
    order: {by: "name", type: "asc"}
    where:
    status: {<: "Complete"}
    will do
    Ujjwal Gupta
    @ujjwalguptaofficial
    I guess - you can use regex for this. https://jsstore.net/tutorial/regex/
    richard rose
    @manEatingFish_twitter
    Thanks I will try that
    richard rose
    @manEatingFish_twitter
    status: {regex: /^((?!Complete).)*$/s} worked
    Ujjwal Gupta
    @ujjwalguptaofficial
    glad to know :).
    richard rose
    @manEatingFish_twitter
    Question about limit, skip and where.
    I have this query running against 3000 entries
    from: "Entity"
    skip: 0
    limit: 100
    order:
    by: "name"
    type: "asc"
    on scroll i load the next 100 entries by altering the skip
    this all works correctly and they are sorted alphabetically, however when I add a where clause;
    from: "Entity"
    skip: 0
    limit: 100
    order: {by: "name", type: "asc", idbSorting: true}
    where:
    searchterm: {like: "%and%"}
    each group of 100 results is only sorted within its self
    it appears that the 100 limit based on the skip is take from an unordered result from the where, and then subsequently ordered within its self
    richard rose
    @manEatingFish_twitter
    Is this correct behaviour fro IndexedDB? if so is there anything I can do to make the the where and order occur before the skip and limit is applied?
    Let me know if you can regenerate.
    akhilponnala
    @akhilponnala
    Hi guys,
    How can we use union.
    Ujjwal Gupta
    @ujjwalguptaofficial

    Hi @akhilponnala

    right now, jsstore doesn't support union. Please add an issue on jsstore github page.

    Thanks.

    akhilponnala
    @akhilponnala
    Hi @ujjwalguptaofficial
    Please help me in preparing alternate query to union.
    Thanks.
    Ujjwal Gupta
    @ujjwalguptaofficial
    ok sure, looking into this.
    Ujjwal Gupta
    @ujjwalguptaofficial
    @akhilponnala - added the union api. Have a look at - https://jsstore.net/tutorial/union/
    akhilponnala
    @akhilponnala
    Hi @ujjwalguptaofficial
    Thank you for your support.
    akhilponnala
    @akhilponnala
    Hi @ujjwalguptaofficial ,
    How can we implement MYSQL CASE function using jsstore.
    for example:
    SELECT CustomerName, City, Country
    FROM Customers
    ORDER BY
    (CASE
    WHEN City IS NULL THEN Country
    ELSE City
    END);
    Please suggest us on above if there is any altenative method using jsstore
    Hi @ujjwalguptaofficial ,
    please suggest on specifying the default values using jsstore in table creation
    Ujjwal Gupta
    @ujjwalguptaofficial

    Hi

    Jsstore doesn't have this functionality yet. Please add an issue on github. I will take it from there. Thanks.

    akhilponnala
    @akhilponnala
    Hi @ujjwalguptaofficial ,
    Thank you.
    I have added issue on github. Please help us on implementing above.
    Thank you.