Control the tables generated by SimpleMembershipProvider? - sql-server

I found SimpleMembershipProvider to be pretty neat and productive.
I was wondering if there is a way to control the generate table/column names/datatypes.

You can control the table name for the user table and the column names for the user id and user name columns in it. You specify those in the InitializeDatabaseConnection method. The SimpleMembershipProvider expects the UserId column to be an IDENTITY column. It uses ##IDENTITY to obtain the ID of newly created records. Currently, the SimpleMembershipProvider only works with SQL Server (Express or Full) or SQL Compact 4.0 databases.
You can't change the schema of the membership or roles tables. The SQL for managing accounts and using those tables is hard-coded into the SimpleMemberhipProvider.

Related

Logic App failing to select rows from SQL Server Table with multiple dots in schema name

I'm having a logic app that is trying to Get Rows (V2) from On Premise SQL Server. The SQL Server schemna name is having multiple dots in it. The SQL Server table name is [vehicle.small.fourwheel.car.kia].[Picanto], where [vehicle.small.fourwheel.car.kia] is the schema name and Picanto is the Table name.
I've tried several things in Azure Logic App, tried passing the table name as a variable, as a parameter, tried selecting it from the drop down list from Get Rows (V2) Table Name list, but every time there is the same error, "The key didn't match any rows in the table.\r\n inner exception: The key didn't match any rows in the table.\r\nclientRequestId: 28f3f9c4-b5fa-427c-a6f9-b45cdd3d31e1.
If the schema name is just having one dot, then it is working fine.
Need some solution from the experts on this. All of the tables schema names in the database is having multiple dots.
After reproducing from my end, this was working fine for me on premise SQL database. I could able to view all the tables inside the database when connected with the right credentials on Logic Apps without any schema name. Make sure you install on premise data gate way and connect to your on-premise data gateway resource on Azure. Below is the flow of my logic app.
RESULTS:
On premise tables

Changing keys and data for Azure Mobile Service

I have an existing Azure web application backed by an Azure SQL db. My plan is to utilize this same db in new mobile applications I am building, however I made a design decision originally that doesn't work with Azure Mobile Services. I made my keys in the existing database integer ID's and as of recently to utilize a db within the Mobile service it needs ID's that are String GUID's. I have over 200 users entered in my existing database with other associated tables all tied to these ID's.
My question is, is there a feature or methodology for converting all of these integer keys to string keys without dropping all of their data and requiring everyone to manually go in and re set things up again?
My database knowledge is limited but from all I've seen, Azure Mobile Service requires that the keys be strings now and there isn't a work around for it.
Any help is much appreciated, Thanks!
To change the datatype of a column in SQL, just simply run the following command:
ALTER TABLE table_name
ALTER COLUMN column_name column_type
For example, assume your table name is table1 and the column is called keys,
ALTER TABLE table1
ALTER COLUMN keys varchar(10)

Read Oracle DB FROM Microsoft SQL Server Manager 2012 to find Unknown Table

I am working on a project that requires me to read/write to an OLEDB. I do not know what table the information I'm looking for is in and there are about 150+ tables. Is there a way to search each table for a certain column header without querying each table one by one? so far I've just been doing
SELECT * FROM [name]..[name].[name] GO
And reading the headers in data grid view on a vb.net program I made.
Try this if you have a user with dba privileges on the Oracle database.
SELECT OWNER, TABLE_NAME,COLUMN_NAME
FROM sys.dba_tab_columns
WHERE column_name LIKE UPPER('%Your column name%');

SQL Server Tables Relationship in Access

I connected a sql server through ODBC and lined sql tables. I manually created my relationships in my database but, when I do that, my other tables are not editable. My drop downs I created won't allow me to select it or my text box doesn't let me type in it.
How am I supposed to create a relationship so I can use Access as a front-end to enter in data into the database?
If you are linking to tables that exist already in SQL Server, then you don't need to worry about creating relationships in Access.
If you want to edit data in the SQL Server tables, make sure that you have a primary key on each table, and if possible a field with at "timestamp" data type.

Updating Tables In SQL Server 2005 Using Access 2010

Very new to the world of advanced access and SQL Server 2005. I have now developed all my tables in SQL Server and added them to my blank database now in access using a ODBC connection. This topic is just for advice really, what would be the best way for me to create a form so that users within the company can input customer data without having to go onto SQL?
I have three tables 'Customer Table' 'Enquiry Source' & 'Admin Staff' - the 'Enquiry Source' & 'Admin Staff' consist of Enquiry Source ID, Enquiry Source Name, Admin Staff ID & Admin Staff Name which than have a link to the Customer Table.
When updating the tables myself in the SQL Side I use the ID's as integers but now I am in access I would like my users to be able to update these using the appropriate names on a list box. I have created a View in SQL and exported it to access but when I complete all the information and try and save the record it won't allow me to update multiple tables - which I understand is due to it being a View.
Is there an easier way of doing this so my teams can add new customers on the MS access front end system?
The Enquiry Sources are names of methods of referal: Newspaper, Recommendation, Google etc
The Admin Staff are names of employees creating the Customer.
Thanks Guys!
Callum
Link the three tables or three simple views on the tables. Use the form wizard to create a form based on the customer table. Use the list box or combo box wizard to create a control based on each of the two look-up tables. See create form to add records in multiple tables for some notes on how to use the wizards.

Resources