Click here to Skip to main content
15,925,440 members
Home / Discussions / Database
   

Database

 
AnswerRe: accessing sql server 2000 databse in LAN Pin
Colin Angus Mackay19-Dec-06 0:21
Colin Angus Mackay19-Dec-06 0:21 
GeneralRe: accessing sql server 2000 databse in LAN Pin
abhijitw19-Dec-06 17:48
abhijitw19-Dec-06 17:48 
GeneralRe: accessing sql server 2000 databse in LAN Pin
Paul Conrad19-Dec-06 19:15
professionalPaul Conrad19-Dec-06 19:15 
GeneralRe: accessing sql server 2000 databse in LAN Pin
AmirAlilou8-Jan-07 0:03
AmirAlilou8-Jan-07 0:03 
QuestionHOw can I link foxpro tables from MS SQL Server 2000 Pin
Guru_yogi18-Dec-06 19:59
Guru_yogi18-Dec-06 19:59 
AnswerRe: HOw can I link foxpro tables from MS SQL Server 2000 Pin
Steven J Jowett19-Dec-06 5:26
Steven J Jowett19-Dec-06 5:26 
GeneralRe: HOw can I link foxpro tables from MS SQL Server 2000 Pin
Guru_yogi19-Dec-06 18:48
Guru_yogi19-Dec-06 18:48 
QuestionIndexes on views Pin
karam chandrabose18-Dec-06 18:15
karam chandrabose18-Dec-06 18:15 
AnswerRe: Indexes on views Pin
Pete O'Hanlon19-Dec-06 0:30
mvePete O'Hanlon19-Dec-06 0:30 
QuestionUPDATE Query Error Pin
Expert Coming18-Dec-06 14:15
Expert Coming18-Dec-06 14:15 
AnswerRe: UPDATE Query Error Pin
Colin Angus Mackay18-Dec-06 22:39
Colin Angus Mackay18-Dec-06 22:39 
GeneralRe: UPDATE Query Error Pin
Paul Conrad19-Dec-06 5:55
professionalPaul Conrad19-Dec-06 5:55 
AnswerRe: UPDATE Query Error Pin
Pete O'Hanlon19-Dec-06 0:27
mvePete O'Hanlon19-Dec-06 0:27 
GeneralRe: UPDATE Query Error Pin
Expert Coming19-Dec-06 11:16
Expert Coming19-Dec-06 11:16 
Question[Message Deleted] Pin
R_L_H18-Dec-06 10:30
R_L_H18-Dec-06 10:30 
AnswerRe: Getting SQL Server Express CREATE DATABASE directory Pin
Colin Angus Mackay18-Dec-06 13:00
Colin Angus Mackay18-Dec-06 13:00 
QuestionDeleting DataRows Pin
Karma3125118-Dec-06 8:04
Karma3125118-Dec-06 8:04 
AnswerRe: Deleting DataRows Pin
Colin Angus Mackay18-Dec-06 12:57
Colin Angus Mackay18-Dec-06 12:57 
GeneralRe: Deleting DataRows Pin
Paul Conrad18-Dec-06 13:14
professionalPaul Conrad18-Dec-06 13:14 
QuestionTricky question ob querys, how to solve ??? Pin
karam chandrabose18-Dec-06 6:30
karam chandrabose18-Dec-06 6:30 
AnswerRe: Tricky question ob querys, how to solve ??? Pin
Karma3125118-Dec-06 8:17
Karma3125118-Dec-06 8:17 
GeneralRe: Tricky question ob querys, how to solve ??? Pin
Colin Angus Mackay18-Dec-06 12:56
Colin Angus Mackay18-Dec-06 12:56 
AnswerRe: Tricky question ob querys, how to solve ??? Pin
Pete O'Hanlon18-Dec-06 8:45
mvePete O'Hanlon18-Dec-06 8:45 
GeneralRe: Tricky question ob querys, how to solve ??? Pin
karam chandrabose18-Dec-06 17:56
karam chandrabose18-Dec-06 17:56 
QuestionPlease Help me :( Pin
Dayekh18-Dec-06 5:45
Dayekh18-Dec-06 5:45 
Hi,

2 tables. User table and Request Table. Request table has a foriegn key in the Request table called AssignedToID.

I would like to store a Request record without specifying the AssignedToID. I am receiving the following error:

INSERT statement conflicted with COLUMN FOREIGN KEY constraint 'FK_tblRequest_tblUser1'. The conflict occurred in database 'PMSystem', table 'tblUser', column 'inUserID'.

The input for AssignedToID is a Dropdown List. Here's how it is bound:

lst2.Text = "None"<br />
lst2.Value = 0<br />
lst2.Selected = True<br />
<br />
sQueryDDL = "SELECT tblUser.inUserID, tblUser.vchSurname + ', ' + tblUser.vchForename AS AssignedToName FROM tblUser ORDER BY tblUser.vchSurname"<br />
sTableDDL = "tblUser"<br />
dsDDL = clsCommon.getData(sQueryDDL, sTableDDL)<br />
dsDDL.Tables(0).DefaultView.Sort = "AssignedToName"<br />
Me.ddlAssignedToID.DataSource = dsDDL.Tables(0).DefaultView<br />
Me.ddlAssignedToID.DataTextField = "AssignedToName"<br />
Me.ddlAssignedToID.DataValueField = "inUserID"<br />
Me.ddlAssignedToID.DataBind()<br />
Me.ddlAssignedToID.Items.Insert(0, "lst2")


The AssignedToID field is not mandatory and if a user does not select anything, the default value to be stored is 0. The compiler is not liking this. What could be wrong?

Thank you in advance.

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.