# Where to find User ID information

**URL:** https://meta.discourse.org/t/where-to-find-user-id-information/61701
**Category:** Development
**Created:** [April 27, 2017, 6:11am UTC](https://meta.discourse.org/t/where-to-find-user-id-information/61701 "2017-04-27T06:11:28Z")
**Posts on this page:** 10
**Page:** 1

<div class="post-metadata">

### Author: ![Ranga\_TA](https://avatars.discourse-cdn.com/v4/letter/r/ecae2f/32.png) [@Ranga\_TA](https://meta.discourse.org/u/Ranga_TA)
#### Post date: [April 27, 2017, 6:11am UTC](https://meta.discourse.org/t/where-to-find-user-id-information/61701/1 "2017-04-27T06:11:28Z")

</div>

Hi

How to do we extract the username and user ID information for all the users

Thanks  
Ranga

---

<div class="post-metadata">

### Author: ![vinothkannans](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vinothkannans/32/86465_2.png) [@vinothkannans](https://meta.discourse.org/u/vinothkannans)
#### Post date: [April 27, 2017, 6:19am UTC](https://meta.discourse.org/t/where-to-find-user-id-information/61701/2 "2017-04-27T06:19:11Z")

</div>

Go to the admin page of th user. There you can have user id in page url.

```plaintext
/admin/users/:user_id/:username

```

---

<div class="post-metadata">

### Author: ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)
#### Post date: [April 27, 2017, 11:22am UTC](https://meta.discourse.org/t/where-to-find-user-id-information/61701/3 "2017-04-27T11:22:00Z")

</div>

I think that you night want the [data explorer](https://meta.discourse.org/t/32566?silent=true) plugin. It’ll let you do queries and download csv files.

---

<div class="post-metadata">

### Author: ![Ranga\_TA](https://avatars.discourse-cdn.com/v4/letter/r/ecae2f/32.png) [@Ranga\_TA](https://meta.discourse.org/u/Ranga_TA)
#### Post date: [April 27, 2017, 11:41am UTC](https://meta.discourse.org/t/where-to-find-user-id-information/61701/4 "2017-04-27T11:41:23Z")

</div>

> [@pfaffman](#):
>
> explorer

[Data Explorer](https://meta.discourse.org/t/32566?silent=true) Plugin is enabled, how do we download event or User ID information. Or SSO information from the User details?

Thanks  
Ranga

---

<div class="post-metadata">

### Author: ![jomaxro](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jomaxro/32/126216_2.png) [@jomaxro](https://meta.discourse.org/u/jomaxro)
#### Post date: [April 27, 2017, 1:50pm UTC](https://meta.discourse.org/t/where-to-find-user-id-information/61701/5 "2017-04-27T13:50:53Z")

</div>

> [@Ranga\_TA](#):
>
> how do we download event or User ID information. Or SSO information from the User details?

You need to write an SQL query for the information you want. To get the user id for all users, enter the following query:

```plaintext
SELECT users.username, users.id
FROM users
ORDER BY id

```

That will sort by user id. If you want to sort by username, replace `ORDER BY id` with `ORDER BY username`.

---

<div class="post-metadata">

### Author: ![Ranga\_TA](https://avatars.discourse-cdn.com/v4/letter/r/ecae2f/32.png) [@Ranga\_TA](https://meta.discourse.org/u/Ranga_TA)
#### Post date: [April 27, 2017, 2:08pm UTC](https://meta.discourse.org/t/where-to-find-user-id-information/61701/6 "2017-04-27T14:08:49Z")

</div>

Hi Joshua

How do we find the database connectivity information for the discourse

Thanks  
Ranga

---

<div class="post-metadata">

### Author: ![jomaxro](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jomaxro/32/126216_2.png) [@jomaxro](https://meta.discourse.org/u/jomaxro)
#### Post date: [April 27, 2017, 2:09pm UTC](https://meta.discourse.org/t/where-to-find-user-id-information/61701/7 "2017-04-27T14:09:51Z")

</div>

I’m sorry, I’m not sure what you’re asking…

---

<div class="post-metadata">

### Author: ![Ranga\_TA](https://avatars.discourse-cdn.com/v4/letter/r/ecae2f/32.png) [@Ranga\_TA](https://meta.discourse.org/u/Ranga_TA)
#### Post date: [April 27, 2017, 2:57pm UTC](https://meta.discourse.org/t/where-to-find-user-id-information/61701/8 "2017-04-27T14:57:33Z")

</div>

How can we query to discourse database

---

<div class="post-metadata">

### Author: ![eviltrout](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/eviltrout/32/5275_2.png) [@eviltrout](https://meta.discourse.org/u/eviltrout)
#### Post date: [April 27, 2017, 3:04pm UTC](https://meta.discourse.org/t/where-to-find-user-id-information/61701/9 "2017-04-27T15:04:37Z")

</div>

You’ve been told how to use [Data Explorer](https://meta.discourse.org/t/32566?silent=true) to query the database, but you keep asking the same question over and over and posted a second topic about it. It is frustrating for our community members to help you out and have their advice be ignored.

Please take the time [to read the data explorer](https://meta.discourse.org/t/data-explorer-plugin/32566) topic.

---

<div class="post-metadata">

### Author: ![eviltrout](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/eviltrout/32/5275_2.png) [@eviltrout](https://meta.discourse.org/u/eviltrout)
#### Post date: [April 27, 2017, 3:04pm UTC](https://meta.discourse.org/t/where-to-find-user-id-information/61701/10 "2017-04-27T15:04:41Z")

</div>


