String Objects are ok?

mathieu_cupryk
mathieu_cupryk used Ask the Experts™
on
Try
                StoredProcName = dbName & ".dbo.usp_GetPrestigeCustomers"

                cmd = dbManager.GetStoredProcCommand(StoredProcName)
                cmd.CommandTimeout = 0


                dbManager.AddInParameter(cmd, "@DT_FROM", DbType.DateTime, IsNull(dr2.Item(1)))           ' Second Entry will be of first row
                dbManager.AddInParameter(cmd, "@DT_TO", DbType.DateTime, IsNull(dr1.Item(2)))             ' Third entry of the last row
                dbManager.AddInParameter(cmd, "@DT_TO_MONTH", DbType.DateTime, IsNull(dr2.Item(2)))       ' Third entry will be of first row

Should I be passing string objects or dates this query is running forever.
"02/01/2004 12:00AM" {String}
"02/28/2004 12:00AM" {String}
"05/29/2004 12:00AM" {String}

How should I change this?

Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Commented:
Where do you want to pass these string objects to?

Author

Commented:
They are working.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial