Click here to Skip to main content
15,896,154 members
Home / Discussions / Database
   

Database

 
AnswerRe: Can stored procedures retrun more than one value. Pin
Giorgi Dalakishvili18-Feb-08 23:26
mentorGiorgi Dalakishvili18-Feb-08 23:26 
Generalquery + access database Pin
ritu432118-Feb-08 20:40
ritu432118-Feb-08 20:40 
GeneralRe: query + access database Pin
Paddy Boyd19-Feb-08 0:22
Paddy Boyd19-Feb-08 0:22 
Generalaccess database Pin
ritu432118-Feb-08 20:10
ritu432118-Feb-08 20:10 
GeneralRe: access database Pin
Kschuler19-Feb-08 10:52
Kschuler19-Feb-08 10:52 
GeneralProblem in Stored Procedure Pin
Syed Ali Raza18-Feb-08 19:11
Syed Ali Raza18-Feb-08 19:11 
GeneralRe: Problem in Stored Procedure Pin
Paddy Boyd19-Feb-08 0:24
Paddy Boyd19-Feb-08 0:24 
Questioncall DB2 stored procedure? Pin
jchigg200018-Feb-08 4:35
jchigg200018-Feb-08 4:35 
has anyone here used DB2Connect to call a DB2 stored procedure. I'm having trouble registering the input/output parameters.

here is my code

Dim conn As New DB2Connection("DATABASE=DB2DSST;UID=c132;PWD=*******;")
conn.Open()
Dim trans As DB2Transaction = conn.BeginTransaction()
Dim cmd As DB2Command = conn.CreateCommand()
Dim procName As String = "MG1006SP"
Dim procCall As String = "CALL MG1006SP (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)"
cmd.Transaction = trans
cmd.CommandType = CommandType.Text
cmd.CommandText = procCall

' Register input-output and output parameters for the DB2Command
cmd.Parameters.Add("DB2_ID", "DSST")
cmd.Parameters.Add("GRP_ID", "19 ")
cmd.Parameters.Add("LN1_ADDR", DB2Type.Char, 55)
cmd.Parameters.Add("LN2_ADDR", DB2Type.Char, 55)
cmd.Parameters.Add("CITY_NM", DB2Type.Char, 30)
cmd.Parameters.Add("ST_CD", DB2Type.Char, 2)
cmd.Parameters.Add("ZIP5_CD", DB2Type.Char, 5)
cmd.Parameters.Add("ZIP4_CD", DB2Type.Char, 4)
cmd.Parameters.Add("INFO_CHG_DT", DB2Type.Date, 4)
cmd.Parameters.Add("AIBRETRN", DB2Type.Integer, 4)
cmd.Parameters.Add("AIBREASN", DB2Type.Integer, 4)
cmd.Parameters.Add("SQLCODE", DB2Type.Integer, 4)
cmd.Parameters.Add("SQLSTATE", DB2Type.Char, 5)
cmd.Parameters.Add("SQLMESSAGE", DB2Type.VarChar, 1320)
cmd.Parameters.Add("APPL_RTN_CD", DB2Type.Char, 5)
cmd.Parameters.Add("APPL_MESSAGE", DB2Type.VarChar, 500)

' Call the stored procedure
Console.WriteLine(" Call stored procedure named " & procName)
cmd.ExecuteNonQuery()
AnswerRe: call DB2 stored procedure? Pin
Mike Dimmick18-Feb-08 7:08
Mike Dimmick18-Feb-08 7:08 
Questionhow to get the primarykey value of a table after copying a row Pin
Exelioindia18-Feb-08 2:38
Exelioindia18-Feb-08 2:38 
AnswerRe: how to get the primarykey value of a table after copying a row Pin
SimulationofSai18-Feb-08 3:40
SimulationofSai18-Feb-08 3:40 
GeneralRe: how to get the primarykey value of a table after copying a row Pin
Exelioindia18-Feb-08 9:33
Exelioindia18-Feb-08 9:33 
GeneralRe: how to get the primarykey value of a table after copying a row Pin
pmarfleet18-Feb-08 11:16
pmarfleet18-Feb-08 11:16 
QuestionC# MySQL ----parameter '?9' not found in the collection...huh? Pin
js8008518-Feb-08 2:17
js8008518-Feb-08 2:17 
AnswerRe: C# MySQL ----parameter '?9' not found in the collection...huh? Pin
sugo11-Apr-08 4:30
sugo11-Apr-08 4:30 
GeneralPassword! [modified] Pin
kibromg18-Feb-08 1:29
kibromg18-Feb-08 1:29 
GeneralRe: Password! Pin
Michael Potter18-Feb-08 6:10
Michael Potter18-Feb-08 6:10 
QuestionDynamic Parameters for report designed in SQL Server Reporting Services 2005 Pin
Senthil_M17-Feb-08 21:40
Senthil_M17-Feb-08 21:40 
GeneralRe: Dynamic Parameters for report designed in SQL Server Reporting Services 2005 Pin
r aa j18-Feb-08 2:18
r aa j18-Feb-08 2:18 
Questionsecurity in sql server 2000 database [modified] Pin
Sonia Gupta17-Feb-08 19:15
Sonia Gupta17-Feb-08 19:15 
GeneralRe: security in sql server 2000 database Pin
N a v a n e e t h17-Feb-08 19:42
N a v a n e e t h17-Feb-08 19:42 
GeneralRe: security in sql server 2000 database Pin
Sonia Gupta17-Feb-08 19:53
Sonia Gupta17-Feb-08 19:53 
GeneralRe: security in sql server 2000 database Pin
N a v a n e e t h17-Feb-08 21:10
N a v a n e e t h17-Feb-08 21:10 
GeneralPrimark key Pin
laleh.rajabi17-Feb-08 16:23
laleh.rajabi17-Feb-08 16:23 
GeneralRe: Primark key Pin
Christian Graus17-Feb-08 18:44
protectorChristian Graus17-Feb-08 18:44 

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.