i am using ADO.Net oledb for inserting and fetching data from Excel database. I want to make first column in the excel sheet to bold and i want to add comments. I am achieving this thru Interop.Excel Application class.
i dont want to use interop. is there anyway to achieve through ADO.net query itself ? or some other way? My application is c# windows application
No way through ADO.NET, any more than there is of making a SQL Server column bold. ADO.NET treats Excel as a data source - formatting is something quite different and requires knowledge of the Excel spreadsheet format, such as you'd get via Interop. There are probably other libraries you can use if you search...
Related
We have a screen which has number of fields from different tables, i need to extract those fields from tables and keep the data in Excel sheet. How can i do this ?
Is this a "one-time" data-transfer, or will it be an ongoing, automated process?
IMHO, for a "one-time" data-extraction, the easiest way to accomplish that is using ODBC. Historically, I've used ODBC to import the data into Microsoft Access. From there, it's extremely easy to export the data into Excel.
For a regularly-occurring, automated method, I think using the CpyToImpF command works the best. It takes a little trial-and-error to get the process working, but once you've got it set up, it can run in regularly scheduled job to export the data. (Google the syntax for the command, and try it yourself.)
HTH,
Dave
There is a tool called iEXL which will create .Xlsx spreadsheets native on the AS400.
If you after only data from one screen we will help you and the price would we adjusted to take this into account.
WWW.iEXLSOFTWARE.COM
I have very large number of db tables in pracle database. I would like to somehow generate simple jasper report (version 6.0.3) for each of them.
One line with the name of table as header and under it common table displaying all columns of table. Option to exclude some columns from predefined list is welcome.
Any advise? Has someone any experience with this issue?
Thank in advance
My idea is use some ETL tool for extract specification of tables directly from database and map it somehow into xml files
There is a cloud based tool that generates the JRXML transparently based on the data structure, you can check it out at http://flashreport.io.
It supports simple XML and JSON as input, but does not allow excluding specific columns. You would have to do that in your ETL tool.
You can use iReports, which is a designing tool for generating jrxml files (which are jasper-reports xml files): iReports tutorial. You have just to create a data-source (in this case you can create a connection to your DB), and construct your report design by dragging and dropping the tables/columns into it (mapped from the underlying data-source).
I've personally been working this iReports, but nowadays the jaspersoft community is putting it's efforts into another tool: Jaspersoft Studio, which seems to be the future replacement for iReports
Is their any utility through which we can determine the list of database objects an Oracle Form or Report uses or the list of Forms and Reports that use a specific database object.
For Oracle forms/Reports 10g
There used to be a tool made by Quest Software "SQL Impact" but it is not supported any more.
The easiest way to do this kind of analysis is to convert all your fmb/rdf to xml and then write a script in Ruby searching for db object names.
Alternatively you can use JDAPI to iterate over forms objects, but there is no JDAPI for reports. Using JDAPI is much easier using JRuby, you can find sample scripts there:
https://github.com/tomi44g/OracleFormsJruby
I would like to import an Excel .xls file workbook into Powerbuilder. The file has 2 sheets and these sheets must be imported into 2 differenct db tables.
Any assistance is kindly appreciated.
Thanks
John.
First thing, there's nothing automagic, along the lines of a one-line solution that you could get for other file formats. There's a manual method, there's a scripting approach, and you can probably merge the two as a third option.
For a manual method, you can go into Excel and export your data as something that will import into a DataWindow. You don't mention your PowerBuilder version, but the file format for importing from Excel that comes to mind is CSV, which was added in PB9.
For a scripting approach, you can use OLE (assuming Excel is installed on the client machine) and access data however you want with the scripting engine, moving it into PowerBuilder in whatever format you want.
To mix the methods, you could use OLE to export the file to a couple of CSVs, then dw.FileImport() the data in.
Good luck,
Terry.
Postscript: Sybase has examples of OLE access, and examples of using ODBC, a solution I had neglected before.
If you give names to the areas with the data in Excel and then setup ODBC connections that point to them, you can access them like a database table from within PowerBuilder.
I use iReport designed jrxmls for Jasper reports
I have done database specific functions and DML queries like date format, string concatenation, concatenate symbol(||) etc.
My Question is, "Is there any way or plug-in to make the jrxml files to be database portable?".
Thanks in advance,
Kalaiselvan.
You are using JDBC, so your reports are already kind of portable unless you use some vendor-specific SQL functions or features.
You could write your OWN datasource in JasperReports (do implement JRDataSource interface), and provide your own layer of database independence. It shouldn't be that hard.
Each report is filled from a data source like a database, but you knew that. Since the report is filled by fetching data from a specific database with queries to specific rows, if you want to make your .jrxml files database portable (or your .jasper files for that matter) you will need to make your data source and sql queries parameters which are fed into your report file from your program. It is pretty straight forward to make the data source and SQL query a parameter using iReport.