rssidlowski / Pollution_Source_Tracking

City of Baltimore Pollution Source Tracking
0 stars 0 forks source link

Export all PST data to an Excel file #138

Closed rssidlowski closed 9 years ago

rssidlowski commented 9 years ago

From COB personnel: This there a way to export all of the PST data into an Excel file?

gerrykelly commented 9 years ago

Sure, that can be done from Excel (2010 for this example) in a number of ways (as a onetime import or as linked tables. Currently one way is to choose "data" from the menu in Excel > select "from other sources" > select SQL Server, then enter the server info for development (they need to know it will change for Prod.) so .... 10.1.65.39\dpwdev, GIS_ADMIN & the password is all they need. Then they can then select the Pollution_Source_tracking database and import tables (they need to know the schema and understand fields have codes and LU tables have values). If they are not allowed to have the PW for GIS_ADMIN, then could they have a read only account to do this?

gerrykelly commented 9 years ago

Thinking about it, if they want this ability there definitely needs to be a user for them created with readonly on GIS_ADMIN's tables in the Pollution_Source_tracking database. That's an Ian request,

rssidlowski commented 9 years ago

Can we have an export to excel option/button from the application?

gerrykelly commented 9 years ago

Yes, but this would be some work, I'll respond by email.

gerrykelly commented 9 years ago

I'm assuming this only needs to work when using the app from a Windows computer (download via Chrome)

rssidlowski commented 9 years ago

Yes that is correct.

gerrykelly commented 9 years ago

working from windows/chrome (might need to enable popups for site). I still need to tweak some queries.

rssidlowski commented 9 years ago

Can you add a confirmation message prior to starting the Excel download to say: You are initiating export of full PST database to Excel. You will then be prompted to download. Continue? Add a Cancel and OK button. Also what happens if two people do at once? Update the message: excelwb to: Excel workbook has been created on server. Click OK to download.

gerrykelly commented 9 years ago

Done. The buttons on the new message box are the Sencha defaults, I can customize if it really matters. The probably-needing to allow popups for the site to get the download is annoying. I could add a message about that. I could code it differently but that would take some time. But, if it's in the user guide and they've done the download once, that's probably good enough for what they need.

I thought about the "two people do at once" issue when I started this and said to heck with it. If would fail for at least one of them so they'd need to retry. I just figure this would just about never happen and is not worth the order-of-magnitude more effort to manage concurrent processes and downloads.

rssidlowski commented 9 years ago

Verified.