LINQ Table to Excel Spreadsheet - linq

can someone please tell me or point me in the right direction regarding how to save a LINQ table to an excel spreadsheet?
Thanks!
Mr Cricket

Generally, there are two methods to Excel:
UI layer
A lot of UI controls, say Grids, such as XtraGrid (DevExpress.com), can show Linq result (actually you have to call IQueryable.ToList() at first) and then export what you see into excel, pdf, csv and other formats.
The advantage is you may adjust the UI represenation of the Linq data before you export it.
The disadvantage is that it is interactive, so user activity is involved.
Data Layer
You may write lines of code to export the data into MS excel directly. It should be very easy if you know the API of MS API. But if you want to make the sheet beautiful, you may need a lot of code. Or you may create an MS Excel template manually and show the data by the help of the template.
The advantage is the speed and no user is involved.
The disadvantage is that it is hard to make the export beautiful or conveniently. Especially when you offer this function to end users.

Related

Programmatic creation of sheets and visuals in quicksight

I have visual data available to bind in the sheet for example (positions and types of visuals with source data) and I want to update the analysis with my updated sheets/visuals programmatically. Here are a few things I’d like to accomplish by programmatically creating analyses:
Eliminate Manual Work: Creating Quicksight reports involves a lot of repetitive click-and-drag work. It would be more efficient to replace this with code.
Improve Re-usability: Re-using content in Quicksight is a very click intensive manual process. Code is easier to reuse for similar work.
Improve Precision: Click-intensive manual processes are naturally error prone. Giving users the ability to script out analysis creation reduces the potential for error.
Is there any way to create/ Update existing sheets and visuals programmatically?
Any quicksight api endpoints?

Export All Relational Models to PDF from Oracle Data Modeler

Is there a way to export all Relational Models for a schema in Oracle Data Modeler to a single PDF file? Where each model is a separate page?
I have an ERD for my schema consisting of about 90 tables. This full model can be hard to read. To account for this, I have created several additional Relational Models that cover subsets of data. For example, another model that consists of just fives tables pulled from the full model, showing their mappings. This is to better demonstrate the relationships of this subset of data in our application's workflow. They relate to several other tables, but these five on their own more easily demonstrate how these items work together from a user's perspective.
I can print each relational diagram out to separate PDFs using File -> Print Diagram -> To PDF File..., but this leaves me having to manually combine nearly a dozen different PDFs. Is it possible to export them all out to a single file at once? Data Modeler seems to only focus on the open diagram that is in focus, and ignores everything else when I'm working with print options.
If that's not possible, is there at least a way to print all the models to separate files with a single click? Opening each model and printing them separately is overly time-consuming.
Not today.
What you can do, in version 4.2 is have your design/model with your smaller diagrams implemented as SubViews.
When you run the 'All Tables' report and export to HTML, you get a TOC/index page with links to the data dictionary reports for each object, and you also get links to each SubView diagram in the HTML. So it's a single report, with different pages for each diagram. It's just HTML instead of PDF.
It's NOT PDF, but I would argue slightly that HTML is easier to work with.
We could always create an ER to give you exactly what you're asking for though. I'm assuming that maybe Adobe Writer could take multiple PDF files and edit them into a single document as a workaround?

What's more performing between an EXCEL formula, a PIVOT TABLE and VBA code?

