How to create multiple tables with SQL commands
865380May 30 2011 — edited May 30 2011Hi, First of all, is it possible to create more then one table at a time with SQL commands?
because I tried to do this in the following way
Example:
CREATE TABLE "HB_Product" (
"productId" NUMBER(4) NOT NULL,
"productName" VARCHAR2(20) NOT NULL,
"prodPricePerTon" NUMBER(10,2),
CONSTRAINT "HB_Product_PK" PRIMARY KEY ("productId")
)
/
CREATE TABLE "HB_Operations" (
"orderNo" NUMBER(5) NOT NULL,
"lineNo" NUMBER(4) NOT NULL,
"billNo" NUMBER(10) NOT NULL,
"actions" VARCHAR2(15),
"place" VARCHAR2(15),
"actDate" DATE NOT NULL,
"totWeight" NUMBER(6,3),
CONSTRAINT "HB_Operations_PK" PRIMARY KEY ("lineNo")
)
/
I copied some of the syntax from the object browser table creation, but I preffer to use my own sql.
This gives me a "Missing or invalid option" error.
Can someone explain me how to do it correctly, or why it's not possible?
Best Regards Stan!