Seeking MySQL/Java Developer for Central storage API

Discussion in 'WIP and Development Status' started by Kainzo, Jun 14, 2013.

Thread Status:
Not open for further replies.
  1. Offline

    Kainzo

    Looking for someone to assist in creating a central storage location for all Hero* plugins.

    If you're interested in assist in framework and structure creation and specialize in MySQL please let me know!

    You can find our team @ esper.net /join #Heroes

    Have a good one!
     
  2. Offline

    ogedi

    • Inappropriate
    kainzo es newb.
     
  3. Offline

    CraftingRealm

    MySQL is very easy. I made a small class which I always use to connect to sql when I use it. Download it at my site http://craftingrealm.com/plugins/SQL.java Just edit the IP, Username, Password and Database Name in the class and add it to your plugin. To use it just create a new SQL (SQL sql = new SQL()) and then use one of 2 methods. sql.voidQuery(String) is for sending queries which don't return anything (usually for data editing). sql.sendQuery(String) returns a ResultSet imported from java.sql.ResultSet which works much like a List or Set. If you don't know anything about how to write queries, look up MySQL tutorials and I'm sure you'll find something useful.

    Oh and there's a free very useful program I use to test and create queries called HeidiSQL. Download it and connect to your database. Then you can edit data with a gui and it will show what queries it is sending. Just copy these and edit them for your code!

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jun 2, 2016
  4. Offline

    Kainzo

    Strange....
    Server Error
    404 - File or directory not found.

    The resource you are looking for might have been removed, had its name changed, or is temporarily unavailable.
     
  5. Offline

    CraftingRealm

    This is a web error. Where are you trying to use the class? It's for your java program or plugin not for web. If you're trying to connect to the sql using the web, you need to use PHP. First make sure you have PHP installed on your web server, or if you bought hosting make sure they run PHP. Then create your php file (index.php) and add the following code wherever you want something from SQL to be displayed.
    PHP:
    <?php
    $connection 
    = new mysqli("IP HERE""USERNAME HERE""PASSWORD""DATABASE NAME");
    $sql "ADD SQL QUERY HERE";
    $result mysqli_query($connection$sql);
    while (
    $var mysqli_fetch_array($result)) :
         
    //use $var in code. It is the next data returned from sql with each pass.
         
    echo "Put <b>whatever</b> you want to " $var "be displayed in page here. You can use markup.";
         
    // The . is concatenation
    endwhile;
    ?>
     
  6. Offline

    Ultimate_n00b

    He's trying to download it off your site, the link doesn't work.
     
  7. What about using the Persistance API?
    For me it works quite good and saves your the Trouble of writing SQL Queries.
    You have to work yourself into it a Little, but once you get the hang if it, it works quite well.
     
  8. Offline

    dark navi

    While I greatly enjoy the design and implementation of MySQL schema, I don't know if I would be on the level of Heros. If no one has applied yet, I'd be glad to give my take on the situation!
     
  9. Offline

    Wingzzz

    Once I have a go at testing my SQL api (MySQL/SQLite), if it's all good and dandy I could send it your way :)
     
  10. Offline

    Kainzo

    Sorry, been on a new job at work, we're still looking for assistance, it is quite in-depth ... we're still trying to sort out some of the fundamentals. :)
     
Thread Status:
Not open for further replies.

Share This Page