A
Alexandre Jaquet
Hi,
I can't understand why I got different result
with the same sql query.
My code :
sub getComboBox {
my $name = shift || '';
my $htmlbuffer = '';
my @members = ();
my $group = ();
(@members) = sqlSelect("clientlevel","user","userID=userID AND
clientlevel <> ''");
$htmlbuffer = "<select name=\"$name\" style=\"width: 100%\"
class=\"editionFld\" \">\n";
foreach $group(@members) {
$htmlbuffer.= "<option value=\"$group\" selected>$group</option>\n";
}
return $htmlbuffer .= "</select>\n";
}
I got only one result and when I execute the query with the console :
select clientlevel from user where userID=userID and clientlevel <> ''
I got 4 items
I can't understand why I got different result
with the same sql query.
My code :
sub getComboBox {
my $name = shift || '';
my $htmlbuffer = '';
my @members = ();
my $group = ();
(@members) = sqlSelect("clientlevel","user","userID=userID AND
clientlevel <> ''");
$htmlbuffer = "<select name=\"$name\" style=\"width: 100%\"
class=\"editionFld\" \">\n";
foreach $group(@members) {
$htmlbuffer.= "<option value=\"$group\" selected>$group</option>\n";
}
return $htmlbuffer .= "</select>\n";
}
I got only one result and when I execute the query with the console :
select clientlevel from user where userID=userID and clientlevel <> ''
I got 4 items