Okay
  Public Ticket #3358083
Can not us
Closed

Comments

  • Steve started the conversation

    I have a table set up that works properly till I add a where clause, here is the data source with where clause

    SELECT view_talent_income.`post_date`,
           view_talent_income.`month`,
           view_talent_income.`year`,
           view_talent_income.`post_author`,
           view_talent_income.`amount_owed`,
           view_talent_income.`amount_paid`
    FROM view_talent_income
    WHERE post_author = %CURRENT_USER_ID%

    Problem is when I try and save the table with the where clause I get an error saying "No data fetched!" which is what I expect since as the administrator I will not have any data to show.  The error prevents the table from being saved which is a major problem for me.

    I do not see why you would treat "No data fetched" as an error, particularly since it prevents saving the table. This will not be the only table I need to filter by current user where as the admin I have not data.


    Thanks

  • Steve replied

    Never mind, I figured out I can set a default for %CURRENT_USER_ID% that works

  •  1,708
    Miloš replied

    Hi, Steve.

    I am delighted to hear that this has been resolved. Thank you for letting us know. Anything else that we could assist with, please don't hesitate to create new tickets.

    Have a great day!smile.png

    Kind Regards, 

    Miloš Jovanović
    [email protected]

    Rate my support

    wpDataTables: FAQ | Facebook | Twitter | InstagramFront-end and back-end demo | Docs

    Amelia: FAQ | Facebook | Twitter | InstagramAmelia demo sites | Docs | Discord Community

    You can try wpDataTables add-ons before purchasing on these sandbox sites:

    Powerful Filters | Gravity Forms Integration for wpDataTables | Formidable Forms Integration for wpDataTables | Master-Detail Tables