View ProjeQtOr On SourceForge.net
ProjeQtOr - Project Management Tool
Supportez nous sur Capterra
OIN - Open Invention Network
ProjeQtOr free project management software - execute a request personalized - ProjeQtOr

Prochaines sessions de formation

Les prochaines formations et démonstrations sont ouvertes, inscrivez-vous rapidement !

 

Démonstration de ProjeQtOr

(gratuit, sur inscription)

Mardi 23 avril (10h30-12h)

Jeudi 16 mai (16h-17h30)

Jeudi 13 juin (10h30-12h)

 
 

Planifiez avec ProjeQtOr

3 et 4 avril (9h - 12h30)

 
 

Administrez avec ProjeQtOr

10 et 11 avril (9h - 12h30)

 

 

 
 

execute a request personalized

More
11 Déc 2012 17:34 #1 by yassine
i can't execute this request with sqlElement :dry:
SELECT count(distinct `idResource`,`workDate`)FROM `work` WHERE `week`=201248

Please Connexion or Create an account to join the conversation.

More
11 Déc 2012 18:12 #2 by babynus
Not really ANSI SQL compliant.
Try
select count(*) from 
(SELECT distinct `idResource`,`workDate` FROM `work` WHERE `week`=201247) as ww

Babynus
Administrator of ProjeQtOr web site

Please Connexion or Create an account to join the conversation.

More
11 Déc 2012 18:16 #3 by yassine
this is my code

$Ressource=SqlList::getList('Resource');
foreach($Ressource as $keyresource => $valresource)
{
$crit=array('week'=>$y.''.$week);
$obj=new Work();
$Jours=$obj->countSqlElementsFromCriteria($crit);
}

Please Connexion or Create an account to join the conversation.

More
11 Déc 2012 19:26 #4 by yassine
So i should modify the file sqlElement.php.
But i try this way w and i can't create a new function to generate a request to reply this need.

Please Connexion or Create an account to join the conversation.

More
11 Déc 2012 20:31 #5 by babynus
Sure this code
$Ressource=SqlList::getList('Resource');
foreach($Ressource as $keyresource => $valresource) 
{ 
$crit=array('week'=>$y.''.$week);
$obj=new Work();
$Jours=$obj->countSqlElementsFromCriteria($crit);
}
will not generate
SELECT count(distinct `idResource`,`workDate`)FROM `work` WHERE `week`=201248
unless you changed SqlElement code (I stongly recommand against this !).
It will more likely generate
select count(*) as cpt from work where week='201248'

Babynus
Administrator of ProjeQtOr web site

Please Connexion or Create an account to join the conversation.

More
11 Déc 2012 20:34 #6 by babynus
Maybe if you describe what you try to get (and not how you try to get it), answers may be more helpfull. ;)

Babynus
Administrator of ProjeQtOr web site

Please Connexion or Create an account to join the conversation.

Moderators: babynusprotion
Time to create page: 0.032 seconds

Paramétrages de cookies

×

Cookies fonctionnels

Ce site utilise des cookies pour assurer son bon fonctionnement et ne peuvent pas être désactivés de nos systèmes. Nous ne les utilisons pas à des fins publicitaires. Si ces cookies sont bloqués, certaines parties du site ne pourront pas fonctionner.

Session

Veuillez vous connecter pour voir vos activités!

Autres cookies

Ce site web utilise un certain nombre de cookies pour gérer, par exemple, les sessions utilisateurs.