TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Mohammed Gamal
NA
65
0
Get data from a library in DB2 (AS400)
Feb 8 2016 3:25 AM
Dear All
please i need help to get data from a library in DB2 (AS400) named QSBD.INVW
but there error in my sql query
that is my code
////////////////////////////////////////////////////////////////////////////////////////////////////////
string path = "Provider=IBMDA400;Data Source=192.168.1.2;User ID=user;Password=password";
string query = "SELECT * FROM QSBD.INVW";
DataTable dt = new DataTable();
OleDbConnection connection = new OleDbConnection(path);
OleDbDataAdapter dAdapter = new OleDbDataAdapter(query, connection);
connection.Open();
OleDbCommandBuilder cBuilder = new OleDbCommandBuilder(dAdapter);
dAdapter.Fill(dt);
connection.Close();
BindingSource bSource = new BindingSource();
bSource.DataSource = dAdapter;
dataGridView1.DataSource = bSource;
this.Refresh();
//////////////////////////////////////////////////////////////////////////////////////////////////////
the program stops at "dAdapter.Fill(dt);" and gives error "SQL0204: INVW in QSBD type *FILE not found."
please how can i solve this problem.
Reply
Answers (
2
)
how to Integrate PayUMoney in ASP.Net C#?
Convert project of window 8 app of visual 2012 into 2013?