Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post Nov 20, 2012 05:39 AM by sargamlucy
Nov 16, 2012 10:06 AM|LINK
The summary of this discussion is, while using OracleBulkCopy, even after providing the correct table name and schema name, I get Table or View does not exist error. Below is my code :
public static void WriteToServer(string qualifiedDBName, DataTable dataTable, string schemaName)
using (OracleConnection con = new OracleConnection())
con.ConnectionString = Common.ConnectionString;
using (OracleBulkCopy bulkCopy = new OracleBulkCopy(con))
bulkCopy.DestinationTableName = schemaName + "." + qualifiedDBName;
Surprisingly, this code works in my developement environment, but does not work in UAT. in UAT, if I try to run a query like select * from meri_owner.ati_mapping, where
meri_owner is the schema name and ati_mapping is the
table name, it works properly.
But when I use the same parameters in WriteToServer function(written above), it's not working. Please help, it's urgent.
Nov 20, 2012 05:39 AM|LINK
Well after all the searching and getting some help from colleagues, I finally found out the issue. My UAT site was using a user name which did not have insert/update access to the mentioned table. And the table is in another schema, so I had to create a
synonym in the DB user for the schema.table and then use that for updating the value.