Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

MySQL port listener

  • 06-10-2008 2:54pm
    #1
    Closed Accounts Posts: 97 ✭✭


    Hi I'm new to mySQL,
    I want to monitor a port in mysql e.g.(port 3066) and insert whatever comes in, in to a table.
    Can i do this from the command prompt?
    any help would be great?
    Thanks


Comments

  • Registered Users, Registered Users 2 Posts: 2,013 ✭✭✭lynchie


    I don't follow?? MySQL already listens on port 3306. I suggest you read up on the tutorial on the MySQL website for info on inserting data from the command line. http://dev.mysql.com/doc/refman/5.1/en/tutorial.html


  • Closed Accounts Posts: 97 ✭✭kevin216


    I'll be sending information from a J2me socket program to a port.I would to automaticaly put this information in to a mySQL table.
    thanks


  • Registered Users, Registered Users 2 Posts: 2,013 ✭✭✭lynchie


    So Either use jdbc direct from j2me to put data into the DB. If the device is sending data remotely and you really want to use sockets, then just write an app that listens on a socket and then uses jdbc to insert data into a DB. Plenty of info on Sun's website about writing socket based applications.


  • Registered Users, Registered Users 2 Posts: 2,426 ✭✭✭ressem


    You haven't mentioned what program will be listening at that port number to the communications sent by your J2ME app, so I'm guessing that you do not have one in mind?

    The typical way of doing this is to create the server program that will accept the TCP connection from your j2me client, take out the relevant data and do the insert into Mysql using mysql's jdbc client libraries.

    If the j2me app is one that you have written for a student assignment or whatever then how does it communicate? Simple sockets and datastreams or something else?

    If it's a commercial j2me app that you are trying to work with then provide the name of it and someone might be able to provide more info on the essentials for the server, and whether it is necessary or possible to grab the data in a parseable form.


Advertisement