Copy a table in Access structure only with CF query

Ask a Question related to Coldfusion Database Access, Design and Development.

  1. #1

    Default Copy a table in Access structure only with CF query

    Hello,
    I need to know how to create a new table by copying an existing table with the
    table structure only in a query

    Don't know the Syntax but

    CREATE newtable FROM oldtable ( structure only )

    Is there a way to do this in a query?

    Thanks in advance



    jimWPX Guest

  2. Similar Questions and Discussions

    1. Class::Struct - want to access structure within structure
      I want to access a structure within a structure. Below is what I had in mind. Please help. #!/perl/bin/perl use Class::Struct; struct Step...
    2. Query w/bad table structure
      Hi, I am trying to query a column that has multiple values. When I export it, I need to have it so that each of those values is placed in its own...
    3. adding a hyperlink to a field in a table created from a d/b query (Access)
      I've done this using Frontpage; and I know I've done it in the past using just ASP. I'm trying to stay away from FP on this site, so.... Can...
    4. ASP / Access: use of same table twice in one query
      Hi, In a query I use the same table twice: Select u.*, ud.*, dep.*, u2.* from users as u, departments as dep, user_in_departments as ud, users...
    5. query to return table structure
      hi, Is there any command or query that returns the table structure informix.
  3. #2

    Default Re: Copy a table in Access structure only with CF query

    You mean without knowing the old table's structure?
    Dan Bracuk Guest

  4. #3

    Default Re: Copy a table in Access structure only with CF query

    I actually worked it out. It may not be the right answer but it works

    <cfquery datasource="#application.db#">
    Select * Into admin_pass2 From admin_pass
    </cfquery>

    This makes a copy

    <cfquery datasource="#application.db#">
    Delete * FROM admin_pass2
    </cfquery>

    This empties it

    jimWPX Guest

  5. #4

    Default Re: Copy a table in Access structure only with CF query

    jimWPX wrote:
    > I actually worked it out. It may not be the right answer but it works
    >
    > <cfquery datasource="#application.db#">
    > Select * Into admin_pass2 From admin_pass
    > </cfquery>
    >
    > This makes a copy
    >
    > <cfquery datasource="#application.db#">
    > Delete * FROM admin_pass2
    > </cfquery>
    And if you want to do it in one statement:

    SELECT *
    INTO admin_pass2
    FROM admin_pass
    WHERE 0 = 1

    Jochem

    --
    Jochem van Dieten
    Adobe Community Expert for ColdFusion
    Jochem van Dieten **AdobeCommunityExpert** Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139