Search...
FAQs
Subscribe
Pie
FAQs
Recent topics
Flagged topics
Hot topics
Best topics
Search...
Search within JDBC and Relational Databases
Search Coderanch
Advance search
Google search
Register / Login
Forums
Register
Login
Databases
»
JDBC and Relational Databases
if else in query
Pranav Sharma
,
Ranch Hand
Aug 17, 2006 18:13:00
(0 cow)
(0 skulls)
+Pie
Number of slices to send:
Send
i need to write a query which does the following.
SELECT table1.*, <A_VARIABLE> FROM table1, table2 WHERE table1.column="some character" AND ( <A_VARIABLE> = 'Y', if atleast one row exists in table2 with table2.column="something" [I]else[/I] <A_VARIABLE>='N')
Is this possible
Richard Green
,
Ranch Hand
Aug 17, 2006 19:15:00
(0 cow)
(0 skulls)
+Pie
Number of slices to send:
Send
http://www.devx.com/tips/Tip/15633
Post by:
autobot
But how did the elephant get like that? What did you do? I think all we can do now is read this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
reply
This thread has been viewed 1267 times.
Similar Threads
Help required for hibernate query (HQL) calling stored procedure
Help required for hibernate query (HQL) calling stored procedure
Question of using SqlResultSetMapping
Query help
Hibernate: Different Join in Save() and Get()
More...
All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 02:28:02
.