I have a (growing) table of data with 40.000 rows and 20 columns.
I need to group these data (by month and week) and to perform some simple operations (+ & /) between rows/columns.
I must be able to change the period in question and some specific rows to sum up. I know how to macro/pivot/formula, but I didn't started yet, and I would like the recalculation process to be the fastest possible, not that I click a button and then everything freezes for minutes.
Do you have any idea on what could be the most efficient solution?
Thank you
Excel have it's limits to store and analyze data at the same time.
If you're planning to build a growing database at MS Excel, at some point you will add so much data that the Excel files will not work. (or using them won't be time effective)
Before you get to that point you should be looking for alternate storage options as a scalable data solution.
They can be simple, like an Access DB, sqlite, PostgreSQL, Maria DB, or even PowerPivot (though this can have it's own issues).
Or more complex, like storing the data into a database, then adding an analysis cube and pulling smaller slices of data from these databases, into Excel for analysis and reporting.
Regardless of what you end up doing you will have to change how Excel interacts with the data.
You need to move all of the raw data to another system (Access or SQL are the easiest, but Excel supports a lot of other DB options) and pull smaller chunks of data back into Excel for time effective analysis.
Useful Links:
SQL Databases vs Excel
Using Access or Excel to manage your data

Getting into designing dashboards and need some help identifying each technical layer along the way

So I will be embarking on designing a dashboard that will display KPI's and other relevant information for my team. Since I am in the early stages of this project and am not very familiar on the technical process behind designing a dashboard, I need some questions vetted out first before I go and shop for some solutions to avoid reinventing the wheel.
Here are some of my questions:
We want a dashboard that can provide live-time information via our data sources (or as close to live-time as possible). What function allows a dashboard to update itself with concurrent datasources? From a conceptual standpoint, I can understand creating a dashboard out of Microsoft Excel, and having the dashboard dependent on the values you may have set within your pivot table.
How do you make a dashboard request information from multiple datasources on its own? Just like the excel example, a user may have to go into the pivot tables to update values, but I want to know how would a dashboard request this by itself and what is the exact method from a programming standpoint? Does the code execute itself every time you refresh the webpage?
How do you create datasources organically? I know for some solutions such as SharePoint BI Center, there are pre-supported datasources like an excel sheet or SharePoint and it's as easy as uploading your document and letting the design handle the rest. However, there are going to be some datasources that I know that will need to be fetched. Do I need to understand something else like an event recorder in order to navigate this issue?
Introduction
The dashboard (or a report, respectively) is usually the result of a long chain of steps. Very much simplified it could look like this:
src1
|------\
src2 | /---- Dashboards
|------+---[DWH]-[BR]-+
src n | | \---- Reports etc.
|------/ [Big Data]
Keep in mind, this is only a very, very simple structure of a data backend / frontend.
DWH means Data Warehouse, where data might be stored temporarily (you referred to this as fetching). This could be a database, could be a Big Data engine, could be a combination of both...
Afterwards, there are Business Rules (BR). Those might be specific rules in how different departments calculate and relate to data, but also simple things like algebra.
Questions
So, the main question should not be about the technology:
What software should we choose?
How can we create a dashboard?
but on the contrary focused on your business processes (see it like a top-down view):
How does our core process look like? Where would I like to measure data?
How would department a calculate sales in difference to department b? Should all use the same rule?
Where does everyone store the data? Can we access it? Do we need structural data?
And, very easy to forget but also easily sometimes one of the biggest parts: Is the identifier of a business object (say, sales id) everywhere build and formatted in the same way?
Conclusion
When those questions are at least in the back of your head and you keep working in this direction, more or less automatically data will spill out at certain points of that process.
Then it won't matter if you use Excel, a small-to medium app like Tableau, Tibco Spotfire, QlikView, Power BI or you want to go full scale with a big Hadoop backend, databases and JasperReports, Apache Drill, Pentaho, SSIS on top of it... it will come out eventually.
TL;DR
Focus on the processes first. Make sure to understand them. Draft in Excel. Then proceed in getting the data and the tools you need to help your use cases. It will work out much better from a "top-down" approach than trying to solve your requirements with tools only.

ActiveReports multi table dataset

Is there opportunity to use dataset with multiple tables as datasource in ActiveReports ? What advantages has ActiveReport over SSRS?
Datasets can only reference a single sql query results, they cannot be joined, you would have to join the tables in the SQL query itself. The results would appear as a single dataset that you can bind your data regions to.
ActiveReports has multiple designers and layout engines for various reporting scenarios. It has a section based layout (similar to Microsoft Access) and RDL continuous data regions layout and a Page Layout engine that is used for creating pre-designed form styles reports such as a tax form or complex insurance form. Each one of them has its own optimized engine.
In addition, AR provides you with the designers as royalty free controls to include with your applications. There are quite a few other unique features that might depend on your needs, such as an excel transformation device where the report data is rendered into an Excel template.
However, I would recommend that you download both and try them to see which one would fit your usage scenarios better.
Hope this helps.
http://activereports.grapecity.com

Resources