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 8405949
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T22:57:51+00:00 2026-06-09T22:57:51+00:00

I have made three tables: CREATE TABLE country_ ( id_country int NOT NULL IDENTITY(219,1),

  • 0

I have made three tables:

    CREATE TABLE country_ (
    id_country  int NOT NULL IDENTITY(219,1),
    oid int NOT NULL,
    country_name_ru varchar(50) NOT NULL,
    country_name_en varchar(50) NOT NULL, 
    PRIMARY KEY  (id_country) 
  ) 


    CREATE TABLE region_ (
    id_region int NOT NULL IDENTITY(1612,1),
    id_country int NOT NULL FOREIGN KEY REFERENCES country_(id_country),
    oid int  NOT NULL,
    region_name_ru varchar(255) NOT NULL,
    region_name_en varchar(255) NOT NULL,
    PRIMARY KEY  (id_region) 
 ) 

    CREATE TABLE city_ (
    id_city int NOT NULL  IDENTITY(17590,1),
    id_region int NOT NULL FOREIGN KEY REFERENCES region_(id_region),
    id_country int NOT NULL FOREIGN KEY REFERENCES country_(id_country),
    oid int NOT NULL,
    city_name_ru varchar(255) NOT NULL,
    city_name_en varchar(255) NOT NULL,
    PRIMARY KEY  (id_city) 
 ) 

Then I tried to fill them:

    SET IDENTITY_INSERT country_  ON

    INSERT INTO country_  ( id_country,oid,country_name_ru,country_name_en) VALUES       (1,   3159, 'Россия', 'Russia');

    SET IDENTITY_INSERT country_  OF

In such way I filled region_ and city_ tables, but I have three errors:

wrong syntax near keyword “OF”.

Any ideas?

  • 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-06-09T22:57:53+00:00Added an answer on June 9, 2026 at 10:57 pm

    its off

    SET IDENTITY_INSERT country_  OFF
    

    you can read about this statement here

    as you can see, the syntax includes OFF

    SET IDENTITY_INSERT [ database. [ owner. ] ] { table } { ON | OFF }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have two tables: CREATE TABLE InmarsatZenith.dbo.ClientJob (JobRef int PRIMARY KEY NOT NULL, IntRef
I have the following structure: CREATE TABLE IF NOT EXISTS `myTable` ( `ID` int(11)
I have a problem with my self-made search page. There is 2 tables: **name
I have three basic tables: tblUsers: usrID usrFirst usrLast 1 John Smith 2 Bill
I have three tables. Let's call them a, b, and a_to_b. a_to_b contains (among
I was looking on SO about create tables only if they do not exist
I have a three tables Results: TestID TestCode Value Tests: TestID TestType SysCodeID SystemCodes
Suppose I have a table in my database that is made up of the
I have three tables set up in a MySQL database called event, status and
So what I currently have is my tables in SQL, with table connecting different

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.