Results 1 to 5 of 5
  1. #1
    Join Date
    Jun 2004
    Posts
    9

    Unanswered: How can I see all online users by using embedded SQL commands?

    Hi everybody,
    I want to see all online users bt using embedded MySQL command in my application? That's allright "SHOW PROCESSLIST" line give fine results at my MySQL manager's SQL commands window. But how can i achieve that by using embedded SQL in my program? I looked all the tables if some of them changes when logged on to the my DB by using several logins. But I could not see anything related with that problem..It seems that all tables stay same..It seems MySQL cannot recognize new logged on user except "SHOW PROCESSLIST" command. But I could not use that command as a embedded SQL Query . What should I do? Thanks
    Inanc

  2. #2
    Join Date
    Jul 2004
    Location
    Dundee, Scotland
    Posts
    107
    execute the SQL query "SHOW PROCESSLIST;"

    A table with the following fields is returned:
    Id, User, Host, db, Command, Time, State, Info

    I assume the Id, User, and Host fields will enable you to solve the problem. note that the mysql table that this information is/might by stored in is not made available to us (it must be a MySQL internal thing).

  3. #3
    Join Date
    Jun 2004
    Posts
    9

    Table name is not "processlist"

    I was trying to get some information of online users by using "SHOW PROCESSLIST" according to your advice ..Yes, you can get all information about online ones by using that command...It is OK...MySQL server feels comfortable with the command "SHOW PROCESSLIST"...but when i say ;

    SELECT * FROM PROCESSLIST

    It says there is no table with a name PROCESSLIST...so I wonder what is the name of that table including online users information...I think that point has a weak explanation in MySQL manual...thanks..

    Regards

  4. #4
    Join Date
    Jun 2004
    Posts
    9

    I could not find a solution for that problem yet

    I could not find a solution for that problem yet

  5. #5
    Join Date
    Jun 2004
    Posts
    9

    Is it Imposible?

    Is it imposible?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •