Step by step to set up tomcat with mysql

hi i'm new to these things, well i went through the forum , there are load of info but no1 has explain how to set up (step by step) tomcat with mysql using jdbc driver ( also i'll use jsp pages to get info from the database.)
thx alot.

Hiya,
Best way would be to read the README.doc that you get after the installation on the sysetm. Becuase this provided you with the exact info. pertianing to the sysetm etc that you have and also visit this website:
http://www.experts-exchange.com/Programming/Programming_Languages/Java/Q_20148108.html
It gives u a step by step guide to set-up and some sample codes also to test etc.
Happy Javaing, Cheers

Similar Messages

  • How use Tomcat with MySQL

    Can anybody suggest me as how to use Tomcat with MySQL server.
    Thanks in advance.
    Khiz_eng

    add the classpath to the JDBC-driver to the tomcat-
    environment (I did it in tomcat.sh)
    Then put your code accessing MySQL into a servlet....
    You can put the user-ID and the password into a session-
    object or read them in as parameters.
    The book 'core Servlets and Java Server Pages' from
    Marty Hall gave me a lot information.
    Regards
    Fredy

  • Problems setting up Tomcat with RoboHelp Server V8

    Hi,
    My Systems Administrator is trying to set up RoboHelp Server version 8 for me. he has been following the Adobe Installation guide and has got as far as page 10 where it tells him to install and configure IIS and TomCat, at this point he says he does not understand what he should be doing. He has not installed TomCat before and it is telling him to configure the tomcat directory and although he has tried using what it says it comes up with an error the directory does not exist.
    He is using:
    Windows 2008 Server Standard
    IIS 7.0
    TomCat 6.0.20
    SQL Server 2008 express SP1 - this is the latest version the adobe instructions says RooHelp Server works with SQL Server 2008 but does not mention express not sure if that could be a problem?
    MS Report Viewer 2008 SP1
    Java V6 Update 12
    He says the installation guide talks about a directory with Win32 in it which does not appear on his machine its a 64 bit machine.
    Please can someone give me some instructions on how to set up the TomCat part - I have looked but the troubleshooting that adobe has does not seem to be for Windows 2008 only Vista and XP and even then it says nothing about setting up TomCat
    Thanks in advance
    Erika

    Erika
    Not an area I can help with but try this post. http://forums.adobe.com/thread/204737?tstart=0
    Also look through the forum. There are some detailed posts on this.
    Finally take a look at http://notcolin.wordpress.com. There are some relevant blogs there.
    See www.grainge.org for RoboHelp and Authoring tips

  • Help - JSC to Tomcat with MySql

    I built a simple test app in JSC with MySql.
    Product: MySql Ver. 5.0.27-community-nt
    Database name: Test
    Table name: testtable
    Datasource name: MySql1
    Dataprovider's SQL: SELECT ALL testtable.code, testtable.name FROM testtable WHERE testtable.name LIKE ?
    The page had a textfield, button, statictext and a table mapped to the dataprovider
    The following code was included:
    public void prerender() {
    try {
    String s = "";
    String t = (String) textField1.getText();
    if (t == null || t.equals(""))
    s = "";
    else
    s = t;
    s += "%";
    staticText3.setText(s);
    getSessionBean1().getTesttableRowSet().setObject(1,s);
    getSessionBean1().getTesttableDataProvider().refresh();
    } catch (Exception e) {error(e.toString());}
    public String button1_action() {
    return null;
    When tested in JSC, it worked fine.
    But when I exported it as a war file and deployed it in Tomcat 5.5.17 with the following settings, the statictext
    displayed the selected value, but the table showed "No items found". Please help.
    User: root
    password: adminadmin
    Connector downloaded: mysql-connector-java-5.0.4.zip
    The appropriate jstl.jar and standard.jar where used by copying them from jakarta
    The tomcat's server.xml used is shown below:
    <?xml version="1.0" encoding="UTF-8"?>
    <Server>
    <Listener className="org.apache.catalina.core.AprLifecycleListener"/>
    <Listener className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener"/>
    <Listener className="org.apache.catalina.storeconfig.StoreConfigLifecycleListener"/>
    <Listener className="org.apache.catalina.mbeans.ServerLifecycleListener"/>
    <GlobalNamingResources>
    <Environment
    name="simpleValue"
    type="java.lang.Integer"
    value="30"/>
    <Resource
    auth="Container"
    description="User database that can be updated and saved"
    name="UserDatabase"
    type="org.apache.catalina.UserDatabase"
    pathname="conf/tomcat-users.xml"
    factory="org.apache.catalina.users.MemoryUserDatabaseFactory"/>
    <Resource
    name="jdbc/Travel"
    type="javax.sql.DataSource"
    driverClassName="org.apache.derby.jdbc.ClientDriver"
    password="travel"
    maxIdle="2"
    maxWait="5000"
    validationQuery="select * from TRAVEL.PRODUCT"
    username="travel"
    url="jdbc:derby://localhost:21527/samp"
    maxActive="4"/>
    </GlobalNamingResources>
    <Service
    name="Catalina">
    <Connector
    port="8080"
    redirectPort="8443"
    minSpareThreads="25"
    connectionTimeout="20000"
    maxThreads="150"
    maxSpareThreads="75">
    </Connector>
    <Connector
    port="8009"
    redirectPort="8443"
    protocol="AJP/1.3">
    </Connector>
    <Engine
    defaultHost="localhost"
    name="Catalina">
    <Realm className="org.apache.catalina.realm.UserDatabaseRealm"/>
    <Host
    appBase="webapps"
    name="localhost">
    <Context
    path="/TomTest">
    </Context>
    <Context
    path="/TradeMeTender">
    <Resource
    auth="Container"
    description="Creator generated DataSource Reference"
    name="jdbc/Travel"
    type="javax.sql.DataSource"
    driverClassName="org.apache.derby.jdbc.ClientDriver"
    password="travel"
    maxIdle="2"
    maxWait="5000"
    validationQuery="SELECT * from TRAVEL.PRODUCT"
    username="travel"
    url="jdbc:derby://localhost:21527/sample"
    maxActive="4"/>
    </Context>
    <Context
    path="/FileUploadExample">
    <EJB
    home="greeting.GreeterHome"
    name="GreeterEJB"
    remote="greeting.Greeter"
    type="Session"/>
    </Context>
         <Context path="/MySqlTest" docBase="MySqlTest"
         debug="5" reloadable="true" crossContext="true">
              <Resource name="jdbc/MySql1" auth="Container" type="javax.sql.DataSource"
    maxActive="100" maxIdle="30" maxWait="10000"
    username="root" password="adminadmin" driverClassName="com.mysql.jdbc.Driver"
    url="jdbc:mysql://localhost:3306/Test?autoReconnect=true"/>
         </Context>
    </Host>
    </Engine>
    </Service>
    </Server>

    You could track JDBC calls and the SQL's executed by the driver at the database,
    Update you datasource, DBURL with some parameters/properties to generate some info for debugging like this:
    jdbc:mysql://$hostname:$port/$databasename?autoGenerateTestcaseScript=true&dumpQueriesOnException=true
    Check out your deployment containers log to find out which particular SQL statement is being executed. This could help in identifying performance issues with application. That could possibly give a clue, if something is not working in your application.
    For designtime JDBC calls made, this info is sent to IDE log.
    Reference: http://dev.mysql.com/doc/refman/5.0/en/cj-configuration-properties.html
    HTH,
    Sakthi

  • Please Help, Data Set Master/Detail with mySQL DB

    Hi...
    I installed the Data Set Master/Detail Sample (states and
    citys autopopulate) getting values from a XML file...
    when a user adds a listing in my site, it works great.. i use
    the XML file values for the states/citys and then everything is
    stored in a DB... BUT i need to do this..
    when he comes back to edit his listing, i want the Data Set
    Master/Detail to show hes values (from de DB) with the option to
    edit them, not the first XML file values.
    Thanks

    Thank you kinblas!!!!!
    I saw another post with the solution!!!
    Here it is
    http://www.adobe.com/cfusion/webforums/forum/messageview.cfm?forumid=72&catid=602&threadid =1308016&highlight_key=y&keyword1=SetDefaultState
    Thanks again!

  • Need help setting up JDBC with mySQL and Netbeans

    I've successfully got mySQL up and running and created a few simple test databases. I've been following the instructions on this website (http://www.stardeveloper.com/articles/display.html?article=2003090401&page=1 ) to get JDBC working but have had little luck.
    I've downloaded JDBC from mySQL website, extracted the mysql-connector-java-3.1.13-bin.jar file and changed the class path to :
    C:\Program Files\Java\jre1.5.0_06\lib\ext\mysql-connector-java-3.1.13-bin
    which is where I placed the .jar file.
    I then used the following code provided on stardeveloper.com to test a connection with the test database.
    import java.sql.Connection;
    import java.sql.DriverManager;
    import java.sql.SQLException;
    public class JdbcExample2 {
      public static void main(String args[]) {
        Connection con = null;
        try {
          Class.forName("com.mysql.jdbc.Driver").newInstance();
          con = DriverManager.getConnection("jdbc:mysql:///test",
            "root", "secret");
          if(!con.isClosed())
            System.out.println("Successfully connected to " +
              "MySQL server using TCP/IP...");
        } catch(Exception e) {
          System.err.println("Exception: " + e.getMessage());
        } finally {
          try {
            if(con != null)
              con.close();
          } catch(SQLException e) {}
    }It compiles but when run I get the error message :
    java.lang.NoClassDefFoundError: testdatabase/JdbcExample2
    Exception in thread "main"I assume this means that my classpath isn't setup correctly but I have no idea what's up and how to correct it.
    Can someone PLEASE tell me how to setup jdbc and what I've done wrong.
    Thanks in advance :)

    Thanks for your reply. I've made some progress but I'm still having problems.
    In mySQL I created a new user called uraknai with password n0121429 and granted them access to a test database I created called pet.
    Then, in netbeans, I clicked the Runtime tab, clicked Databases and rightclicked Drivers and clicked Add Driver. I then added the driver mysql-connector-java-3.1.13-bin.jar. I then right clicked the newly added driver and selected the connect using option. I filled in the appropriate boxes clicked ok and it connected successfully.
    Then, under the project tab, I right clicked the project name, clicked properties then clicked Libraries and added the .jar file mysql-connector-java-3.1.13-bin.jar
    I then ran the following code to test the connection to the database:
    import java.sql.*;
    public class ConnectionTest {
        public ConnectionTest() {
        public static void main(String[] args)
            System.out.println("BEGIN CONNECTION TEST");
            Connection conn = null;
            try
                   String userName = "uraknai";
                   String password = "n0121429";
                   String url = "jdbc:mysql://localhost/pet";
                   Class.forName ("com.mysql.jdbc.Driver").newInstance ();
                   conn = DriverManager.getConnection (url, userName, password);
                   System.out.println ("Database connection established");
             catch (Exception e)
                   System.err.println ("Cannot connect to database server");
             finally
                   if (conn != null)
                       try
                           conn.close ();
                           System.out.println ("Database connection terminated");
                       catch (Exception e) { /* ignore close errors */ }
    }and get the message:
    java.lang.NoClassDefFoundError: math/ConnectionTest
    Exception in thread "main"
    Java Result: 1when I run the code.
    Can someone explin what I've done wrong and how to fix the problem.
    Cheers.

  • Steps to set up my domain with Apache

    Hello,
    I would like to know the steps to set up my domain with Apache including the use of DNS Services. I have DNS services (http://www.dnsexit.com) . I just don't know where to begin with it adding my domain. I've already went  to my preferences>>sharing>> web sharing and turned it on. My domain host is netfirms. I have an actiontec model- m1424-wr  router  and I have a verizon fios wireless connection that's always on. I've been doing my research on this. I'm just stuck on this part. However is it true that php/mysql is pre-installed on Mac osx 10.6? I hope I can get help. Thank you in advance.

    Your description is somewhat incomplete. I assume that dnsexit.com provides dynamic DNS and that you registered a domain name with NetFirms (you say "domain host", but I presume that you just registered the domain name and they aren't actually hosting it; hosting means that your web site is on their computers instead of yours). I'll also assume that you mean that you intend to run a web server on your Mac through your FiOS connection (not a great idea, and potentially a violation of FiOS' terms of service unless you bought their commercial plan).
    If all of those assumptions are correct, you need to:
    1. Contact NetFirms and tell them to point your domain to DNSExit's name servers: ns1.dnsExit.com and ns2.dnsExit.com and ns3.dnsExit.com and ns4.dnsExit.com
    2. After step 1 is complete, you need to install a dynamic DNS update client on a computer in your network that will always be on (DNSExit has them and installation and set-up instructions). These programs will periodically check the IP address of your network and, if it changes, will update the record at DNSExit so that sites can find it. Note that you are using FiOS so the IP address of your router is expected to change periodically; this works around that. Your router has 2 IP addresses: the WAN is the IP address exposed to the world through your FiOS connect, and the LAN, which is an address local to your home network.
    3. Login to your ActionTEC router as the adminsitrator. You can do this through your web browser. The LAN IP address of the router is the gateway address indicated in the Network preference pane for your ethernet connection. The modem documentation tells you the default password for the router (make sure to change it).
    Perform the following tasks on the router (though the advanced options, you'll want to poke around to find them):
    a. check the DHCP address ranges (usually it says that it will give out IP addresses from 192.168.1.100-192.168.1.200 or similar). Note it down. You're going to want to give the computer that acts as the web server a static IP address outside that range.
    b. Choose an address outside the DHCP range that isn't already in use and write it down. This will be the static IP addres you will set on your web server.
    c. Locate the Firewall/NAT settings on the router and add a rule to forward traffic on ports 80 and 443 to the IP address you had chosen.
    4. On the computer that will be the web server, start web-sharing.
    5. Go to the network preferences and configure the static IP address that you selected. Use the same gateways and DNS settings that were assigned by DHCP.
    ... and that's it. If you performed all those steps properly, requests to your domain will be sent to your FiOS modem and forwarded on to the designated computer for a response.
    PHP and Apache are preinstalled on the Mac. MySQL is not. You will need to download and install MySQL yourself.

  • Is anybody out there who knows the steps to set up Logic Express? with an Alesis iO|26 interface

    Is anybody out there who knows the steps to set up Logic Express 9 (scores) with an Alesis iO|26 interface to input notes by playing
    an electric guitar? Thank you for your time and patience.
                                                                                          W.W.

    And i fount this
    PETERSON SONUUS-G2M MIDI-KONVERTER
    ok this one could sendout your guitar sound as a MIDI data but only monophone.
    Thats what i see as a big computation problem ( when you play your simple C7 there are
    at least 10 important parameter that describe your C7 chord; but if you play monophone
    theese small boxes can convert it).
    Have you tried anny MIDI guitar?
    I saw some "usb" guitars transmiting midi signal into
    software synth on some computer.
    http://www.roland.com/products/en/GI-20/
    This one?

  • Steps to UTF-8 Encoding with Oracle 8i and Weblogic 6.1SP1

    What are the Steps to UTF-8 Encoding with Oracle 8i and Weblogic
              6.1SP1?
              I have:
              - Oracle 8.1.5 database created with character set=UTF8 and national
              character set=UTF8
              - Weblogic 6.1SP1 without any encoding mechanism set
              (though I did play with
              <jsp-param><param-name>encoding</param-name>
              <param-value>UTF-8</param-value>
              </jsp-param>
              in the weblogic.xml for a while though it seemed not to make a
              difference)
              - JSP pages set to content='text/html; charset=UTF-8'
              - JSP form POSTs set to enctype="UTF-8"
              I can copy and paste Chinese Kanji from a UTF8 encoded web page into
              form text boxes but when I post the data it comes back as different
              Kanji. Then once it is posted the Kanji stays the same on repeated
              posts. The same Kanji text also looks different when viewed in a form
              text box than when viewed as straight text on the page.
              Is there anything else? Or am I already encoding characters twice?
              Please help!
              Mel Christie
              

    Hi Experts,
    Please correct me if am asking you the question in wrong way.
    I have ARCGIS with oracle database 10gr2 in production server.
    My work is to connect AUTOCAD S/W (client computer which is connected in LAN) to ARCGIS in order to access the toposheets available in SDE user.
    When iam trying to connect iam getting this error:The specified credentials are not valid or provider is not able to establish a connection.
    I checked the path to production server by pinging and user/passcode too but not helpful.
    Please help me in this , very urgent.
    Thanks.
    Edited by: user13355644 on Jul 3, 2010 3:53 AM
    Edited by: user13355644 on Jul 22, 2011 2:55 AM

  • Steps to setting up BI in SAP Netweaver abap 7.0 trial version

    Hi all,
    I meet some difficulties to setting up BI in SAP Netweaver 7.0 trial version
    I do those steps:
    - loggin to client 000 with user DDIC pwd minisap
    - Change client active to 001 with transaction SE16
    - Enter table name RSADMINA
    - Enter BW in the CUSTOMZID field and click Execute (press F8)
    - Select the table row BW and click change (press F6)
    - Enter 1 for the BWMANDT and click save
    - Run SU01
    - create new user NWUSER
    - initial pwd for the NWUSER sap2009
    - create grant (SAP_ALL, SAP_NEW)
    - save
    - log off on the system
    - login to client 001 with new created user NWUSER
    - I can't loggin --> name or password is incorrect (repeat logon)
    Wich step i missed?
    Please help me, i need to pratice some tuto on BI platform
    Thanks and bests regards
    Souad

    Hi all,
    I arrived to active BI platform in sapnetweaver trial version 7.01, i follow this steps.
    1/You need to login to 001 client as SAP* password minisap
    2/Create your own user in SU01 transaction and log in with your own user.
    3/Then run Administration workbench of BW (RSA1) and create and assign of logical system to your client,
    4/replicate DataSources form its own BW system.
    It's easy and simple.
    Trial version had a limit, when i tried to create a transformation between a datasource an InfoObject i meet some trouble. Log message suggest to install frontend of sap netweaver to resolve this trouble.
    This topic is close
    Thanks Uday
    Kinds Regards.
    Souad

  • How to make the servo motor to move in steps of set degrees and stop

    how to make the servo motor to move in steps of set degrees and stop

    Hi,
    I think the following document would be a good starting place: NI Developer Zone Tutorial: Single Axis Moves It includes links to several example programs that you may find useful for your application. Keep in mind that there are many motion examples that ship with LabVIEW as well.
    I strongly recommend that you check out the following documents as well:
    NI Developer Zone Tutorial: Simple Point to Point Motion
    NI Dev
    eloper Zone Tutorial: Hands-On Motion
    NI Developer Zone Tutorial: Axis Settings for Motion Controllers
    These tutorials will help give you a good foundation for understanding motion control systems.
    Best wishes!
    Dawna P.
    Applications Engineer
    National Instruments

  • My sister bought a 16GB iPod touch 5 and went thru all the steps to set up but then realized it didn't have a camera. So we clicked reset and erase all contents and settings. This does mean her credit card info is erased right?? Thanks for your help.

    My sister bought a 16GB iPod touch 5 and went thru all the steps to set up but then realized it didn't have a camera. So we clicked reset and erase all contents and settings. This does mean her credit card info is erased right?? Thanks for your help.

    Welcome to Apple Support Communities
    When you erase an iPod touch, your information, apps and settings are deleted and iOS is back to factory settings. If she wanted an iPod touch with camera, she should return it after erasing it. Note that the iPod touch doesn't store her credit card information

  • HT204053 I have an Apple ID, but when I try to sign in for icloud, from the control panel, it says that I have an Apple ID but I don't have one for icloud. I can't seem to find where I set up the account, even though I've gone thru the steps to "set up" i

    I have an Apple ID that I use for itunes.  I am trying to set up my icloud account.  I have gone thru the steps to "set up" the icloud account.  It only has me download the icloud control panel, then I'm supposed to sign into icloud, but then it tells me that I don't have an icloud account.  I have looked all over the support area and it doesn't tell me how to get passed this problem.  Any suggestions?

    http://www.youtube.com/watch?v=gmOmd_WFp6o
    This was helpful for getting icloud set up from my pc...but someone said that they had it on their pc and then it disappeared. Fun! Fun! Fun!

  • Error occurred in deployment step 'Add Solution': A feature with ID '' has already been installed in this farm. Use the force attribute to explicitly re-install the feature.

    Hi I am getting the error
    Error occurred in deployment step 'Add Solution': A feature with ID 10495515-2482-41fd-98eb-3c87f739f54b has already been installed in this farm.  Use the force attribute to explicitly re-install the feature.
    when trying to deploy web parts
    question 1 - how do i use the force attribute when deploying from visual studio
    question 2 - am i deplying it to the right place, if i deply it to the
    url:port that points to my central admin tool it deploys but i cant seem to see it in any of my webs in my site collection, if i deploy it to the
    url:port that points to my site collection I get this error.
    im new to all this by the way :)
    thanks in advance

    If you are deploying from Visual Studio then please follow this post:
    http://sharepointfordeveloper.blogspot.com/2014/03/solved-visual-studio-issue-error.html
    Open the visual Studio and navigate to the feature XML file and add the bellow attribute.
    AlwaysForceInstall="TRUE"
    The <FeatureName>.Template.Xml output would be some think link this.
    <?xml
    version="1.0"
    encoding="utf-8"
    ?><Feature
    xmlns="http://schemas.microsoft.com/sharepoint/"
    AlwaysForceInstall="TRUE"></Feature>

  • Steps to upgrading iphone 4 with iOS 5

    Need steps to upgrading iphone 4 with iOS 5?

    1. connect ur phone to ur mac/pc
    2. open itunes ( make sure u have version 10.5 )
    3. if it doesnt automatically ask u to update ur phone . click on summary and then click update
    4. ensure that u backup ur data before updating.
    5. click on download and install.
    6. wait for a while and enjoy iOS5

Maybe you are looking for

  • Can't connect my 2009 macbook pro to new 2011 LG TV

    I just got a new LG LED LCD TV and I'm trying to connect my 2009 macbook pro to it. I bought a Belkin Mini Display Port to HDMI Adapter at the Apple Store. I also bought the Apple HDMI to HDMI 1.8m cable to connect the computer to the TV. I set up th

  • Adobe has taken over my scanner.  Used to scan and it would come to my computer as a

    Adobe has taken over my scanner.  I used to scan and it would go to a file.  It asked me to update and it came up with a bunch of choices, I asked someone which to chose and they suggested whatever I have.  On the side it comes up with =  Export, Cre

  • Function module not showing my itab

    hi am working on smartforms  in se38 i declared an internal table it_regup after decalrations and select statements i went to smart forms i looped there and am displaying i called tht function moudule after calling SSF_FUNCTION_MODULE_NAME and in the

  • Playing SWF files each time a web page is used.

    Hi Gang, Currently using flash catalyst to create a website for work (seriously not a programmer but love creating visual art). I have a SWF file that I want to run EVERYTIME a page is viewed, (its actually part of the page) but currently the file wi

  • Airdrop - not working from iMac to MacBook Pro

    Airdrop won't work from iMac to MacBook Pro, but will work from MacBook Pro to iMac. Is there something I need to set on either computer? Thanks.