trying to do a simple filter but my lack of knowledge of PHP & Mysql is getting me in a jam.
I have 2 tables:
MyMainTable = which has all individual records for different people
and
Users = the security table that also has a "Cities" field with single quote-comma delimited city names.
What I need to do is to filter the MyMainTable to only display authorized cities records from the "Users" table.
The server event I have going on right now is:
Code:
// Recordset Selecting event
function Recordset_Selecting(&$filter) {
ew_AddFilter($filter, "`MyMainTable`.`City` IN (" . CurrentUserInfo("Cities") . ")");
}
The killer of the whole thing is that I had this running the other night and thought I backed up what I did to "Code Repository" but goofed. I know the server event above has an error. I may have added "Users" before or in CurrentUserInfo("Cities") . ")"); somewhere but I forget exactly what I did.
Errors I am getting are:
Code:
Failed to execute SQL: SELECT * FROM `MyMainTable` WHERE `MyMainTable`.`City` IN () LIMIT 20 OFFSET 0. Error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') LIMIT 20 OFFSET 0' at line 1
No records found
(mysqlt): SET NAMES 'utf8'
Error (0):
(mysqlt): SELECT COUNT(*) FROM `MyMainTable` WHERE `MyMainTable`.`City` IN ()
Error (1064): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1
(mysqlt): SELECT * FROM `MyMainTable` WHERE `MyMainTable`.`City` IN ()
Error (1064): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1
(mysqlt): SELECT * FROM `MyMainTable` WHERE `MyMainTable`.`City` IN () LIMIT 20 OFFSET 0
Error (1064): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ') LIMIT 20 OFFSET 0' at line 1
Hi Experts,
I have csv file with 30, 40 columns
Pasting just 2 column for problem description.
Need to print error if below combination is not present in file
check for column-1 (DocumentNumber) and filter columns where value in DocumentNumber field is same.
For all such rows, the field... (7 Replies)
Hello,
What I wish to succeed is to setup loadbalancing between two dedicated servers. Here is my case:
=======================================================================================================
LB IP (Just an IP address): Provided by hosting company (11.22.33.44) Hosting company... (1 Reply)
Hi,
On my Java webpage which invokes the shell script has two checkboxes viz ...
apache
and
weblogic
apache require one parameter i.e apache home from the user while Weblogic requires three or five params from the user vi.z weblogic_home or <jdk_home, config_home & pid>, username and... (4 Replies)
Dear All,
I am capturing system date and creating the file by using that time stamp, file is getting appended with checks of application & database check logs.
But when the date is in between 1 to 9 both inclusive, it appends a single space to file name but after 9th it works fine.
... (5 Replies)
Hello All,
I am stuck with the follwing problem , pls give me some advice..
Input file:
input clock;
input reset; \\reset all
input yuv;
//input comment
output sur;
output sud;
output vtua;
output tur;
input ebi;
//output comment
The input file... (1 Reply)
Ok, since i am scripting first-timer i want to apology in advance if any of my ideas are way off.
What i am trying to achieve is a script that can listen for alerts from snort. When snort triggers an alert then i want my script to do nothing for X seconds, and after that period of time i want... (3 Replies)