query 3 « Operation « Java Database Q&A





1. Can someone tell me what is wrong with this query?    coderanch.com

Hello everyone, I am trying to run the following query in DB2... SELECT distinct DS.DUP_SONG_RESOLUTION_ID as dupSongResId FROM DB2INST1.SONG_TITLE TITLE, DUPSONG.DUP_SONG_RESOLUTION DS WHERE TITLE.SONG_TITLE_NM like '%love%' AND TITLE.TITLE_TYPE_CD='OT' AND DS.STATUS_CODE <>'5' AND DS.STATUS_CODE <>'6' AND (TITLE.SONG_CD =DS.MASTER_SONG_CODE or TITLE.SONG_CD =DS.DUP_SONG_CODE) ORDER BY DS.DUP_SONG_CODE and it gives the following error... 17:07:07 [SELECT - 0 row(s), 0.000 secs] [Error Code: -214, SQL State: ...

2. Dymanic queries    coderanch.com

Hi, We have a Java EE back-end application using EJBs plus DAOs. We are now going to integrate a Java Web Front-End. The front-end will allow the user to query data, providing numerous query criterias- simple comparisons (= ,<, >, >=, =<, !=), intervals (between X and Y), multiple values (in (A, ..., Z)), etc. That means that the queries we ...

3. query    coderanch.com

4. query problem    coderanch.com

hi all how to retrive data using firstname or lastname. when a user enters his firstname or lastname he will get all the details about him,but i dont know how to write or(||) in the query, my query is: select url,title,user_id from user_profile where first_name='vamshi'|| last_name='g' is this query is correct. thank you.

6. JDBC QUERIES    coderanch.com

7. Subselect runs fast, outer query doesn't    coderanch.com

SELECT DETAIL_ID /*SELECT #1*/ FROM DRLR5.RU_METRIC_DET WHERE DETAIL_ID IN ( SELECT /*SELECT #2*/ MD.DETAIL_ID FROM DRLR5.RU_CMI_REPORT_DET RD JOIN DRLR5.RU_METRIC_DET MD ON MD.DETAIL_ID = RD.DATASOURCE_KEY JOIN ( SELECT CR.HW_ASSET_ID, COUNT(CR.HW_ASSET_ID) AS CLUSTER_COUNT FROM DRLR5.RU_METRIC_DET M JOIN DRLR5.RU_CMI_REPORT_DET CR ON M.DETAIL_ID = CR.DATASOURCE_KEY WHERE M.METRIC_NUM = 53187 AND MONTH(M.METRIC_STOP_DT) = MONTH(CURRENT DATE) GROUP BY CR.HW_ASSET_ID ) AS C ON C.HW_ASSET_ID = RD.HW_ASSET_ID WHERE ...

8. Please help with db query    coderanch.com

9. wether JDBC supports UNION Queries    coderanch.com





10. Reduce db query frequecy    coderanch.com

Hello, i am trying to find an approach to reduce users' queries to database by querying more records from the database using spatial locality concept. This approach will be used in a news database. The idea is users usually want to read the latest news instead of the older one. However, some user may want to read the old news. It ...

11. Query regarding Database commit and Queue Commit    coderanch.com

Hi, Let me first give a brief introduction of the business scenario - I am using JMS Queues and I have a Java application which listens on this queue constantly. Wheneever, there is a message on this queue, it is picked by this Java application and a stored procedure is called internally and the data from the message is stored in ...

12. Help need in query    coderanch.com

I have a table as follows Id Name col1 col2 col3 11 Abhishek val1 val2 val3 12 Ajay val1 val2 val3 13 Meera val4 val5 val6 14 Vijay val4 val5 val6 15 Malik val4 val5 val6 16 Sunil val7 val8 val9 17 Mehul val7 val8 val9 and so on I want to write a query such that I get a single ...

14. OracleDatabaseMetaData Typeinfo query getting fired    coderanch.com

Author OracleDatabaseMetaData Typeinfo query getting fired Shail Rathi Greenhorn Joined: Dec 03, 2008 Posts: 2 posted Dec 03, 2008 05:17:00 0 I am using com.ibm.db.beans.DBSelect. following is code snippet. public SQLUtilitiesAnswerSelect() { super(); initializer(); } protected void initializer() { select = new DBSelect(); try { select.setConnectionSpec(SurveyPortlet.connectionObj); select.setCommand("SELECT ANSWER_ID, ANSWER_DESC, ANSWER_ORDER, IS_DEFAULT, PERCENT_WEIGHT FROM ANSWERMASTER WHERE QUESTION_ID =:questionId ORDER BY ANSWER_ORDER asc"); ...

15. Problem in Query    coderanch.com

Hi friends, I want to do one jdbc program which runs the query with wild characters. Before that in my table filed values are like "ARVOD TEC ", that is a lot of space at the end. In jsp page if the user enter AR* it should display all the data starts with AR if the user enter *VOD it should ...

16. Regarding time taken by query    coderanch.com

Priyakant, I'll assume you are talking about indexes rather than keys. I would expect the two queries to perform similarly. The way to find out for sure is to run a database explain to see how your database does it. My guess on the execution plan: table 1 1) use the index to find the one record matching both name and ...





18. Query Dillema    coderanch.com

Hi Guys I have two queries executing, I am using the commit/Rollback method. The problem is for the second query, I need the ID from the first query for one of the foriegn key columns in the second query. Is there anyway of getting the ID for the first INSERT record before committing to the transaction? See my code below: conn.setAutoCommit(false); ...

19. The query has been canceled !!    coderanch.com

20. Problem in using "IN" in query    coderanch.com

21. What is the impact of HashMap/TreeMap on Database queries?    coderanch.com

I was asked this question in interview. Can you guys tell me what would be the right answer to this questions? 1) when hashmap or treemap are implemented, do they effect database queries? I said that we could cache the data into collections so that we can read data from memory instead of doing DB transacations. This would increase the performance ...

22. Db Visualizer - Queries    coderanch.com

Hi Roger Bjrevall, It is really nice to see the tool.Of course it typically reminds me of 'SQLYog' -- a prominent GUI for MySQL database. Looking at the features, was really amazed by "Charting of data" and "multi result set management". The navigator feature is awesome!! I guess this tool definitely has many things in store Also felt happy on seeing ...

23. Need help - Lot of joins are slowing down my query    coderanch.com

Hi Mansi, you did not tell against which DB your query is executed - and not too many details about the query / tables, etc. Well, I'm only used to Oracle, so maybe most of my hints won't be applicable to your situation. I agree with my pre-posters that indexes may be one answer. But creating indexes is just one part ...

24. DB Visualizer: query optimization    coderanch.com

25. JDBC and optimizer query hints - are they recognised?    coderanch.com

Hi folks, An Oracle hotshot at a customer site has identified a problem query that can be improved by adding optimizer hints of the form "select /*+ index(.... etc". The query is executed using a regular JDBC PreparedStatement. The database is oracle 9i and we're using the classes12.zip (not sure of exact revision) for the JDBC driver. It's a legacy app ...

26. DB query from bean    coderanch.com

27. run query in the same time    coderanch.com

If you mean as a single update, yes, you can chain them together in a single string if your driver supports batch queries. Although usually when you perform a batch operating all the queries are the same type. Having a batch operation of multiple different type (Select, insert, update) would create output akin to apples and oranges, as in its hard ...

28. doubt in a query    coderanch.com

I am working on a application where pagination is used for navigating the content of a chapter.I have a database table which contains the subjectname say (science) it has chapters like chap1,chap2,chap3,chap4 and each chapter contains some 5 pages . Now my problem is How can i get the exact number of (count) page number 4 of the chapter number chap3 ...

29. Problem with query    coderanch.com

I know this is a simple query. When I try to execute in TOAD it is giving me the result. But when i put it in my application code it is not entering into rs.next loop Not ure what is happening String query = "select category_name from category_info where category_parent_level in (select category_no from category_info where upper(category_name) = upper(' " +category ...

30. java.lang.OutOfMemoryError: Java heap space in DB query    coderanch.com

Do you have a log of the exact query/parameter that runs, when you get an out of memory error? And what happens if you run the same error-generating query directly, using a SQL querying tool? Or maybe you have a memory leak somewhere else in the application. Is this the ONLY place where you get an out of memory error?

31. Need a sample query    coderanch.com

Hai friends, Consider a case that if I want to insert 60 records of student, for their attendance. I just need to do bulk insert of all 60records at a second.Can any one get a sample query.Even if there is chance for batch update how to do it,can any one get me a sample querry.

32. How to create dynamic query builder?    coderanch.com

Hi All, I have a requirement where I need to show a report in a j2ee application(jsp/servlet) and the available columns will be shown in a pane. The user will choose from those options. So I need to build a runtime query builder. Please tell me the elegant way to do this. Thanks, Kousik

33. counting slaries using query    coderanch.com

34. MULTIPLE Query IN a RS    coderanch.com

If you want to use a single result-set then its a better idea to close the first one (off course after result set has been iterated) and then executeQuery on the same instance of result set. See the code below, you will get a better idea Try this String st1="select sum(salary) from v_table where id=2 and post!='manager'"; String st2="select sum(salary) from ...

35. how do do this? -> depending on the query, returns different objects    coderanch.com

hi, i'm not sure if this question goes here. and I'm learning java by myself. i was trying to make an small application, and i found a situation like following: let's say I have 3 tables, user(id_usr, name, surname) , sport(id_sport, sport), hobbies(id_usr, id_sport), and 3 classes with the same attribute and only setters and getters (i think they call beans ...

36. Self Join Query Help    coderanch.com

Hello all, I have a table like the one shown below id parentChannelId ------------------------ item1 null item2 item1 item3 item1 item4 item2 item5 item3 item6 item6 .....so on ..so on I would want to get all the children (which includes the grandchildren) of item1 , I know i need to do a self join.But i am not sure on how to ...

37. What's the best design approach when querying a database in a web app?    coderanch.com

Hi Adrian, as you have guessed correctly putting database access code directly into servlet service methods or JSP scripts is bad and ugly Unfortunately it's harder to tell anything like a "best way". There are fundamentally different access methods like pure JDBC with SQL statements or O/R mappers like hibernate for example. Despite this technology difference you could still hide this ...

38. query is not getting executed    coderanch.com

39. can't run query from java war    coderanch.com

Hi, I developed a jar file which turn to the h2 db and reads data. I included this jar inside a web application that I developed using eclipse. I have a jsp file that reads data from the db using that jar. It works fine in the eclipsa. When I exectute war file out of that web app, and put it ...

40. Regular query vs JDBC Programming?    coderanch.com

I am in the middle of trying to get a HUGE SQL query to work. Uggg! It's quite complicated in that to make it work, it will take lots of sub-queries and other things (like UNIONS). The problem is, well, it's too complicated! And, of course, it needs to be done ASAP. I'm therefore wondering if it wouldn't be easier to ...

41. general query    coderanch.com

42. query for maximum marks    coderanch.com

43. Validation/DB query question    coderanch.com

public static boolean duplicateUserid(String userid) { ConnectionPool pool = ConnectionPool.getInstance(); Connection connect = pool.getConnection(); PreparedStatement ps = null; ResultSet rs = null; String query = "SELECT COUNT(Userid) FROM User WHERE userid = ?"; boolean bCount = true; try { ps = connect.prepareStatement(query); ps.setString(1, userid); rs = ps.executeQuery(); if(rs.equals(0)) {bCount= true;}else{bCount =false;} return bCount; } catch(SQLException e) { e.printStackTrace(); } finally { ...

44. Query Preparation    coderanch.com

45. problem with inser into query    coderanch.com

Dear friends, I have a table with column titles as: (id, price,quality,deadline,UtilityValue,sellerNumber) which Id is an AUTO_INCREMENT! now I want to copey this table to another table with the exact same column titles. till here every thing is ok! but I DONT want to copy the id field. what I want is that I copy the data of each row except ...

46. How to write query to obtain not 100% match?    coderanch.com

Dear experts, I manage to come up with the 'matching' codes. However, it doesn't produce exactly what I want and I'm stuck so I hope someone can advise me the correct way to do the query. Thanks. What I'm trying to achieve is: Parents ID and contact together with the tutors name and contact and subjects taught will be displayed once ...

48. Queries via MapReduce in NoSQL?    coderanch.com

49. Query taking forever    coderanch.com

50. Query Time out    coderanch.com

Hi , I am using Oracle JDBC Driver version - 9.0.2.0.0 in my JDBC based utility program. the problem is when query takes more than 20-30 minutes to return the resuts ,I face "Time out" error. I have tried printing getQueryTimeOut(); which will print '0' (Zero) I have read from JDBC API doc that Zero indicates Driver will wait for any ...

51. How to reduce the response time when querying the Database ...    coderanch.com

hi all, I am using Ejb 3.0 in my Application with back End MySQL 5.0 I am working on a bank reconcilation Module where a file of about 20 lacks record is uploaded. which is validated with database and then inserted . it took almost 20 lacks queries to insert data.. It take a lot of tym to upload that Huge ...

52. this is my query running succesfully in database but in my java program rs.next() is false    coderanch.com

I bet that the problem is difference in national settings, and the horrible where clause (where invoice_date like '03-12-2010%'). The invoice_date column is most probably a DATE type. When you compare it to a text value using the LIKE operator, it is implicitly (silently) converted to text using actual national settings. When you run the query in the database client, the ...

53. Large data query hangs indefinitely    coderanch.com

Hi, I'm new to DB development; so please bear with me. I need to query a large data set (potentially be in the 100K range). Using Netbeans, the result returned w/o issues; however, performing the same query in the command line... a "2" is returned and hangs indefinitely. Now, in the application, the same query returns a resultset and is able ...

54. How to get "closest to" values in a query?    coderanch.com

I'll be writing a SQL select to fetch a record given latitude and longitude values. The table contains discrete latitude and longitude values for various zip codes. It is highly unlikely that the latitude and longitude value that 'll be using for input will exactly match values that are in the table. What would be the most efficient/easy way to fetch ...

55. Query does not work    coderanch.com

Do you mean that when executing a query like select .... from ... where field like '%this is a search string%' the query will not return records containing the text 'this is a string' ? This is actually the expected behaviour. The like operator searches for exact matches, allowing you just to specify wildcard characters for a single character or a ...

56. JDBC queries or stored procedure    coderanch.com

57. Slow running query that uses SUBSTR    coderanch.com

58. Processing None-SQL query via JDBC    coderanch.com

59. How can I make this query take less time?    coderanch.com

I am trying to check soem data within a certain data and that has a value in one of the columns. Trying something like this: SELECT * FROM table_name WHERE creation_date BETWEEN '01-JAN-2001' AND '10-JUN-2010' AND attribute1 IS NOT NULL; but this is taking a long time to run. Something like 30-45 minutes. Even if I try to change it to ...

60. one conneciton, multple queries    coderanch.com

Hello, I've a requirement to insert a list of employee into Emp table. I've following options: option 1: public void updateEmpTable(Employee e) { // standard connection code st.executeUpdate("insert into Emp values (' + e.name +')"); conn.close; } I call this method for entire employee list. Note: the connecion creation & closing part is happening for each employee. option 2: public void ...

61. Search Query Problem    coderanch.com

SQL> create table patients( 2 patient_id number(14), 3 rDate timestamp(0) default sysdate, 4 title number(5), 5 firstName varchar2(25), 6 lastName varchar2(25), 7 email varchar2(110), 8 nationality number(5)); Table created. SQL> SQL> insert into patients(patient_id,title,firstName,lastName,email,nationality) values(1,1,'Test','Hello','test@test.com',5); 1 row created. SQL> insert into patients(patient_id,title,firstName,lastName,email,nationality) values(2,1,'Testing','Hello','test@test.com',4); 1 row created. SQL> insert into patients(patient_id,title,firstName,lastName,email,nationality) values(3,1,'Hello','world','test@test.com',3); 1 row created. SQL> commit; Commit complete. SQL> select patient_id ...

62. group by query    coderanch.com

63. Executing query from java program    coderanch.com

Hi All, I am frustrated with a problem. I have created so many queries for DB2 and successfully executed it. I am facing problem a query which uses IN keyword. I have a text box on page where user can enter any number of comma separated values. I need to query DB using this parameter as SELECT * FROM STATE WHERE ...

64. org.springframework.dao.EmptyResultDataAccessException: No entity found for query    coderanch.com

Hello, With Spring 3.5.1, Liferay 5.2.8 (EE SP4), when I deploy the WAR file to liferay hot deploy directory, it thrown the following exception: Caused by: org.springframework.dao.EmptyResultDataAccessException: No entity found for query at org.springframework.orm.jpa.EntityManagerFactoryUtils.convertJpaAccessExceptionIfPossible(EntityManagerFactoryUtils.java:295) at org.springframework.orm.jpa.aspectj.JpaExceptionTranslatorAspect.ajc$afterThrowing$org_springframework_orm_jpa_aspectj_JpaExceptionTranslatorAspect$1$18a1ac9(JpaExceptionTranslatorAspect.aj:15) at com.ix.msp.persistence.jpa.ServiceFacade.findByName(ServiceFacade.java:53) at com.ix.msp.persistence.jpa.ServiceFacade.findByName(ServiceFacade.java:1) at com.ix.msp.domain.loader.VocabularyLoader.afterPropertiesSet(VocabularyLoader.java:113) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1469) at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1409) Here is the ServiceFacade.java file: package com.ix.msp.persistence.jpa; import javax.persistence.EntityManager; import javax.persistence.PersistenceContext; import javax.persistence.NoResultException; import javax.persistence.Query; ...

65. Single query that counts children including zero elements    coderanch.com

I'd like to join two tables (parent/child relationship) and show the items name from the Table A along with a count(*) of the number of matching items in table B. The result should look something like this: 102, WidgetA, 10 --> Indicating there are 10 records in table B 105, WidgetB, 0 --> Indicating there are 0 records in table B ...

67. Vector for database query    coderanch.com

hi to all, I have created a vector to store the database query results using "dataset" syntax like getDataset etc. now when i print using logger the format is [[values],[values]] again to retrieve element by element value i created another vector vectorname2 and used vecotrname.elementAt() which gives the result in [values] form. Now for null value of database i entered a ...

68. query working in sqldeveloper and not from java jdbc    coderanch.com

The ORA-01861 error indicates a conversion from textual format is taking place. Post the java code so that we can see what's happening there. Also, I've never used ojdbc14.jar and I don't want to claim this is connected to your issue, but unless you're on Java 1.4, I'd suggest moving to newer version of the JDBC client.

69. JDBC-ODBC Bridge Query Problems with "LIKE" clause    go4expert.com

Hello Everyone, I am connecting to a MS Access database using the DriverManager class and JDBC-ODBC Bridge driver. I am having trouble with a query using the "LIKE" clause in MS Access. When I run the query in Access, it returns results as it ought to, but when I attempt to use this string of SQL in a prepared statement, it ...

70. Can't Send More Than One Query To The Server (Using Jdbc And Ocsf)    go4expert.com

hello, i'm using JDBC and OCSF to make client-server connection including MySQL. i'm now stuck at a very strange problem: my server can receive either "select..." string, "insert..." string, "update..." string (those are treated as queries), or any other string, which is treated as a simple message to the server (i do nothing with in so far) here is the code ...

71. I need help with a query.    java-forums.org

In my application, I have three tables from which I created a view, lets call them table A, B and C. I have a frame in which the user inputs a search word into a textfield, this word is from the column 'name' from table A. I need to return the values from the column 'name' from table B associated with ...

72. [SOLVED] Concrrent Queries with One Statement/Connection...    java-forums.org

Is there any way to have concurrent qureies with only one statement/connection... My database is Postgres and in my Java application I have 2 threads in which they each query the database with the same statement and connection... I want them to query concurrently, but no matter what I try, they will both start concurrently, but the second query waits until ...

73. Query Optimization    java-forums.org

Query Optimization This is my first article and so please provide comments on it (good or bad). The design of the database is one of the most important factors in the performance of the database and with a good database design you also need optimal queries to perform optimally. Everyone wants the performance of their database to be optimal ...

74. Need Explanation for a Simple Query    java-forums.org

Hi everybody. I was developing a JSP page with a "Registration Form" in it. Therefore I am supposed to store all the information that user provides into the Database. I was trying to use "Prepared Statement", but my faculty told to use the following simple query. I used it and it worked. But I didn't understand it's meaning. Pls explain the ...

75. Not getting a response for query    java-forums.org

76. Multiple queries - is it smart to enable this    java-forums.org

I think this is the best solution you can take. Using stored procedures you can easily handle transactions in case of any error. For example say you want to do an insertion to the DB as well as update on DB. And the update fail, and if you want to rollback the insertion it's very easy to handle in SPs. There ...

77. how to run the two queries at the same time    java-forums.org

how to run the two queries at the same time Final.java Java Code: int objectId; int clientId; DateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); // String gpstime = null; PreparedStatement preparedStatement = null; Connection conn=null; long Total=0; int b; int b2; int nano=0; int nano1=0; String disHour=""; String disMinu=""; String disSec=""; Speedfinal f=new Speedfinal(); ArrayList arr = new ArrayList(); ArrayList ...

78. Receiving data from a socket and querying database    java-forums.org

Hi, I have the following program, what it does is receive information from a socket, and when the information received matchs with a cell in a database, it performs some actions, when not, it should do nothing. The program is actually working, but, in the part that it should do nothing (else part of if (actualsituation.next()){ ) after some seconds (5 ...

79. How i know how many lines were replied from a query?`    java-forums.org

Hmmmm Still I dont know really how to do what I want. OK here is the problem. I developed a program that receives data from a socket and queries a database with the data received: if the query gives a result, it will send the information of each column of the database trough a socket. The program works great if just ...

80. reset query    java-forums.org

81. can java handle nested sub queries?    java-forums.org

SELECT tblPatientMeds.PatientMedID, (Select PossibleMedName from tblPossibleMeds where PossibleMedID = tblPatientMeds.PossibleMedID), tblPatientMeds.DateStarted, tblPatientMeds.DateStopped, tblPatientMeds.IsSuspectedMed, tblPatientMeds.PatientID, tblPatientMeds.PossibleMedID, tblPatientMeds.MedDosageID, tblPatientMeds.MedRouteID, tblPatientMeds.MedIntervalID, tblPatientMeds.MedPerscriberID , (Select DosageSize from tblPossibleMedDosage where MedDosageID= tblPatientMeds.MedDosageID), (Select MedRoute from tblPossibleMedRoute where MedRouteID= tblPatientMeds.MedRouteID) , (Select MedInterval from tblPossibleMedInterval where MedIntervalID= tblPatientMeds.MedIntervalID) , (Select Perscriber from tblPossibleMedPerscriber where MedPerscriberID= tblPatientMeds.MedPerscriberID) FROM tblPatientMeds WHERE (((tblPatientMeds.[PatientID])='7c7e811b-6e91-4f65-9735-1a40c36fd0e4'));

82. Can't seem to get a count(*) where query working    java-forums.org

I'm kind of new to this and I'm trying to check the existence of a record in my database using count(*). In MySQL the query is simply SELECT COUNT(*) FROM user WHERE username = 'name'; where 'name' is a variable set by the user's input, I just can't seem to find out how to get the result of the query stored ...

83. Query to group URLs together    java-forums.org

Depending upon what database you are using, you could query via a regular expression. However this would be quite inefficient if your database is huge. An alternative would be to create a mapping table that defines the domain name itself, mapped to each of the entries - in which case you can query that table then join across the mapping to ...

84. Query in database    java-forums.org

85. querying russian data from db problem    java-forums.org

86. Help in Query    java-forums.org

87. help me need to understand queries    java-forums.org

help me need to understand queries Hi I just have joined a company as a Junior software engineer. I was asked to analyze an App named CRM Admin Console and find out the tables and their relation. This admin console authenticates user. Now I need to build a web application named Promo Admin Console which will be similar to ...

88. Help In An Critical Query    java-forums.org

TABLE1 (TOTAL 3 COLUMNS) A B C TABLE2 (TOTAL 3 COLUMNS ) D E F DESCRIPTION : actually there were two tables and of 3 columns containing each WHAT I NEED : I need a SINGLE query in such a way that I have to get all the values of TABLE2.F(column) where { TABLE1.C(column) [where i can hardcode this column value ...

89. JDBC query output    forums.oracle.com

90. Query using multiple databases    forums.oracle.com

I'm new to the mvc framework but have a decent grasp of how to connect to a database and create data access classes with methods that query that data. But the project I'm beginning will be using 4 already created databases. Once I create the classes I need for my application environment, how do I query their objects together. All the ...

91. querying a database    forums.oracle.com

Hi all. Started a project (school) where: * jsp page via a form sends a query * a class handles the query and the connection to the database (MySQL) * the database returns the result to a class * the class creates a jsp to be displayed at the client I'm trying to separate presentation, logic and content. I can make ...

92. Java JDBC help with resulset query    forums.oracle.com

That gives me the following output... admin01 Deafault admin stock01 nameOfStock01 admin01 Default admin stock02 nameOfStock02 admin01 Default admin stock03 nameOfStock03 user01 Ben Bunny stock01 nameOfStock01 user01 Ben Bunny stock02 nameOfStock02 user02 Silly Sam stock02 nameOfStock02 user02 Silly Sam stock03 nameOfStock03 I am looking for a code that gives me output of admin01 name surname stock01 nameOfStock01 stock02 nameOfStock02 stock03 nameOfStock03 ...

93. How to query the database periodically???    forums.oracle.com

Hi, i would like to do a certain task ( like fetching the database, etc) in a particular interval time. For example, my program has to query the database in every 15 mins and display the record if any new record added in the table. Any one please help me in this and if possible, please give me a sample code. ...

94. Database Query    forums.oracle.com

95. database query problem...    forums.oracle.com

I'm not sure I understand. BREED is always a string. In the first bit of code it sucessfully gets these and prints them to the screen. In the second, it doesn't. The NAME column in the DB is designaed as a VARCHAR field (length 50) - so thats definely a string too. The AGE column is defined as an integer.

96. Querying Database    forums.oracle.com

Before I get started on creating a form for web users to query a mysql database, I was wondering if java had some sort of library that handles reporting w/ jsp? I was just going to create an HTML form, check the values of the inputs and do PreparedStatement pst = con.prepareStatement("SELECT * from table where city = user_input"); etc Then ...

97. best way to attach a Reader to a db query?    forums.oracle.com

Reading from a file is a very common operation, whereas turning a database query into a Reader is a very uncommon operation. So you should expect it would take more code to do so. I think you have the right basic idea there -- do a query and construct the output from the ResultSet -- but you're making it more complicated ...

98. Background task to execute a database query    forums.oracle.com

Hello, I have a html page where user can click on various links and each link displays some information in a small popup window. On click of each link I am running a database query which takes about 70 sec to return the results. Since the query is taking a while to execute, User will not see the information instantly. I ...

99. Db link Query in Java    forums.oracle.com

I 'm executing a sql query from Java. The sql has data from two different database and i'm using db link for the same. But my java program connects to only one database. So my program is throwing "connection description ofrm remote database not found" error. How can i change my java program which will solve this issue?

100. Query to database    forums.oracle.com