If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > insert problem

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 01-22-11, 11:16
shivarocks shivarocks is offline
Registered User
 
Join Date: Jan 2011
Posts: 5
Unhappy insert problem

hello friends,
i am new to db2 and i have a project to do in db2 so first i created a database and a table but when i need to insert data into that it is showing sql error code 7,
this is my table

CREATE TABLE SHIVA.USR_JOBSEEKER (
ID BIGINT GENERATED ALWAYS AS IDENTITY (START WITH 1 INCREMENT BY 1),
USERNAME VARCHAR(25) NOT NULL UNIQUE,
EMAIL VARCHAR(45) NOT NULL UNIQUE,
PASSWORD VARCHAR(45) NOT NULL,
FULLNAME VARCHAR(25),
DOB DATE,
GENDER VARCHAR(50),
LOCATION VARCHAR(45),
MOBILE BIGINT NOT NULL,
EXP_YRS VARCHAR(25),
EXP_MNTS VARCHAR(25),
CURR_SAL VARCHAR(25),
EDU_DET VARCHAR(25),
SKILLS LONG VARCHAR,
FUNC_AREA LONG VARCHAR,
RESUME_TIT VARCHAR(75),
RES_PASTE VARCHAR(300),
DATE DATE,
ALERTS VARCHAR(5),
STATUS VARCHAR(3) NOT NULL DEFAULT 0
)




and this is my inserting code


INSERT INTO SHIVA.USR_JOBSEEKER(USERNAME,EMAIL,PASSWORD) VALUES('SHIVA','SJSUS','DFHF')


is there any mistake in syntax or cant we send data to only particular fields or what is the prob i cant understand please help me!!!
i use ems sql manager is there any problem with that and my db2 works very slow even to execute create table and insert one row from table!!!
can some one help me regarding that..
thank u!!!

Last edited by shivarocks; 01-22-11 at 11:21.
Reply With Quote
  #2 (permalink)  
Old 01-22-11, 11:49
tonkuma tonkuma is online now
Registered User
 
Join Date: Feb 2008
Location: Japan
Posts: 2,195
Mobile bigint not null,
Reply With Quote
  #3 (permalink)  
Old 01-22-11, 22:42
shivarocks shivarocks is offline
Registered User
 
Join Date: Jan 2011
Posts: 5
thank friend so i must remove not null in mobile...thanks friend...but how to make db2 work faster???
Reply With Quote
  #4 (permalink)  
Old 01-24-11, 09:56
stolze stolze is offline
Registered User
 
Join Date: Jan 2007
Location: Jena, Germany
Posts: 2,662
You could tune the system and applications.
__________________
Knut Stolze
IBM DB2 Analytics Accelerator
IBM Germany Research & Development
Reply With Quote
  #5 (permalink)  
Old 01-25-11, 09:10
Mathew_paul Mathew_paul is offline
Registered User
 
Join Date: Oct 2007
Posts: 200
you could use append on if u don't have cluster index on it

regds
paul
Reply With Quote
Reply

Tags
db2

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On