Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7693945
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T21:12:21+00:00 2026-05-31T21:12:21+00:00

I created a table without a primary key Like this: private static final String

  • 0

I created a table without a primary key

Like this:

private static final String SCRIPT_CREATE_DATABASE =
      "create table " + MYDATABASE_TABLE + " ("
      + KEY_ID + " INT, "
      + KEY_CONTENT1 + " , "
      + KEY_CONTENT2 + " , " + KEY_CONTENT3 +" date, " + KEY_CONTENT4 +
      " , " + KEY_CONTENT5 +
      " , " + KEY_CONTENT6 +
      " , " + KEY_CONTENT7 +
      " , " + KEY_CONTENT8 +
      " , " + KEY_CONTENT9 +
      " , " + KEY_CONTENT10 +
      " , " + KEY_CONTENT11 +
      " , " + KEY_CONTENT12 +
      " , " + KEY_CONTENT13 +
     ");";

But i want to update the row KEY_ID should have primary key,where table has been created without primary key,can i able to update the table?,Please help.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T21:12:22+00:00Added an answer on May 31, 2026 at 9:12 pm

    declare column KEY_ID as Primary key

    private static final String SCRIPT_CREATE_DATABASE =
      "create table " + MYDATABASE_TABLE + " ("
      + KEY_ID + "integer primary key, "
      + KEY_CONTENT1 + " , "
      + KEY_CONTENT2 + " , " + KEY_CONTENT3 +" date, " + KEY_CONTENT4 +
      " , " + KEY_CONTENT5 +
      " , " + KEY_CONTENT6 +
      " , " + KEY_CONTENT7 +
      " , " + KEY_CONTENT8 +
      " , " + KEY_CONTENT9 +
      " , " + KEY_CONTENT10 +
      " , " + KEY_CONTENT11 +
      " , " + KEY_CONTENT12 +
      " , " + KEY_CONTENT13 +
     ");";
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I created a table then added a foreign key reference to its primary key
I created a table tbl_Candidate , but I forgot to set the primary key
I would like to create a table that has both a column for created
I'm having problems trying to get a query like this table answers CREATE TABLE
I have a MySQL table like this: CREATE TABLE categories ( ID INT NOT
So I have a table like this: create table `test` ( `testId` int(11) not
We have a DB like this: CREATE TABLE `jobs` ( `id` int NOT NULL
I have the following table of counters: CREATE TABLE cache ( key text PRIMARY
I have a SQlite3 table that has typeless columns like in this example: CREATE
I created a table with this schema using sqlite3: CREATE TABLE monitored_files (file_id INTEGER

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.