Questions on creating a table.

Hello,
I would like to ask you guys on how do i create a table after getting the user to input 2 values.
Example : Enter the table size : 3 3
and the program will create a table of column of 3 and row of 3.
I'm current stuck at getting the the program to accept the inputs and translate it into table as i only know how to create a table of fixed column and rows.
Any advice?

Are you talking about AWT, Swing, SWT, console output?
And how do you create tables of fixed size? Like, 1. Or 2. Do both, check what has changed, try to add the difference in a loop.

Similar Messages

  • Question about creating new tables using SQL script in WebLogic Server

    Hi,
    I am new to WebLogic and I am following a book Java EE Development with Eclipse published by PACKT Publishing to learn
    Java EE.  I have installed Oracle Enterprise Pack for Eclipse on the PC and I am able to log into the WebLogic Server Administration Console
    and set up a Data Source.  However the next step is to create tables for the database.  The book says that the tables can be created using
    SQL script run from the SQL command line.
    I cannot see any way of inputting SQL script into the WebLogic Server Admistration Console.  Aslo there is no SQL Command line in DOS.
    Thanks  for your help.
    Brian.

    Sounds like you are to run the scripts provided by a tutorial to create the tables, right?  In that case, you may need to install an Oracle client to connect to your database.  The client is automatically installed with the database, so if you have access to the server that hosts the database, you should be able to run SQLplus from there.
    As far as I know, there is no way to run a script from the Admin Console.  I could be wrong, however.

  • Question on Creating table from another table and copying the partition str

    Dear All,
    I want to know whether is there any way where we can create a table using another table and have the partitions of the new table to be exactly like the used table.
    Like
    CREATE TABLE TEST AS SELECT * FROM TEMP;
    The table TEMP is having range and hash partitions.
    Is there any way when we use the above command, we get the table partitions of TEMP to be copied to the new table TEST.
    Appreciate your suggestions on this one.
    Thanks,
    Madhu K.

    may this answer your question...
    http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:595568200346856483
    Ravi Kumar

  • Question on Creating Table From Insert statement

    Hi,
    I want to create a table using a DBlink from another database using the create/insert statement. Will it also transfer the constraints or do I have to do it manually afterwards? Thanks.
    Create table T1
    SELECT a,b,c from T2 from DB@dblink;

    As discussed above, the constraints, indexes, triggers are not copied. Only NOT NULL constraints are copied.
    Look at this thread Re: Copying table structure.
    for copying triggers/indexes from source table to destination table.
    Thanks,
    Navaneeth

  • Newbie Question - Creating a table layout in a report

    Post Author: TomBrowning
    CA Forum: General
    (Crystal Reports Version XI 11.0.0.2495 )
    Hi,
    I have created a table/grid in the report details section by using the "Outside Borders" tool to surround the report fields then moved them around in order to join them to each other in a row.  This appears to show the data as if in a table/grid when viewed in preview; this is also fine when I print the report out.  However if I export to a PDF using the "Export Report" tool; the table is displayed with white space between the rows, breaking the table up.
    I'm sure there must be a better way of creating a table that would get around this problem and I just can't see it for looking?
    Thanks for your help
    Tom

    Post Author: pandabear
    CA Forum: General
    Hey Tom,
        Try rt clicking on "Details"/"Section Expert" and click on "Format Multiple Columns". 
    Keep the boxes you made around the fields as they'll be duplicated too.  Play around with
    it and look at the help files.
    Hope this helps,
    The Panda 

  • Dynamic SQL and GRANT CREATE ANY TABLE

    hi gurus,
    i have a dynamic SQL in a procedure where a table will be created from an existing table without data.
    strSQL:='create table ' || strTemp || ' as select * from ' || strArc || ' where 1=2';
    execute immediate strSQL;
    without GRANT CREATE ANY TABLE for the user, *"ORA-01031: insufficient privileges"* error during execution.
    Is there a way to tackle this issue without providing GRANT CREATE ANY TABLE privilige?
    many thanks,
    Charles

    ravikumar.sv wrote:
    The problem is not because of dynamic sql...It probably has something to do with dynamic SQL or, more accurately, dynamic SQL within a stored procedure.
    From a SQL*Plus command prompt, you can create a table if your account has the CREATE TABLE privilege either granted directly to it or granted to a role that has been granted to your account. Most people probably have the CREATE TABLE privilege through a role (hopefully a custom "developer role" that has whatever privileges you grant to users that will own objects but potentially through the default RESOURCE role). That is not sufficient to create tables dynamically via a definer's rights stored procedure. Only privileges that are granted directly to the user, not those granted via a role, are visible in that case.
    I expect that the DBAs are granting the CREATE ANY TABLE privilege directly to the account in question rather than through whatever role(s) are being used which is why that appears to solve the problem.
    Justin

  • How can i create a table which name is dynamic and not static?

    i have a question to ask. normaly if i want to create a table, i must provid a name for the table. for example, create table tt (id number(5)). But now in my application, I need to control the table name with params through function, how can i do?
    thx

    First thank you to reply so fast!
    But I met problem according to your instructive. The following is my code:
    declare
    m varchar(5);
    begin
    m:='hello';
    execute immediate 'create table'|| m ||'(id number(5),name varchar(5))';
    commit;
    end;
    The SQL*Plus tell me the command create is invalid. My oracle is 8.1.7.0.0. Maybe I miss something so that I can not get correct result. Wish your further help.
    yours sincerely
    zhou jinguang

  • How can I create a Table View in Cocoa Applescript?

    This is my last resort. I've searched for days and only found tutorials for iPhone and Cocoa, and I have no idea where to start. I'm looking for a way to create a Table View, and fill it with a few cells that call a handler when clicked. I've looked through the Xcode help, the Apple documentation, and countless tutorials, and I don't know what to do. I'm sure what I'm asking is possible, because usually what is possible in Cocoa is possible in Cocoa-Applescript.
    Perhaps something like:
    myTableView's addCell_OfType_WithHandler("This is a text cell", text, "myHandler:")
    I would appretiate any responses and brief descriptions on the matter.

    You did not answer my first question, which was not an idle question. I'll answer here, but if cross-chatter appears in a different thread I'll ignore it. You'll have to keep track of the mess yourself.
    Apple_For_The_Win wrote:
    At this point, I've dragged a Table View onto my window, in Xcode. I've connected it to the value "myTableView", and that's where I need help. I'm specifically trying to add cells into the table view.
    I'll assume that 'connected it to the value "myTableView"' means that you've control-dragged in XCode from the table view in Main Menu.xib to a property in your applescript app delegate called myTableView. If that's not the case, please correct me.
    I prefer to use an array controller for this, so please drag an array controller object into main menu.nib. once you've done that, do the following:
    open the applescript app delegate and add a new property called "tableController"
    select the table view in the object list (you may need to open some disclosure triangles to reach it). and add appropriate (an) column name(s). you can hide column titles later if you like, but having named columns makes life easier.
    select the array controller in the object list
    rename the array controller "table data"
    open the attributes inspector, and then add the column name(s) as key(s) in the object controller area
    open the bindings inspector, and where it says "controller content", open the disclosure arrow and bind the content to the App Delegate object on the model key path self.tableController
    select the table view in the object list again, then go down a level and select each column in turn
    for each column, open the bindings inspector, and where it says "value", open the disclosure arrow and bind the content to the Table Data object with the controller key arrangedObjects model key path being the name of the column (which is the name of the key in the controller as well)
    back in the applescript app delegate, add code like the following:
      -- create a list of records, where each record represents a row and the column name is the record key
      set myData to {{column_1_name:"hello"}}
      -- convert it to an NSArray and add it to the controller content. don't forget the *my* keyword, or it won't work
      set my tableController to NSArray's arrayWithArray:myData
      -- may or may not be needed
      myTableView's reloadData()
    That should populate the table with simple text. if you want something more complicated (like buttons or links) then create the more complicated elements separately and add them to the data.

  • How Do I Create A Table?

    I will admi9t that I am the newest of "newbies" to SQL Server so I pose the basic question : How Do I Create A Table in SQL Server? I read in a book fairly recently how to do this but have forgotten.
    Steve R. Burrus

    "SQL Server 2008 supports the creation of tables using T-SQL, the SQL Server
    Management Studio (SSMS) Object Explorer and the SSMS Database Diagram Editor. Regardless of the tool you choose, creating a table involves naming the table, defining the columns, and assigning properties to the columns. The visual tools (such
    as Object Explorer and database diagrams) are usually the best starting point for creating tables.
    Using Object Explorer to Create Tables
    The Object Explorer in SSMS has a Tables node under each database listed. You can add tables via the Object Explorer by right-clicking this Tables node. As shown below the
    New Table option displayed after you right-click the Tables node in Object Explorer. The top-right side of the screen shown in bleow.it is the table creation screen that allows you to enter the column name and data type and to set the Allow
    Nulls option.
    The data entry area under Column Name is a free-form area where you can define a column name. You can select the data type from the Data Type drop-down, which displays
    the data types available with SQL Server. The Allow Nulls option is Boolean in nature and is either checked or not checked. For each column selected, a Column Properties section is displayed in SSMS, providing a myriad of additional properties that you can
    assign to each column.
    Using T-SQL to Create Tables
    Ultimately, all the tables created with the visual tools can also be created by using T-SQL. As with many of the SSMS tools, database objects can be resolved or scripted into T-SQL statements.
    Let’s examine the T-SQL syntax to better understand some of the table creation options. so let's create a Table name
    test.Customer which has a 5 columns of CustomerID, LastName, FirstName, CreditLine, and CreationDate. so when you execute the bottom code you will have the table. 
    --START with USE command to tell the sql server which database you want to create the table on, this case we want to create the table on Adventurework2008 (it’s a Sample database)"
    USE
    Adventurework2008
    CREATETABLE test.Customer
    (CustomerID
    INT IDENTITY(1,1),
    LastName
    VARCHAR(50)
    NOT NULL,
    FirstName
    VARCHAR(50)
    NOT NULL,
    CreditLine
    MONEY SPARSE NULL,
    CreationDate
    DATE NOT
    NULL)
    GO
    I hope this helps answering your question more or less. Goodluck
    Reference-book:
    Microsoft® SQL Server 2008 R2 UNLEASHED Ray Rankins Paul Bertucci Chris Gallelli Alex T. Silverstein

  • Can I create a table in a procedure submitted to job queue?

    I have created a package (with AUTHID CURRENT_USER) where some of the procedures create temporary tables to facilitate processing. These procedures run just fine when executed directly from within an anonymous block at the SQL*PLUS level. However, when I submit the procedures to the job queue (via DBMS_JOB.SUBMIT), the job is submitted successfully but fails when run. Investigating the Alert Log shows an error of insufficient privilege on the CREATE TABLE command in the procedure.
    QUESTION:
    Can I create a table from a procedure running in the Job Queue? If so, then how to get it to work? Does the job run in a different environment that needs Create Table privileges set to my schema?
    Thanks for any info you can provide.
    John

    FYI: Found the problem. In the Administrator's Guide (of course not in the supplied packages documentation about DBMS_JOB) I found:
    "How Jobs Execute
    SNP background processes execute jobs. To execute a job, the process creates a session to run the job.
    When an SNP process runs a job, the job is run in the same environment in which it was submitted and with the owner's default privileges.
    When you force a job to run using the procedure DBMS_JOB.RUN, the job is run by your user process. When your user process runs a job, it is run with your default privileges only. Privileges granted to you through roles are unavailable."
    And of course we had set up our users to get all privileges through Roles, so CREATE TABLE wasn't one of my DEFAULT PRIVILEGES!
    It sure would be nice if Oracle documentation could get its act together and provide ALL information about a topic in a logical place. The effort to find the information about privileges occurred after it took me 1/2 hour to figure out why my submissions were failing - I didn't have the ';' included in the quoted string for the procedure to be called - which I only figured out after looking at the code for DBMS_JOB where it made the note to make sure you include the ';'. Wouldn't it be good to have that MINOR DETAIL mentioned in the description of DBMS_JOB.SUBMIT?????

  • How to create a table with more tan 20 columns

    I created a A4 landscape document to make a calendar for the next year.
    To add the date information I need to insert a table with 32 columns (name of month + 31 days). It should be possible to create a table with a over all width of 29.7 cm (consisting of 1 column of 4.9 cm and 31 columns with 0.8 cm)?
    Remark: Yet reduced all indention's (? German: Einzug) and other spacers and the size of used font of the table.

    Hello Till,
    unfortunatly Pages connot create a table with more than 20 columns. This is no question of size or place.
    But you can create two tables, set the most right border of the fist table to "no line" and align the second table (with the other 12 columns) at the right side of the first table. Now you have "one" table with 32 columns.
    I have done this with my driving book (Fahrtenbuch, um es korrekt zu schreiben and it works fine.
    Frank.

  • How to create a table with datatype blob and insert a pdf file (ravi)

    how to create a table with datatype blob and insert a pdf file,
    give me the explain asap
    1.create the table?
    2.insert the pdffiles into tables?
    3.how to view the files?
    Thanks & Regards
    ravikumar.k
    Edited by: 895044 on Dec 5, 2011 2:55 AM

    895044 wrote:
    how to create a table with datatype blob and insert a pdf file,
    give me the explain asapPerhaps you should read...
    {message:id=9360002}
    especially point 2.
    We're not just sitting here waiting to answer your question as quickly as possible for you.

  • Need help in Creating External Tables

    Hi All,
    I have a flat file containing numberic data, CLOB data, and also date columns data. I have to load this flat file data into staging server table using External tables. I have to write a stored procedure in such way creating exteranl tables dynamically. My question or need help from you people is that how to define the external table to load the CLOB data from flat file.
    Thanks,
    Sankar

    The LOCATION clause of an external table specifies the file or files to be read when the table is queried. You can change it to refer to different files without dropping and recreating the table and invalidating all dependent code.
    Regarding DBMS_SQL, yes you can do it the hard way if you prefer.
    Good point about CLOB columns in external tables. Quite possibly they are not supported, but I would have to check the manuals and try some examples.

  • I have created a table on pages.  Somehow I have set something so a blue dot appears every time I press he space bar.  How did I do it? and how do I get rid of it?

    two questions-- I have created a table on pages.  Somehow every time I press the space bar, I get a blue dot between words--How did I do it? and How do I get rid of it.  Also, I created a template on pages--How do I "save as" for a new file using that template?

    All you are seeing is the word space (from the spacebar).
    Menu > View > Hide Invisibles you had Show Invisibles on.
    When you are using a template it should be named "Untitled" and it will ask you to save when you go to close or you simply go to Save under the File menu.
    Peter

  • How to create a table dynamically in webdynpro

    hai everybody
    in webdynpro we know how to create at design time
    but i want to create it at runtime that is dynmamically i want to set the rows and coloums of the table at run time
    Thanks & Regards
    sravan

    I guess this should work,
    Suppose you want to dynamically create a Table (say Category) having a column called Category Code, then in the wdDoModifyView() hook method, just add the following code snippet,
    if (firstTime) {
    //Create the Table UI Element
    IWDTable table = (IWDTable) view.createElement(IWDTable.class, null);
    //Set the Table Header
    IWDCaption tableCaption = (IWDCaption) view.createElement(IWDCaption.class, null);
    tableCaption.setText("Category Table Contents");
    table.setHeader(tableCaption);
    //Create and add a Column UI element for the above table     
    IWDTableColumn column = (IWDTableColumn) view.createElement(IWDTableColumn.class, null);
    table.addColumn(column);
    //Set the required column header using the caption (Category Code here)                         
    IWDCaption caption = (IWDCaption) view.createElement(IWDCaption.class, null);
    caption.setText("Category Code");
    column.setHeader(caption);
    //Create a TableCellEditor and bind it to an attribute of the Category Node in the context     
    IWDTextView editor = (IWDTextView) view.createElement(IWDTextView.class, null);
    editor.bindText("tb_Category.cat_code");
    column.setTableCellEditor(editor);
    //Finally add the Table UI element to the view          
    IWDUIElementContainer root = (IWDUIElementContainer) view.getRootElement();
    root.addChild(table);
    You need to follow the same procedure for adding multiple columns to the table.
    Hope this answers your question!
    Regards
    Kishan

Maybe you are looking for

  • White box around images

    I'm using FCE 4. I've setup a moving map sequence (such as world map, point A to point B, with moving line) the sequence has taken me four pics to get it done using my crop tool. Sometimes when I playback, the world map has a transparency of black ar

  • IPod nano skipping song

    Hi all. I downloaded a song from the itunes music store and uploaded it it my nano (1gb), after about 16-19 seconds, it will skip to the next song. I have checked the settings for it on itunes, tried the 5 r's and taken it out from the library and ad

  • Release date colum

    Is the release date a function of Itunes or is it in the ID3 tag somewhere? I have several Podcasts (.mp3format) that I would like to import into Itunes, and they are organized by "release date". How do I add this to my file ID3 tags

  • Demonstrate Load Balancing

    Hi All, We are in the process of testing a new software load balancer on top of Oracle E Business Suite R12.1.3. The configurations are done and from the load balancer software itself we can see the requests are forwarded to different application ser

  • I cant install adobe application manager

    Today I got my monthly income creative cloud and I can not install the Adobe Application Manager to download and launch applications. Error downloading. I have an operating system OSX 10.8.2