This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes JDBC and the fly likes Create statement Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Create statement" Watch "Create statement" New topic
Author

Create statement

Candy Bortniker
Ranch Hand

Joined: Mar 17, 2003
Posts: 123
I am trying to create a table with several columns. I would like to not put all of the column names on one line because you would have to scroll over to see the full line. Can I do something like:
"CREATE TABLE Reimbursement (GroupAcctNumber VARCHAR(10),
SSN VARCHAR(9), name VARCHAR(20),
date VARCHAR(10), providerSSN(9),
providerName(20) amount float(7),
description VARCHAR(45))"
Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15299
    
    6

Are you trying to do this in JAVA Code? This is basically a String concantanation issue. When creating a String in JAVA and spreading it out over multiple lines a + operator must be used. So your statement would be more like:

[ October 18, 2003: Message edited by: Gregg Bolinger ]

GenRocket - Experts at Building Test Data
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Create statement
 
Similar Threads
sequence generator with mysql
Hypersonic DB question
@JoinTable or @JoinCol...
Create table error
SQL Error