# User telemetry and Performance Data

**URL:** <https://forum.communityhealthtoolkit.org/t/user-telemetry-and-performance-data/2359>\
**Category:** Technical Support\
**Created:** [December 20, 2022, 2:56pm UTC](https://forum.communityhealthtoolkit.org/t/user-telemetry-and-performance-data/2359 "2022-12-20T14:56:37Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![michael](https://communityhealthtoolkit.b-cdn.net/user_avatar/forum.communityhealthtoolkit.org/michael/32/319_2.png) [@michael](https://forum.communityhealthtoolkit.org/u/michael)\
**Post date:** [December 20, 2022, 4:58pm UTC](https://forum.communityhealthtoolkit.org/t/user-telemetry-and-performance-data/2359/3 "2022-12-20T16:58:37Z")

</div>

…and if you do end up deciding to use `couch2pg` and want to explore using SQL, here’s a sample statement to get you started. `couch2pg` will put data from CouchDB’s `medic-users-meta` DB into a table called `couchdb_users_meta` in PostgreSQL.

```auto
SELECT 
	doc#>>'{metadata,user}' AS t_user,
	doc#>>'{metadata,versions,app}' AS t_app_version,
	doc#>>'{metadata,year}' AS t_year,
	lpad(doc#>>'{metadata,month}',2,'0') AS t_month,
	lpad(doc#>>'{metadata,day}',2,'0') AS t_day,		
    jsonb_pretty(doc) AS obj_key

FROM 
    couchdb_users_meta
    
WHERE
	doc->>'type'='telemetry'
	AND doc#>>'{metadata,year}' = '2022'

LIMIT 100
;
```

---

_[View the full topic](https://forum.communityhealthtoolkit.org/t/user-telemetry-and-performance-data/2359)._
