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

Is this possible to implement? .jsp/database Query.

Options
  • 18-05-2011 5:35pm
    #1
    Registered Users Posts: 413 ✭✭


    So I want to add a database to my website called music.
    You will be able to search by Song/Artist.

    Recently for a college assignment we made a basic library website allowing us to search for books and reserve them.

    We used .mdb file for a database. We accessed it with our data source:
    <%--setupdata source --%>
    <sql:setDataSource
    var ="booksdb"
    scope = "session"
    driver = "sun.jdbc.odbc.JdbcOdbcDriver"
    url = "jdbc:odbc:Driver={Microsoft Access Driver (*.mdb)};
    DBQ=C:\apache-tomcat-6.0.32\webapps\myapps\assign\books.mdb"/>


    We carried out queries such as:
    <%--sql query that will select all the fields within the Categories table and display them in order by the column categoryID --%>
    <sql:query var="checkCategory" scope="request" dataSource = "${booksdb}">
    SELECT * From Categories
    ORDER BY CategoryID
    </sql:query>
    <jsp:include page="header.jsp" flush="true"/>

    We used tomcat.

    So I'm just wondering if this will be possible:
    To implement the same method through filezilla for my website?
    So I would drag my .mdb database into my files on filezilla.
    I would have my 2-3 necessary pages on filezilla.

    I'm obviously going to have to adjust my datasource but not sure what to?
    Do I need to bring tomcat onto my Filezilla? I presume no, because I'm already hosting my website on a server, so I can just locate my data source to that?

    I currently have my website up and running with just a few htmls files..etc

    I'm with register 365, using Filezilla, is this possible to implement into my website as it is the only method I have learned with using databases and I want users to be able to search song/artists.

    Thanks ;)


Comments

  • Registered Users Posts: 413 ✭✭i124Q


    www.djbarcoe.com/query.jsp

    Why is this just giving me my jsp code and not displaying a table with the results from the database?

    Thanks ;)


  • Closed Accounts Posts: 10 Skiex


    Doesnt look like your running it through a java applet.

    You might want to look into that.

    What sort of server is hosting the site?

    Edit: Should read better.

    You need a java server. Looks like you have some a php server.


Advertisement