4776b8bc72ab3b157a6e72ffa4c25a5826b1d330
FAQ/Questions/ConnectionStringRW.md
| ... | ... | @@ -5,32 +5,6 @@ ConnectionStringRW is one of Izenda Driver's properties, which enables users to |
| 5 | 5 | |
| 6 | 6 | Below is a sample global.asax using the ConnectionStringRW setting. The code block will appear within <script runat="server"> </script> tags within global.asax |
| 7 | 7 | |
| 8 | -```csharp |
|
| 9 | - |
|
| 10 | - public class CustomAdHocConfig : FileSystemAdHocConfig { |
|
| 11 | - public static void InitializeReporting() { |
|
| 12 | - //Check to see if we've already initialized. |
|
| 13 | - if (HttpContext.Current.Session == null || HttpContext.Current.Session["ReportingInitialized"] != null) |
|
| 14 | - return; |
|
| 15 | - //Initialize System |
|
| 16 | - AdHocSettings.LicenseKey = " License Key Here"; |
|
| 17 | - AdHocSettings.SqlServerConnectionString = @" Connection String Here"; |
|
| 18 | - AdHocContext.Driver.ConnectionStringRW = @" Connection String RW Here"; // ConnectionStringRW was used |
|
| 19 | - |
|
| 20 | - } |
|
| 21 | -} |
|
| 22 | -``` |
|
| 23 | - |
|
| 24 | - |
|
| 25 | - |
|
| 26 | -##Question |
|
| 27 | - |
|
| 28 | -How do I add Read-Write user permission to DB? |
|
| 29 | - |
|
| 30 | -##Answer |
|
| 31 | - |
|
| 32 | -Using 'ConnectionStringRW' property, user permissions to DB can be specified. This property should be assigned similarly to normal connection string as below - in the initialization of reporting. |
|
| 33 | - |
|
| 34 | 8 | ##Global.asax (C♯) |
| 35 | 9 | ```csharp |
| 36 | 10 | |
| ... | ... | @@ -47,6 +21,7 @@ Using 'ConnectionStringRW' property, user permissions to DB can be specified. Th |
| 47 | 21 | } |
| 48 | 22 | } |
| 49 | 23 | ``` |
| 24 | + |
|
| 50 | 25 | ##Global.asax (VB.NET) |
| 51 | 26 | |
| 52 | 27 | ```visualbasic |
| ... | ... | @@ -62,7 +37,7 @@ Public Class CustomAdHocConfig |
| 62 | 37 | 'Initialize System |
| 63 | 38 | AdHocSettings.LicenseKey = "INSERT_LICENSE_KEY_HERE" |
| 64 | 39 | AdHocSettings.SqlServerConnectionString = "INSERT_CONNECTION_STRING_HERE" |
| 65 | - AdHocContext.Driver.ConnectionStringRW = "INSERT_CONNECTION_STRING_HERE |
|
| 40 | + AdHocContext.Driver.ConnectionStringRW = "INSERT_CONNECTION_STRING_HERE" |
|
| 66 | 41 | |
| 67 | 42 | |
| 68 | 43 | End Sub |
| ... | ... | @@ -72,6 +47,19 @@ End Class |
| 72 | 47 | |
| 73 | 48 | |
| 74 | 49 | |
| 50 | +##Question |
|
| 51 | + |
|
| 52 | +How do I add Read-Write user permission to DB? |
|
| 53 | + |
|
| 54 | +##Answer |
|
| 55 | + |
|
| 56 | +Using 'ConnectionStringRW' property, user permissions to DB can be specified. This property should be assigned similarly to normal connection string as below - in the initialization of reporting. |
|
| 57 | + |
|
| 58 | + |
|
| 59 | + |
|
| 60 | + |
|
| 61 | + |
|
| 62 | + |
|
| 75 | 63 | If it's not assigned, Izenda as before uses Driver.ConnectionString for all operations against DB |
| 76 | 64 | |
| 77 | 65 |