473,473 Members | 1,758 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

how can write requete between in preparedstatement

132 New Member
Hello,

i want to write this requete:
PreparedStatement st=c.prepareStatement("SELECT a,b,c FROM table WHERE (a BETWEEN "+?+" and "+?+"+10) AND (b BETWEEN "+?+" and "+?+"+ 10) LIMIT 5 ");
in preparedstatement but signe error why can any tell what can write


thanks
Nov 24 '09 #1
1 2270
Dököll
2,364 Recognized Expert Top Contributor
I am not sure what you are asking manjava...

What are you hoping to do?
Nov 25 '09 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Dani | last post by:
Hi everyone Description of the problem: Using a PreparedStatement to write down an integer (int) plus a timestamp for testing purposes. When read out again the integer looks very different. We...
5
by: Dov Moryusef | last post by:
Hi to all, I’ve a table with an idendity column : CREATE TABLE USRDB2.MYTABLE ( "ID" INTEGER NOT NULL GENERATED ALWAYS AS IDENTITY (START WITH 0, INCREMENT BY 1, NO CACHE), "CODE"...
6
by: Markus | last post by:
In my Java-application I create an PreparedStatement like this: PreparedStatement v_stmt = dbcon.prepareStatement("SELECT * FROM mytable WHERE UPPER(userID) LIKE UPPER(?)"); v_stmt.setString(1,...
2
by: Peter Knowfield | last post by:
Bonjour ŕ tous, Je développe une base traitant des candidatures pour des jobs. J'ai créer des requetes me donnant des listings d'individus selon des critčres, et je désire pouvoir accéder...
2
by: Mickael Jouvin | last post by:
Hello, I have a problem with my test of requete (if rsTbl("Nom_produit") = null then %> <option value="1"> "Aucune réponse ne correspond ŕ la requete" </option>) and i don' know why ? ...
3
by: info | last post by:
Hallo zusammnen, ich möchte einen VARBINARY-Wert aus einer Tabelle auslesen, diesen in einer Datei speichern und später wieder in eine Tabelle einfügen. Den Wert hole ich mit einem Select und...
1
by: ptkumar | last post by:
Hi All, I am facing one problem, i fetch the record from database using preparedstatement. The resultset contains morethan 300000 records. it got OutOfMemoryError. Plz any body can help me.
6
by: redashley40 | last post by:
This is my first attempt in SQL and PreparedStatement I have add the PreparedStatement and I'm not to sure if I'm doing it correctly. When I do a test run on Choose 1 ,or 2 I get this error. Error...
1
by: banging | last post by:
Hi there, I have a question regarding locking of tables so that when two or more people try to write or update the mysql tables, it locks up. Basically I only want one person to write to the...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.