[sql dataadpatr syntax error]

A

Agnes

Mycode shown as the following:- it is very simple code.
However, I got an error on "daExBL.Fill(dsExBL) "
Is there problem onmy syntax or on my SQL server ?

Dim conSea As New SqlClient.SqlConnection()
Dim strSelectExBL As String = "select * from BillLadingHeader number
where ='CGL03060010' "
Dim strConnSea As String = "data source=dts-server;initial
catalog=cgl_seadata;integrated security=SSPI;persis" & _
"t security info=True;workstation id=dts-server;packet size=4096"
conSea.ConnectionString = strConnSea

Dim daExBL As New SqlDataAdapter(strSelectExBL, conSea)
Dim dsExBL As New DataSet()
conSea.Open()
daExBL.Fill(dsExBL)
 
J

Jorge

Hi Agnes
I think its the select statement :
"select * from BillLadingHeader number where
='CGL03060010'"

It should be something like this:
"select * from BillLadingHeader where number
='CGL03060010'"

Kind Regards
Jorge
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top