Subsonic: Is it possible to use the oledb provider - subsonic

When I set up a connection for Subsonic 3.0.0.4 to connect to an Oledb sql provider using the T4 Templates I get the following error: Keyword not supported 'provider' Can Subsonic access a database using OleDb? If so. How?

Which dbms do you want to use?
Since SubSonic 3 uses System.Data.Common for accessing data, it should be possible to use it with every dbms that supports ADO.net (I belive there is a OleDbProvider for ado).
But if you use a DBMS that is not supported by subsonic you have write your own DataProvider and an OleDb.ttinclude template file.
The beste starting point is to look at an existing provider:
https://github.com/subsonic/SubSonic-3.0/tree/master/SubSonic.Core/DataProviders/MySQL
https://github.com/subsonic/SubSonic-3.0-Templates/tree/master/TemplateProviders
Creating your own Provider shouldn't be to hard at all. I would use a Copy&Paste approach from an existing provider and modify everything that causes some errors.

I would use the standard SQL to LINQ Entity spaces but I have to connect to a database for a client through their application server's specific OLEDB provider. Apparently it's doing extra work after the standard OLEDB SQL commands are sent to the server. So LINQ as far as I understand is out. I built my own CRUD classes, but it's a pain doing it this way. I just want a tool that can build the standard classed so I don't have to create the layer myself.
It's MS SQL Server 2005 on the other end.

Related

jHipster - simplify generation of the new APP if the DB already exists

does any tool exist that can simplify generation of the new APP if the DB already exists? I can create JDL file for new app manually base on existing DB - but I prefer to automate the process. This DB is part of old Spring Roo app.
Thank you.
The spring Roo 1.x version provides the "Database Reverse Engineering" functionality. This add-on allows you to create an application tier of JPA 2.0 entities based on the tables in your database. DBRE will also incrementally maintain your application tier if you add or remove tables and columns.
After generate the entities, you could execute the necessary web mvc commands to generate the complete application.
However, remember that the Spring Roo 1.x is not beeing maintained, because uses old technologies.
See more about the DBRE process here:
http://docs.spring.io/spring-roo/reference/html/base-dbre.html
Hope it helps,
There's a JHipster module that is being developed for this purpose: https://github.com/bastienmichaux/generator-jhipster-db-helper
It is probably not ready yet but could be a good start.

How to do the Authorization in Asp.net by using Identity Framework?

For doing authorization in asp.net mvc 5 I have searched lot on internet but not getting correct answer. Actually I am using Visual studio community edition with .net framework 4.5.2 and mvc5. I want to do the Authorization in my project. My project is created with no authentication mode while creating a project.
Firstly I have tried these things:
I typed a command "Enable Migrations" on Package manager console.
Then I got one error like: Creating a DbModelBuilder or writing the EDMX from a DbContext created using Database First or Model First is not supported. EDMX can only be obtained from a Code First DbContext created without using an existing DbCompiledModel.
I dont know how to resolve this error. please help me to get out of it.
Which approach did you chooses to build our database model? Code First, Model First or Database First?
I'm asking because you can't use migrations with Model First or Database First approach. EF Migrations is a product targeted for Code First approach. CodeFirst assumes that you will never make any changes manually to the database. All the changes to the database will go through the code first migrations.
But there is solution for that - you can use Code First approach with an existing database. Take a look here: Using EF “Code First” with an Existing Database.

Connect Appserver of progress open edge through node.js

Does anyone have experience, information or some (coding) examples about a solution to establish a connection between the appserver of progress and node.js!? The aim is to create REST-Services to the db which can be accessed by the web like an angular-app.
Thanks for any advice
Christian
Starting with 11.2 (and enhanced in later versions) you can create REST-based applications utilizing the AppServer as a platform. ProDatasets are used as output (they convert easily to xml and/or json).
This is all explained in the Web Services part of the documentation. I'm providing a link below.
Basic steps
You need to consult the manual for all these steps...
Create an ABL program with input parameters (could be a parameter, a temp-table or a dataset) and and a single output parameter (could be a temp-table, a dataset or a single character or longchar parameter).
Add ABL-specific REST annotation to the program
Map the parameters in OpenEdge Studio
Setup REST agents with the restman utility
Export a "WAR-file" and deploy your webservice.
Calling the web service from node.js should be no greater problem than calling any REST based web service.
In versions prior to 11.2 you can "fake it and make it" utilizing WebSpeed. You can create a webspeed program that read parameters from the query-string (using get-field()) and then writes a response to the "webstream". Use either the WRITE-XML or WRITE-JSON methods on a temp-table or a dataset for writing the result. Don't forget to add a good MIME type though... This might not be as robust and customizable but it will work...
OE 11.4 Product Documentation - Web Services See chapter "II Creating OpenEdge REST Web Services"
These might also be useful:
OE 11.4 Product Documentation - Working with XML
OE 11.4 Product Documentation - Working with JSON

Changing internal database to external JDBC in Atlassian crowd

I have installed Atlassian crowd using the internal database method on Centos 6. Installation went successfully and now i want to use external database (mysql) using JDBC. I cant find the option to accomplish that. How can i do that?
See Atlassian's documentation for how to Migrate to Another Database:
This guide applies to situations when you may need to migrate Crowd to another database.

Subsonic adding a DB provider for Simple Repository

I was wondering--what part of Subsonic 3 needs to be modified to support a different database under a Simple Repository scenario? I haven't found any documentation on this point. Subsonic 3 seems to be all about the T4 templates but when I check out the Subsonic project sources I don't see any T4 templates in there...so where/how do I add support for another database?
Thanks,
Alex
no part of SubSonic needs to be modified for SimpleRepo - just change your connection string and be sure to change the provider (part of the connection string) as well. So, the default connection might be:
connectionString="server=localhost;database=northwind;user id=bob;password=*****" provider="System.Data.SqlClient"
Change that to be the connection string you want, and the provider to your DB provider. MySQL would be something like "MySql.Data.MySqlClient" and SQLite would "System.Data.SQLite" (I think).
SubSonic will do the rest.

Resources