File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JDBC and the fly likes SQL and table Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "SQL and table" Watch "SQL and table" New topic
Author

SQL and table

Lao Kinsuyi
Ranch Hand

Joined: Mar 22, 2007
Posts: 30
Hi guys

I'm sorry if this is a stupid question or novice. Infact, i'm very new to SQL.
Firstly, can someone tell me what topics in SQL are relevant to a java programmer and they should know.

Secondly, how can i draw the table (database)for select,insert, upgrade in SQL by using notepad. Or can i use word programm for drawing the table to be used. Because, i read in a book that someone can only use notepad to write SQL and the table.

SCJP 1.5
Jeanne Boyarsky
author & internet detective
Marshal

Joined: May 26, 2003
Posts: 31074
    
232

Lao,
There's no such thing as a stupid question and novice questions are welcome.

1) A Java programmer should know how to write basic select queries - joins, aggregates functions, group by, etc. A Java programmer should also know how to write insert/update/delete queries. For any application with large amounts of data, it is also important to know about indexes and performance. If you have to design tables, it is good to get a book on database design and normalization. The Head First SQL book covers all of these.

2) I'm not sure what you mean by "draw the table." Are you looking for something graphical. Some databases (such as oracle) provide a more tabular view and generate the DDL (SQL for creating a table.) You can use any text editor to create DDL by hand though.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
hisham ragheb
Ranch Hand

Joined: Apr 14, 2008
Posts: 30
To use SQL then you have to read about JDBC 2.0, you have to know how to:
1-get and register a JDBC driver.
2-open a connection to your DB.
3-create statements then exequete queries or updates.
4-read your result set.

what i understood from your second question that you think that there is somthing in java that output the result of your SQL DML commands into somthing graphical..actally the SELECT statement return somthing very similar to tables as object instance where you extract field data from but drawing tables is related to grapghical API's(eg..swing,awt)


SCJP 1.5 (94%), SCWCD 1.4 (91%), SCBCD 1.5 (95%)
Lao Kinsuyi
Ranch Hand

Joined: Mar 22, 2007
Posts: 30
Thank you guys.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: SQL and table