Categories > TinyButStrong general >

Querying with TBS

The forum is closed. Please use Stack Overflow for submitting new questions. Use tags: tinybutstrong , opentbs
By: timotei
Date: 2011-03-17
Time: 18:58

Querying with TBS

I seem to have an unusual response from a tbs query in Joomla 1.5

A select query asks for valid existing db info -  4 fields from table mytable using standard syntax that uses two references in the WHERE statement to locate the data.

{tbs}mergeblock=abc;sql=SELECT one, two, three, four FROM mytable WHERE category='999' AND place='9'{/tbs}

Everything works fine until I make a change to the query.

When the first field is removed (one) and replaced with a new field (five) from the table,
I get an error message from TBS looking for the original field (one) when I run the query.

I have checked for caching issues and page code for any old references and nothing seems
to fix this error message problem except placing the fieldname (one) back into the query.

Note also that all data is queried properly and displays on page either way. (both one and five fields exist in the table)

Even noerr option does not seem to operate when set as follows:

{tbs}mergeblock=abc;noerr;sql=SELECT one, two, three, four FROM mytable WHERE category='999' AND place='9'{/tbs}

This is the error message generated by tbs whenever field one is removed from the query:

TinyButStrong Error in field [inv.partno...] : item 'one' is not an existing key in the array. This message can be cancelled using parameter 'noerr'.

Can anyone help me understand this persistance?

Thanks much.




By: Skrol29
Date: 2011-03-17
Time: 21:17

Re: Querying with TBS

If your Joomla configuration uses Explicit URLs, then it may be the browser cache that does this persistence.
To check this, you can just had a "?x=123" in the URL and see if the page is refreshed.

By: timotei
Date: 2011-03-17
Time: 21:46

Re: Querying with TBS

Adding that does not seem to affect the browser at all.
Nor does it affect it on a different browser.

Thanks for your input.
By: Skrol29
Date: 2011-03-18
Time: 21:50

Re: Querying with TBS

I have no idea about this strange behavior.
Check the HTML source to see if there is a PHP error at the top.