Home News Contact Us Forum About Us Demos Products F.A.Q.
Shopping Cart
You currently have 0 items in your cart.


Recent Events
  • 31/12/2023 New Year SALE

    We are glad to announce New Year SALE. 25% discount for all our extensions. Use NY24 coupon code. Hurry up the discount is valid till 7 January.

  • 21/11/2023 BLACK FRIDAY 23 is coming

    BIG SALE, 35% discount for all our extensions. Use BF23 coupon code. Hurry up the discount is valid till 27 November.


2Checkout.com, Inc. is an authorized retailer of goods and services provided by ARI Soft. 2CheckOut




Follow us on twitter



Welcome, Guest
Please Login or Register.    Lost Password?

Strange Problem Returning Specific MySQL Results
(1 viewing) (1) Guest
Go to bottomPage: 12
TOPIC: Strange Problem Returning Specific MySQL Results
#53660
Strange Problem Returning Specific MySQL Results 9 Years, 1 Month ago Karma: 0
Hi,

I am asking this to see if there is an obvious reason as to why I am seeing a specific problem when using ARI Data Tables. I am using it to return tables from my online database and all is working just fine, except for one very specific issue that only just now have I seen. It relates to a very specific record entry.

I have a MySQL database table with over 2500 total records and some 30-40 fields per record. In one of the fields I am storing an organization name identifier that is later used to query and search the data. One specific entry is for "TRU S+T" which is the unique abbreviated identifier used to identify the full company name of "TRU Simulation+Training".

When I do any search or try and pull any data on "TRU S+T" using ARI Data Tables the results come back empty. It is like there is some error in the field value being searched. I have confirmed that the entries are stored in the database exactly how they are being searched which is "TRU S+T". Plus, all other searches and reports using the same articles, pages and code works perfectly for all other field values (eg. "CAE", "FSI", etc.) Only "TRU S+T" causes a problem.

The only thing different in this field value is the use of the "+" symbol. Is there a limitation I am not currently aware of? Any ideas or thoughts are welcome.

Ken
The administrator has disabled public write access.
 
#53661
Re:Strange Problem Returning Specific MySQL Results 9 Years, 1 Month ago Karma: 747
Hello,

Could you send screenshot(s) of module settings page by email?

Regards,
ARI Soft
The administrator has disabled public write access.
 
#53673
Re:Strange Problem Returning Specific MySQL Results 9 Years, 1 Month ago Karma: 0
To see the problem go to this page on my site,

sim-x.net/index.php/simulators-region.html

Near the bottom there is a field called "Simulator Maker". Pick any one other than "TRU Simulation+Training" and see how the page returns the database results using ARI DataTables module. However, not when "TRU Simulation+Training" is selected.

This is what the query is set to inside ARI module,

SELECT
LocRegion as Region,
COUNT(DISTINCT uSimID) AS Count
FROM Simulators
WHERE
MarkForDeletion <> "1"
AND
({$REQUEST:vOrganization|empty:""} = '' OR Organization LIKE CONCAT('%',{$REQUEST:vOrganization|empty:""},'%'))
AND
({$REQUEST:vEngMaker|empty:""} = '' OR EngMaker LIKE CONCAT({$REQUEST:vEngMaker|empty:""},'%'))
AND
({$REQUEST:vSimType|empty:""} = '' OR SimType LIKE CONCAT('%',{$REQUEST:vSimType|empty:""},'%'))
AND
({$REQUEST:vACFamily|empty:""} = '' OR ACFamily LIKE CONCAT('%',{$REQUEST:vACFamily|empty:""},'%'))
AND
({$REQUEST:vACType|empty:""} = '' OR ACType LIKE CONCAT('%',{$REQUEST:vACType|empty:""},'%'))
AND
({$REQUEST:vYear|empty:""} = '' OR InServiceDate LIKE CONCAT('%',{$REQUEST:vYear|empty:""},'%'))
AND
({$REQUEST:vFMSMaker|empty:""} = '' OR FMSMaker LIKE CONCAT({$REQUEST:vFMSMaker|empty:""},'%'))
AND
({$REQUEST:vSimMaker|empty:""} = '' OR SimMaker LIKE CONCAT({$REQUEST:vSimMaker|empty:""},'%'))
AND
({$REQUEST:vVisMaker|empty:""} = '' OR VisMaker LIKE CONCAT({$REQUEST:vVisMaker|empty:""},'%'))
AND
({$REQUEST:vACMaker|empty:""} = '' OR ACMaker LIKE CONCAT({$REQUEST:vACMaker|empty:""},'%'))
AND ({$REQUEST:vACClass|empty:""} = '' OR ACClass LIKE CONCAT({$REQUEST:vACClass|empty:""},'%'))
AND
({$REQUEST:vQualLevel|empty:""} = '' OR QualLevel1 LIKE CONCAT('%',{$REQUEST:vQualLevel|
empty:""},'%') OR QualLevel2 LIKE CONCAT('%',{$REQUEST:vQualLevel|
empty:""},'%') OR QualLevel3 LIKE CONCAT('%',{$REQUEST:vQualLevel|
empty:""},'%'))
AND
({$REQUEST:vRegApprovals|empty:""} = '' OR Regulator1 LIKE CONCAT('%',{$REQUEST:vRegApprovals|empty:""},'%') OR Regulator2 LIKE CONCAT('%',{$REQUEST:vRegApprovals|empty:""},'%') OR Regulator3 LIKE CONCAT('%',{$REQUEST:vRegApprovals|empty:""},'%') OR Regulator4 LIKE CONCAT('%',{$REQUEST:vRegApprovals|empty:""},'%') OR Regulator5 LIKE CONCAT('%',{$REQUEST:vRegApprovals|empty:""},'%'))
GROUP BY
LocRegion
ORDER BY
Count DESC

The vSimMaker $REQUEST variable is the one for Simulator Maker.

Thanks.

Ken
The administrator has disabled public write access.
 
#53675
Re:Strange Problem Returning Specific MySQL Results 9 Years, 1 Month ago Karma: 747
Use %2B instead of +

Regards,
ARI Soft
The administrator has disabled public write access.
 
#53681
Re:Strange Problem Returning Specific MySQL Results 9 Years, 1 Month ago Karma: 0
Thank you very much, but I cannot use that instead of the + sign. The + sign is stored in a field in the database and is read. It is simply stored in a text field like "TRU S+T". I can see from some other tests that when it comes back via the $REQUEST variable the field is "TRU S T" with the + sign seemingly replaced by a space.

I do not think this is an ARI DataTables issue. I suspect I will have to prevent the + sign from being used in text strings when stored in the database. Is the + character a restricted or special character? I was not aware it was.

Anyway, thanks.

Ken
The administrator has disabled public write access.
 
#53682
Re:Strange Problem Returning Specific MySQL Results 9 Years, 1 Month ago Karma: 747
It doesn't require to use it in a database. Use it in filter drop-down.

Regards,
ARI Soft
The administrator has disabled public write access.
 
Go to topPage: 12