Bonjour à tous,
Dans le but de faire du reporting, je cherche le moyen de récupérer les différentes variables possibles dans la base. J'ai donc pensé à me connecter à la base postgresql de wapt afin d'explorer les différentes tables et trouver mon bonheur. J'ai suivi le tuto https://www.wapt.fr/en/doc-2.4/wapt-console-usage-advanced-reporting.html#co... pour configurer et autoriser la connexion à la base mais je ne doit pas avoir les bonnes informations de connexion je pense. J’essaie de me connecter comme ceci : host : mon serveur wapt database : wapt user id : wapt password : celui paramétré dans la dernière ligne du tuto
Quelqu'un pourrait-il m'aider svp ? Ou si vous avez d'autres solutions pour récupérer les différentes variables utilisables dans le reporting ?
Merci, Cordialement,
Bonjour Jérôme,
Personnellement, je me connecte à la base depuis le shell du serveur et j'ai récupéré les noms des colonnes pour les utiliser dans mes reports. su postgres psql \c wapt # sélection de la base \dt # liste toutes les tables \d+ <tablename> # liste les colonnes, que tu peux utiliser dans tes requêtes SQL ex: \d+ hosts
[image: image.png]
Après, beaucoup de data sont dans "dmi" ou "wmi" pour les hôtes par exemple, ça devient très vite complexe à utiliser quand on ne s'y connait pas beaucoup. Si ça peut t'aider, voici un exemple d'un rapport que j'ai fait qui compte les builds W10 et le langage:
*select host_info->'windows_version' as Build,* *os_name as OS,* *case wmi->'Win32_OperatingSystem'->'OSLanguage'*
- when '1031' then 'de-DE'*
- when '1033' then 'en-US'*
- when '1036' then 'fr-FR'*
- when '1038' then 'hu-HU'*
- when '1040' then 'it-IT'*
- when '1041' then 'ja-JP'*
- when '1046' then 'pt-BR'*
- when '1049' then 'ru-RU'*
- when '2052' then 'zh-CN'*
- when '2057' then 'en-GB'*
- when '2058' then 'es-MX'*
- when '3082' then 'es-ES'*
- else wmi->'Win32_OperatingSystem'->>'OSLanguage'*
*end as Lang,* *count(wmi->'Win32_OperatingSystem'->'OSLanguage')* *from hosts* *where CAST(host_info->'windows_version' AS CHAR) NOT ILIKE '10.0.19044' AND os_name iLIKE 'windows 10%%'**group by 1,2,3*
Tu retrouves le chemin à utiliser dans l'onglet "hardware inventory" quand tu sélectionnes un PC dans ton inventaire: [image: image.png]
Il y a peut-être mieux / plus simple mais ça m'a suffit :)
Best regards
Vincent NEANT IT Infrastructure Engineer *Minebea **A**ccessSolutions* Headquarter Office Location : Nevers, 4 quai de la jonction, 58000 Nevers, France Mobile : +33 6 26 43 00 89
On Tue, May 9, 2023 at 11:28 AM Jérôme DUPUIS via WAPT wapt@lists.wapt.fr wrote:
Bonjour à tous,
Dans le but de faire du reporting, je cherche le moyen de récupérer les différentes variables possibles dans la base. J'ai donc pensé à me connecter à la base postgresql de wapt afin d'explorer les différentes tables et trouver mon bonheur. J'ai suivi le tuto https://www.wapt.fr/en/doc-2.4/wapt-console-usage-advanced-reporting.html#co... pour configurer et autoriser la connexion à la base mais je ne doit pas avoir les bonnes informations de connexion je pense. J’essaie de me connecter comme ceci : host : mon serveur wapt database : wapt user id : wapt password : celui paramétré dans la dernière ligne du tuto
Quelqu'un pourrait-il m'aider svp ? Ou si vous avez d'autres solutions pour récupérer les différentes variables utilisables dans le reporting ?
Merci, Cordialement, -- *Jérôme DUPUIS* *TSH Informatique* *Centre Hospitalier d'Abbeville* 43 Rue de l'Isle, 80142 ABBEVILLE ✆*03 22 25 57 65 / 03 22 25 52 40* ✉dupuis.jerome@ch-abbeville.fr _______________________________________________ WAPT mailing list WAPT@lists.wapt.fr http://lists.wapt.fr/listinfo/wapt
Bonjour Jérôme,
Personnellement, j’ai trouvé mon bonheur avec ce lien https://www.wapt.fr/en/doc-2.4/_downloads/0282f7c80229f4962a16e92b2eb8a655/w... Il se trouve dans le lien que vous avez mis ; il est juste sous la vidéo : « The database structure diagram is available here wapt_db_data_structure.svghttps://www.wapt.fr/en/doc-2.4/_downloads/0282f7c80229f4962a16e92b2eb8a655/wapt_db_data_structure.svg. »
Vous avez aussi plusieurs exemples mis à disposition sur le forum et dans la documentation. Pour la partie JSON du WMI, DMI … vous pouvez retrouver les informations dans l’onglet inventaire matériel.
Bonne journée,
[cid:image001.png@01D6A634.11A0CF30]
Monsieur Cyril MICHARD Technicien, Section Micro & Hotline
Service Départemental d’Incendie et de Secours de Seine-et-Marne 56, avenue de Corbeil BP 70109 - 77001 Melun cedex michard@sdis77.frmailto:michard@sdis77.fr Fixe : 01 60 56 86 92
De : WAPT wapt-bounces@lists.wapt.fr De la part de Jérôme DUPUIS via WAPT Envoyé : mardi 9 mai 2023 11:28 À : David Matta via WAPT wapt@lists.wapt.fr Cc : Jérôme DUPUIS dupuis.jerome@ch-abbeville.fr Objet : [Wapt] Reporting Wapt
ATTENTION: Cette adresse email ne se termine pas "@sdis77.fr". NE CLIQUEZ PAS sur les liens ou les pièces jointes sans avoir contrôlé l'email et la réelle identité de cet expéditeur. Bonjour à tous,
Dans le but de faire du reporting, je cherche le moyen de récupérer les différentes variables possibles dans la base. J'ai donc pensé à me connecter à la base postgresql de wapt afin d'explorer les différentes tables et trouver mon bonheur. J'ai suivi le tuto https://www.wapt.fr/en/doc-2.4/wapt-console-usage-advanced-reporting.html#co... pour configurer et autoriser la connexion à la base mais je ne doit pas avoir les bonnes informations de connexion je pense. J’essaie de me connecter comme ceci : host : mon serveur wapt database : wapt user id : wapt password : celui paramétré dans la dernière ligne du tuto
Quelqu'un pourrait-il m'aider svp ? Ou si vous avez d'autres solutions pour récupérer les différentes variables utilisables dans le reporting ?
Merci, Cordialement, -- [cid:image002.jpg@01D9826B.46EED8B0]
Jérôme DUPUIS TSH Informatique Centre Hospitalier d'Abbeville 43 Rue de l'Isle, 80142 ABBEVILLE ✆03 22 25 57 65 / 03 22 25 52 40 ✉dupuis.jerome@ch-abbeville.frmailto:dupuis.jerome@ch-abbeville.fr
AVERTISSEMENT
Cette personne vous envoie un email depuis l'extérieur. Signalez tous les courriels suspect en suivant cette procédure sur l'intranet https://intra.sdis77.fr/upload/docs/application/pdf/2019-01/memo_hameconnage_sdis.pdf
Bonjour Cyril,
En effet, je n'avais pas vu le lien merci. Les commandes postgressql dans la réponse de Vincent m'ont beaucoup aidé également.
Merci à vous pour vos retour rapide. Bonne journée, *Jérôme DUPUIS* /TSH Informatique/ *Centre Hospitalier d'Abbeville* 43 Rue de l'Isle, 80142 ABBEVILLE ✆*03 22 25 57 65 / 03 22 25 52 40* ✉dupuis.jerome@ch-abbeville.fr
Le 09/05/2023 à 11:48, Michard Cyril via WAPT a écrit :
Bonjour Jérôme,
Personnellement, j’ai trouvé mon bonheur avec ce lien https://www.wapt.fr/en/doc-2.4/_downloads/0282f7c80229f4962a16e92b2eb8a655/w...
Il se trouve dans le lien que vous avez mis ; il est juste sous la vidéo : « The database structure diagram is available here wapt_db_data_structure.svg https://www.wapt.fr/en/doc-2.4/_downloads/0282f7c80229f4962a16e92b2eb8a655/wapt_db_data_structure.svg. »
Vous avez aussi plusieurs exemples mis à disposition sur le forum et dans la documentation.
Pour la partie JSON du WMI, DMI … vous pouvez retrouver les informations dans l’onglet /inventaire matériel/.
Bonne journée,
cid:image001.png@01D6A634.11A0CF30
*Monsieur Cyril MICHARD*
Technicien, Section Micro & Hotline
*Service Départemental d’Incendie et de Secours de Seine-et-Marne*
56, avenue de Corbeil
BP 70109 - 77001 Melun cedex
michard@sdis77.fr
Fixe : 01 60 56 86 92
*De :*WAPT wapt-bounces@lists.wapt.fr *De la part de* Jérôme DUPUIS via WAPT *Envoyé :* mardi 9 mai 2023 11:28 *À :* David Matta via WAPT wapt@lists.wapt.fr *Cc :* Jérôme DUPUIS dupuis.jerome@ch-abbeville.fr *Objet :* [Wapt] Reporting Wapt
ATTENTION:Cette adresse email ne se termine pas "@sdis77.fr". *NE CLIQUEZ PAS* sur les liens ou les pièces jointes sans avoir contrôlé l'email et la réelle identité de cet expéditeur.
Bonjour à tous,
Dans le but de faire du reporting, je cherche le moyen de récupérer les différentes variables possibles dans la base. J'ai donc pensé à me connecter à la base postgresql de wapt afin d'explorer les différentes tables et trouver mon bonheur. J'ai suivi le tuto https://www.wapt.fr/en/doc-2.4/wapt-console-usage-advanced-reporting.html#co... pour configurer et autoriser la connexion à la base mais je ne doit pas avoir les bonnes informations de connexion je pense. J’essaie de me connecter comme ceci : host : mon serveur wapt database : wapt user id : wapt password : celui paramétré dans la dernière ligne du tuto
Quelqu'un pourrait-il m'aider svp ? Ou si vous avez d'autres solutions pour récupérer les différentes variables utilisables dans le reporting ?
Merci, Cordialement,
--
*Jérôme DUPUIS*
/TSH Informatique/
*Centre Hospitalier d'Abbeville*
43 Rue de l'Isle, 80142 ABBEVILLE
✆*03 22 25 57 65 / 03 22 25 52 40*
✉dupuis.jerome@ch-abbeville.fr mailto:dupuis.jerome@ch-abbeville.fr
*AVERTISSEMENT*
Cette personne vous envoie un email depuis l'extérieur. Signalez tous les courriels suspect en suivant cette procédure sur l'intranet https://intra.sdis77.fr/upload/docs/application/pdf/2019-01/memo_hameconnage_sdis.pdf
WAPT mailing list WAPT@lists.wapt.fr http://lists.wapt.fr/listinfo/wapt
Bonjour, Tu peux aussi créer un user psql qui aura les droits de lecture sur la base. Ensuite, par exemple avec Dbeaver, par tunnel ssh tu peux avoir un accès graphique qui peut aider à faire des tests plus fin.
Le 09/05/2023 à 11:28, Jérôme DUPUIS via WAPT a écrit :
Bonjour à tous,
Dans le but de faire du reporting, je cherche le moyen de récupérer les différentes variables possibles dans la base. J'ai donc pensé à me connecter à la base postgresql de wapt afin d'explorer les différentes tables et trouver mon bonheur. J'ai suivi le tuto https://www.wapt.fr/en/doc-2.4/wapt-console-usage-advanced-reporting.html#co... pour configurer et autoriser la connexion à la base mais je ne doit pas avoir les bonnes informations de connexion je pense. J’essaie de me connecter comme ceci : host : mon serveur wapt database : wapt user id : wapt password : celui paramétré dans la dernière ligne du tuto
Quelqu'un pourrait-il m'aider svp ? Ou si vous avez d'autres solutions pour récupérer les différentes variables utilisables dans le reporting ?
Merci, Cordialement, --
*Jérôme DUPUIS* /TSH Informatique/ *Centre Hospitalier d'Abbeville* 43 Rue de l'Isle, 80142 ABBEVILLE ✆*03 22 25 57 65 / 03 22 25 52 40* ✉dupuis.jerome@ch-abbeville.fr
WAPT mailing list WAPT@lists.wapt.fr http://lists.wapt.fr/listinfo/wapt