Connecting to layout in FMP database

hello!
I need to target a specific layout in FMP - how do I do this in my connection? Is it added to:
java.sql.Connection connection = java.sql.DriverManager.getConnection ("url" add here?);
many thanks :)

Hi,
It depends on the server you use to connect to the database.
bye
Uma

Similar Messages

  • Connection between Layout Designer & Print Preview

    Hi,
    Can anyone tell me any hints related to the connection between Layout Designer and Print Preview (icon) for displaying the selected report layout's preview.

    What is ur exact requirement..??
    Generally all the layouts are  stored in 2 tables in the company database, RDOC and RITM are the tables.
    Hope it helps,
    Vasu Natari.

  • SQL1119N  A connection to or activation of database "DEV"

    Hello All,
    am Gautam Poddar from PwC, Kolkata. I have talked with you just now.
    We have activated the logretain and userexit on after taking the full ofline backup of the system. We were unable to take the online backup, so log directory was full. So we have moved the log file from log directory to another directory. After that we have increased the size of the log directory and copy all the log files to log directory but database connection is failed. I am getting this error while try to connect with this command > connect to dev
    SQL1042C An unexpected system error occurred. SQLSTATE=58004
    Yesterday I was unable to resolve the problem. So I have restored all the file system from OS level Backup.  Now I am not able to connect the Database and it is giving this error message
    ecldevqa:db2dev 5> db2 connect to DEV
    SQL1119N  A connection to or activation of database "DEV" cannot be made
    because a previous restore is incomplete.  SQLSTATE=57019
    Restored these file system
    /dev/sapvg/devsaptemp1
                       1572864   16768 1544008    1% /db2/DEV/saptemp1
    /dev/sapvg/devsapdata4
                       41943040 23979664 17823088   57% /db2/DEV/sapdata4
    /dev/sapvg/devsapdata3
                       41943040 23979664 17823088   57% /db2/DEV/sapdata3
    /dev/sapvg/devsapdata2
                       41943040 23979664 17823088   57% /db2/DEV/sapdata2
    /dev/sapvg/devsapdata1
                       41943040 23979664 17823088   57% /db2/DEV/sapdata1
    /dev/sapvg/DEV_LOG_DIR
                       10485760 5390328 5055680   52% /db2/DEV/log_dir
    /dev/sapvg/devdb2dump
                       3145728 2757168  385592   88% /db2/DEV/db2dump
    /dev/sapvg/db2dev  3145728  100224 3021728    3% /db2/db2dev
    I have seen these out put has not changed after restoration > db2 get db cfg for DEV
    ecldevqa:db2dev 17> db2 get db cfg for DEV
           Database Configuration for Database DEV
    Database configuration release level                    = 0x0b00
    Database release level                                  = 0x0b00
    Database territory                                      = en_US
    Database code page                                      = 1208
    Database code set                                       = UTF-8
    Database country/region code                            = 1
    Database collating sequence                             = IDENTITY_16BIT
    Alternate collating sequence              (ALT_COLLATE) =
    Database page size                                      = 16384
    Dynamic SQL Query management           (DYN_QUERY_MGMT) = DISABLE
    Discovery support for this database       (DISCOVER_DB) = ENABLE
    Restrict access                                         = NO
    Default query optimization class         (DFT_QUERYOPT) = 5
    Degree of parallelism                      (DFT_DEGREE) = 1
    Continue upon arithmetic exceptions   (DFT_SQLMATHWARN) = NO
    Default refresh age                   (DFT_REFRESH_AGE) = 0
    Default maintained table types for opt (DFT_MTTB_TYPES) = SYSTEM
    Number of frequent values retained     (NUM_FREQVALUES) = 10
    Number of quantiles retained            (NUM_QUANTILES) = 20
    Backup pending                                          = NO
    Database is consistent                                  = NO
    Rollforward pending                                     = NO
    Restore pending                                         = NO
    Multi-page file allocation enabled                      = YES
    Log retain for recovery status                          = NO
    User exit for logging status                            = YES
    Self tuning memory                    (SELF_TUNING_MEM) = OFF
    Size of database shared memory (4KB)  (DATABASE_MEMORY) = COMPUTED
    Database memory threshold               (DB_MEM_THRESH) = 10
    Max storage for lock list (4KB)              (LOCKLIST) = 20000
    Percent. of lock lists per application       (MAXLOCKS) = 90
    Package cache size (4KB)                   (PCKCACHESZ) = 5120
    Sort heap thres for shared sorts (4KB) (SHEAPTHRES_SHR) = 20000
    Sort list heap (4KB)                         (SORTHEAP) = 2048
    Database heap (4KB)                            (DBHEAP) = 35000
    Catalog cache size (4KB)              (CATALOGCACHE_SZ) = 2560
    Log buffer size (4KB)                        (LOGBUFSZ) = 1024
    Utilities heap size (4KB)                (UTIL_HEAP_SZ) = 10000
    Buffer pool size (pages)                     (BUFFPAGE) = 10000
    Max size of appl. group mem set (4KB) (APPGROUP_MEM_SZ) = 128000
    Percent of mem for appl. group heap   (GROUPHEAP_RATIO) = 25
    Max appl. control heap size (4KB)     (APP_CTL_HEAP_SZ) = 1600
    SQL statement heap (4KB)                     (STMTHEAP) = 5120
    Default application heap (4KB)             (APPLHEAPSZ) = 4096
    Statistics heap size (4KB)               (STAT_HEAP_SZ) = 15000
    Interval for checking deadlock (ms)         (DLCHKTIME) = 10000
    Lock timeout (sec)                        (LOCKTIMEOUT) = 3600
    Changed pages threshold                (CHNGPGS_THRESH) = 40
    Number of asynchronous page cleaners   (NUM_IOCLEANERS) = AUTOMATIC
    Number of I/O servers                   (NUM_IOSERVERS) = AUTOMATIC
    Index sort flag                             (INDEXSORT) = YES
    Sequential detect flag                      (SEQDETECT) = YES
    Default prefetch size (pages)         (DFT_PREFETCH_SZ) = AUTOMATIC
    Track modified pages                         (TRACKMOD) = ON
    Default number of containers                            = 1
    Default tablespace extentsize (pages)   (DFT_EXTENT_SZ) = 2
    Max number of active applications            (MAXAPPLS) = AUTOMATIC
    Average number of active applications       (AVG_APPLS) = AUTOMATIC
    Max DB files open per application            (MAXFILOP) = 1950
    Log file size (4KB)                         (LOGFILSIZ) = 16380
    Number of primary log files                (LOGPRIMARY) = 20
    Number of secondary log files               (LOGSECOND) = 40
    Changed path to log files                  (NEWLOGPATH) =
    Path to log files                                       = /db2/DEV/log_dir/NODE
    0000/
    Overflow log path                     (OVERFLOWLOGPATH) =
    Mirror log path                         (MIRRORLOGPATH) =
    First active log file                                   = S0000062.LOG
    Block log on disk full                (BLK_LOG_DSK_FUL) = YES
    Percent max primary log space by transaction  (MAX_LOG) = 0
    Num. of active log files for 1 active UOW(NUM_LOG_SPAN) = 0
    Group commit count                          (MINCOMMIT) = 1
    Percent log file reclaimed before soft chckpt (SOFTMAX) = 300
    Log retain for recovery enabled             (LOGRETAIN) = OFF
    User exit for logging enabled                (USEREXIT) = OFF
    HADR database role                                      = STANDARD
    HADR local host name                  (HADR_LOCAL_HOST) =
    HADR local service name                (HADR_LOCAL_SVC) =
    HADR remote host name                (HADR_REMOTE_HOST) =
    HADR remote service name              (HADR_REMOTE_SVC) =
    HADR instance name of remote server  (HADR_REMOTE_INST) =
    HADR timeout value                       (HADR_TIMEOUT) = 120
    HADR log write synchronization mode     (HADR_SYNCMODE) = NEARSYNC
    First log archive method                 (LOGARCHMETH1) = OFF
    Options for logarchmeth1                  (LOGARCHOPT1) =
    Second log archive method                (LOGARCHMETH2) = OFF
    Options for logarchmeth2                  (LOGARCHOPT2) =
    Failover log archive path                (FAILARCHPATH) =
    Number of log archive retries on error   (NUMARCHRETRY) = 5
    Log archive retry Delay (secs)         (ARCHRETRYDELAY) = 20
    Vendor options                              (VENDOROPT) =
    Auto restart enabled                      (AUTORESTART) = ON
    Index re-creation time and redo index build  (INDEXREC) = SYSTEM (RESTART)
    Log pages during index build            (LOGINDEXBUILD) = OFF
    Default number of loadrec sessions    (DFT_LOADREC_SES) = 1
    Number of database backups to retain   (NUM_DB_BACKUPS) = 12
    Recovery history retention (days)     (REC_HIS_RETENTN) = 60
    TSM management class                    (TSM_MGMTCLASS) =
    TSM node name                            (TSM_NODENAME) =
    TSM owner                                   (TSM_OWNER) =
    TSM password                             (TSM_PASSWORD) =
    Automatic maintenance                      (AUTO_MAINT) = ON
       Automatic database backup            (AUTO_DB_BACKUP) = OFF
       Automatic table maintenance          (AUTO_TBL_MAINT) = ON
         Automatic runstats                  (AUTO_RUNSTATS) = ON
         Automatic statistics profiling    (AUTO_STATS_PROF) = OFF
           Automatic profile updates         (AUTO_PROF_UPD) = OFF
         Automatic reorganization               (AUTO_REORG) = OFF
    Before restoration it was "First active log file                                   = S0000062.LOG" and after restoration this parameter has not changed.
    db2diag.log >
    INSTANCE: db2dev               NODE : 000
    FUNCTION: DB2 UDB, routine_infrastructure, sqlerFmpListener, probe:999
    MESSAGE : FMP exiting with error. Last agent registered:
    DATA #1 : Hexdump, 4 bytes
    0x9FFFFFFFFFFFEEE4 : 0000 0000                                  ....
    2008-01-30-10.34.12.283359+330 I2618633502A1630   LEVEL: Event
    PID     : 12514                TID  : 1           PROC : db2start
    INSTANCE: db2dev               NODE : 000
    FUNCTION: DB2 UDB, base sys utilities, sqleStartStopSingleNode, probe:1130
    DATA #1 : String, 31 bytes
    /db2/db2dev/sqllib/adm/db2star2
    DATA #2 : Hexdump, 256 bytes
    0x9FFFFFFFFFFFBBC0 : 2F64 6232 2F64 6232 6465 762F 7371 6C6C    /db2/db2dev/sqll
    0x9FFFFFFFFFFFBBD0 : 6962 2F61 646D 2F64 6232 7374 6172 3200    ib/adm/db2star2.
    0x9FFFFFFFFFFFBBE0 : 4E4F 4D53 4700 0000 0000 0000 0000 0000    NOMSG...........
    0x9FFFFFFFFFFFBBF0 : 0000 0000 0000 0000 0000 0000 0000 0000    ................
    0x9FFFFFFFFFFFBC00 : 0000 0000 0000 0000 0000 0000 0000 0000    ................
    0x9FFFFFFFFFFFBC10 : 0000 0000 0000 0000 0000 0000 0000 0000    ................
    0x9FFFFFFFFFFFBC20 : 0000 0000 0000 0000 0000 0000 0000 0000    ................
    0x9FFFFFFFFFFFBC30 : 0000 0000 0000 0000 0000 0000 0000 0000    ................
    0x9FFFFFFFFFFFBC40 : 0000 0000 0000 0000 0000 0000 0000 0000    ................
    0x9FFFFFFFFFFFBC50 : 0000 0000 0000 0000 0000 0000 0000 0000    ................
    0x9FFFFFFFFFFFBC60 : 0000 0000 0000 0000 0000 0000 0000 0000    ................
    0x9FFFFFFFFFFFBC70 : 0000 0000 0000 0000 0000 0000 0000 0000    ................
    0x9FFFFFFFFFFFBC80 : 0000 0000 0000 0000 0000 0000 0000 0000    ................
    0x9FFFFFFFFFFFBC90 : 0000 0000 0000 0000 0000 0000 0000 0000    ................
    0x9FFFFFFFFFFFBCA0 : 0000 0000 0000 0000 0000 0000 0000 0000    ................
    0x9FFFFFFFFFFFBCB0 : 0000 0000 0000 0000 0000 0000 0000 0000    ................
    2008-01-30-10.34.14.121256+330 E2618635133A1198   LEVEL: Event
    PID     : 12517                TID  : 1           PROC : db2star2
    INSTANCE: db2dev               NODE : 000
    FUNCTION: DB2 UDB, base sys utilities, DB2StartMain, probe:911
    MESSAGE : ADM7513W  Database manager has started.
    START   : DB2 DBM
    DATA #1 : Build Level, 152 bytes
    Instance "db2dev" uses "64" bits and DB2 code release "SQL09011"
    with level identifier "01020107".
    Informational tokens are "DB2 v9.1.0.1", "s061104", "U809678", Fix Pack "1".
    DATA #2 : System Info, 104 bytes
    System: HP-UX ecldevqa B.11.23 U ia64
    CPU: total:6 online:6 Threading degree per core:1
    Physical Memory(MB): total:16354 free:9294
    Virtual  Memory(MB): total:49122 free:42062
    Swap     Memory(MB): total:32768 free:32768
    Kernel   Params: msgMaxMessageSize:65535 msgMsgMap:2048 msgMaxQueueIDs:512
                     msgNumberOfHeaders:2046 msgMaxQueueSize:65535
                     msgMaxSegmentSize:96 shmMax:17179869184 shmMin:1 shmIDs:400
                     shmSegments:300 semMap:2050 semIDs:2048 semNum:4096
                     semUndo:1024 semNumPerID:2048 semOps:500 semUndoPerProcess:100
                     semUndoSize:824 semMaxVal:32767 semAdjustOnExit:16384
    2008-01-30-10.34.50.661312+330 I2618636332A365    LEVEL: Warning
    PID     : 12533                TID  : 1           PROC : db2agent (DEV) 0
    INSTANCE: db2dev               NODE : 000
    APPHDL  : 0-7                  APPID: *LOCAL.db2dev.080130050450
    AUTHID  : DB2DEV
    FUNCTION: DB2 UDB, base sys utilities, sqleCheckForRestore, probe:10
    RETCODE : ZRC=0xFFFFFBA1=-1119
    2008-01-30-10.34.50.662169+330 I2618636698A373    LEVEL: Warning
    PID     : 12533                TID  : 1           PROC : db2agent (DEV) 0
    INSTANCE: db2dev               NODE : 000
    APPHDL  : 0-7                  APPID: *LOCAL.db2dev.080130050450
    AUTHID  : DB2DEV
    FUNCTION: DB2 UDB, base sys utilities, sqlePrepareForSerialization, probe:20
    RETCODE : ZRC=0xFFFFFBA1=-1119
    2008-01-30-10.34.50.662288+330 I2618637072A353    LEVEL: Severe
    PID     : 12533                TID  : 1           PROC : db2agent (DEV) 0
    INSTANCE: db2dev               NODE : 000
    APPHDL  : 0-7                  APPID: *LOCAL.db2dev.080130050450
    AUTHID  : DB2DEV
    FUNCTION: DB2 UDB, base sys utilities, sqleserl, probe:10
    RETCODE : ZRC=0xFFFFFBA1=-1119
    2008-01-30-10.43.19.986356+330 I2618637426A365    LEVEL: Warning
    PID     : 12532                TID  : 1           PROC : db2agent (DEV) 0
    INSTANCE: db2dev               NODE : 000
    APPHDL  : 0-10                 APPID: *LOCAL.db2dev.080130051319
    AUTHID  : DB2DEV
    FUNCTION: DB2 UDB, base sys utilities, sqleCheckForRestore, probe:10
    RETCODE : ZRC=0xFFFFFBA1=-1119
    2008-01-30-10.43.19.987187+330 I2618637792A373    LEVEL: Warning
    PID     : 12532                TID  : 1           PROC : db2agent (DEV) 0
    INSTANCE: db2dev               NODE : 000
    APPHDL  : 0-10                 APPID: *LOCAL.db2dev.080130051319
    AUTHID  : DB2DEV
    FUNCTION: DB2 UDB, base sys utilities, sqlePrepareForSerialization, probe:20
    RETCODE : ZRC=0xFFFFFBA1=-1119
    2008-01-30-10.43.19.987305+330 I2618638166A353    LEVEL: Severe
    PID     : 12532                TID  : 1           PROC : db2agent (DEV) 0
    INSTANCE: db2dev               NODE : 000
    APPHDL  : 0-10                 APPID: *LOCAL.db2dev.080130051319
    AUTHID  : DB2DEV
    FUNCTION: DB2 UDB, base sys utilities, sqleserl, probe:10
    RETCODE : ZRC=0xFFFFFBA1=-1119
    ecldevqa:db2dev 20>
    Thanks & Regards, 
    Gautam Poddar 
    SAP BASIS 
    PricewaterhouseCoopers (P) Limited

    Hi Gautam
    As Adam said ....
    1. never manually move db2 active log files
    2. IBM does not support filesystem restores.
    The only solution for you is to restore the offline backup and if you have archive logs, then you can do a rollforward .
    Amit
    Edited by: amit chak on Aug 19, 2008 8:07 PM

  • Can't save BISM file pointing to excel sheet (data source). ErrMsg: "There were errors found while validating the page: Cannot connect to the server or database."

    Hi,
    Me and a collegue is administrering our new enterprise BI portal in SharePoint 2013 (On Premise) and have a problem with using a specific Excel file including general ledger data as data source through a BISM file.
    This particular BISM file can't be saved without getting the error message "There were errors found while validating the page: Cannot connect to the server or database."
    BISM files against other Excel sheets and sources (for example SSAS tabular databases) works well.
    Can anyone help us pinpointing whats wrong here, this is a really important stakeholder in our organization requesting this reporting?
    Cheers!

    Hi E.SWARD ,
    My self created a Power pivot excel then i want to use this excel to create BI file . Still i am getting the same error . Pls help me to resolve this issue
    Cannot connect to the server or database.
    I am getting the similar error , if i use Tabular analysis server instance .
    Subhash

  • Error message when trying to connect to a SQL Server Database

    All:
    I get the following message when I try to connect to a SQL Server Database within a form:
    "Connection for Source DataConnection failed because the environment is not trusted"
    Can anyone help me solve this problem?
    Thanks,
    BR

    Hi Brian,
    In Acrobat, security concerns dictate that you cannot specify an ODBC connection string by using the Driver=; syntax. Therefore, the client computer using the form needs to have a DSN pre-configured for ODBC connections.
    Denver
    Adobe Enterprise Developer Support

  • How to connect captivate file in a database (MS SQL SERVER 2008)

    Hi...
    How to connect captivate file in a database (MS SQL SERVER 2008) ???
    Kindly response please..
    thanks!!!

    Hi there
    See if the link below helps you out.
    Click here to view
    Cheers... Rick
    Helpful and Handy Links
    Captivate Wish Form/Bug Reporting Form
    Adobe Certified Captivate Training
    SorcerStone Blog
    Captivate eBooks

  • How to determine the connection string to a SQLite database, in C# code

    Hello. I'm trying to figure out how to specify the connection string to a SQLite database, I would like to access using the following code:
    string connectionString = null;
    SqlConnection connection;
    SqlCommand command;
    SqlDataAdapter adapter = new SqlDataAdapter();
    DataSet ds1 = new DataSet();
    string sql = "SELECT DataName, Data, Id, UserId, DateLastUpdated FROM MainTable";
    connectionString = "Data Source=C:\\SQLITEDATABASES\\SQLITEDB1.sqlite;Version=3;";
    connection = new SqlConnection(connectionString);
    try
    connection.Open();
    command = new SqlCommand(sql, connection);
    catch
    The value I assigned to the variable connectionString, in the code above, I obtained somewhere from the Internet. It does not work. I'm using Visual Studio 2013, against the file sqlite-netFx451-setup-bundle-x86-2013-1.0.96.0.exe, which
    I installed, and got from
    here.
    My application's App.config file looks as follows:
    <?xml version="1.0" encoding="utf-8"?>
    <configuration>
    <configSections>
    </configSections>
    <connectionStrings>
    <add name="DC_Password_Saver.Properties.Settings.DC_Password_SaverConnectionString" connectionString="data source=&quot;C:\Users\patmo_000\Documents\Visual Studio 2013\Projects\DC Password Saver\DC Password Saver\DC Password Saver.db&quot;" providerName="System.Data.SQLite.EF6"/>
    </connectionStrings>
    <startup>
    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.1"/>
    </startup>
    </configuration>
    I tried to use the value assigned to connectionString in the XML settings above, replacing single backslash characters with double backslash characters, because the Visual Studio editor flagged them as unrecognizable, and wound up with the
    following.
    SqlDataAdapter adapter = new SqlDataAdapter();
    DataSet ds1 = new DataSet();
    string sql = "SELECT DataName, Data, Id, UserId, DateLastUpdated FROM MainTable";
    connectionString = "data source=&quot;C:\\Users\\patmo_000\\Documents\\Visual Studio 2013\\Projects\\DC Password Saver\\DC Password Saver\\DC Password Saver.db&quot;";
    connection = new SqlConnection(connectionString);
    The above code however does not work either. So again, does anyone know how I can specify in C# code, a connection string to access my SQLite database? Thanks in advance for your reply.

    What does SQLite connection strings has to do with WPF?
    You will find some valid connection strings here:
    https://www.connectionstrings.com/sqlite/
    But you cannot use the SqlConnection class to connect to a SQLite database. You will need to download and add a reference to the System.Data.SQLite library and then use the SQLiteConnection class:
    connection = new System.Data.SQLite.SQLiteConnection(connectionString);
    try
    connection.Open();
    command = new System.Data.SQLite.SQLiteCommand(sql, connection);
    catch
    Please refer to the following article for more information and an example of how to connect and read and write data from an SQLite database using C#:
    http://blog.tigrangasparian.com/2012/02/09/getting-started-with-sqlite-in-c-part-one/.
    There is contains a link where you can download the required assemblies.
    Hope that helps.
    Please remember to mark helpful posts as answer to close your threads and then start a new thread in an approproate forum if you have a new question.

  • Best practise for creating an application that connects to a SQL Server database

    I have created an application that connects to a SQL Server database and views information using a datagrid and performs several updates when a button
    is selected.  
    I have created a SQLcontrol.vb using the following code:
    Imports System.Data.Sql
    Imports System.Data.SqlClient
    Public Class SQlControl
    'connection 1
        Public SQLCon As New SqlConnection With {.ConnectionString
    = "Data Source=;Initial Catalog=;Integrated Security=True"}
    'connection 2
        Public SQLCon1 As New SqlConnection With {.ConnectionString
    = "Data Source;Initial Catalog=;Integrated Security=True"}
        Public sqlcmd As SqlCommand
        Public sqlda As SqlDataAdapter
        Public sqldataset As DataSet
        Public Function hasconnection() As Boolean
            Try
                SQLCon.open()
                SQLCon.close()
                Return True
            Catch ex As Exception
                MsgBox(ex.Message)
                Return False
            End Try
        End Function
        Public Sub runquery(query As String)
            Try
                SQLCon.Open()
                sqlcmd = New SqlCommand(query,
    SQLCon)
                'LOAD
    SQL RECORDS FOR DATAGROD
                sqlda = New SqlDataAdapter(sqlcmd)
                sqldataset = New DataSet
                sqlda.Fill(sqldataset)
    BH READ DIRECTLY FROM THE DATABASE
                'Dim
    R As SqlDataReader = sqlcmd.ExecuteReader
                'While
    R.Read
                'MsgBox(R.GetName(0)
    & ": " & R(0))
                'End
    While
                SQLCon.Close()
            Catch ex As Exception
                MsgBox(ex.Message)
                'will
    close connection if still open
                If SQLCon.State
    = ConnectionState.Open Then
                    SQLCon.Close()
                End If
            End Try
        End Sub
        Public Sub runquery1(query As String)
            Try
                SQLCon1.Open()
                sqlcmd = New SqlCommand(query,
    SQLCon1)
                'LOAD
    SQL RECORDS FOR DATAGROD
                sqlda = New SqlDataAdapter(sqlcmd)
                sqldataset = New DataSet
                sqlda.Fill(sqldataset)
    BH READ DIRECTLY FROM THE DATABASE
                'Dim
    R As SqlDataReader = sqlcmd.ExecuteReader
                'While
    R.Read
                'MsgBox(R.GetName(0)
    & ": " & R(0))
                'End
    While
                SQLCon1.Close()
            Catch ex As Exception
                MsgBox(ex.Message)
                'will
    close connection if still open
                If SQLCon1.State
    = ConnectionState.Open Then
                    SQLCon1.Close()
                End If
            End Try
        End Sub
    End Class
    A code for one of my button which views displays data grid contains the following code:
    Private Sub Button1_Click_1(sender As Object,
    e As EventArgs) Handles Button1.Click
            If SQL.hasconnection
    = True Then
                SQL.runquery("select 
    * from tablea")
                If SQL.sqldataset.Tables.Count
    > 0 Then
                    DGVData.DataSource = SQL.sqldataset.Tables(0)
                End If
            End If
        End Sub
    I am fairly new to vb.net and have read a few books and followed a few tutorials on youtube, what I would like to know is, are there any disadvantages
    to the way I have connected to a SQL database using the SQLControl.vb.  A lot of the vb books include data adapter and dataset within the form, I'm not sure if I'm following best practice by have the connection details outside of the form.
    My other question is, I have created two connections in the SQLControl and call these connections within the same form using the same data adapter
    and dataset.  It all works fine but I just wanted to know of any potential issues?
    Public SQLCon As New SqlConnection With {.ConnectionString
    = "Data Source=;Initial Catalog=;Integrated Security=True"}
    'connection 2
        Public SQLCon1 As New SqlConnection With {.ConnectionString
    = "Data Source;Initial Catalog=;Integrated Security=True"}
    Thanks

    My other question is, I have created two connections in the SQLControl and call these connections within the same form using the same data adapter and dataset.  It all works fine but
    I just wanted to know of any potential issues
    1) You are not using Sepration of concerns for a solution that is doing data access, like using a DAL.
    http://en.wikipedia.org/wiki/Separation_of_concerns
    2) You are directly issuing SQL commands at the UI, leading to sql injection attacks.
    3) You are not using a UI design pattern, which leads you to tightly couple database activity to the UI.
    http://www.codeproject.com/Articles/228214/Understanding-Basics-of-UI-Design-Pattern-MVC-MVP
    @System243trd, parameters are important to prevent SQL injection attacks (people will insert SQL commands into the database if you do not perform basic checking of what you are passing to the database). If you write a stored procedure try to make
    the variables the correct SQL server data type to avoid problems later of people trying to call it directly.  Darnold924 is right, I see no code to prevent against SQL injection attacks. In addition, during development in some instances LocalSQLDB
    database system is used and during deployment you usually need to use the production SQL server database. Moreover,  Linq-to-SQL is used on Windows Phone 8.1 and it is required for phone development later and so I highly recommend learning
    it if you plan on developing windows phone applications.
    @System243trd, If you want the code for the windows phone app I think it uses the MVVM model or that might be for universal apps or regular windows phone apps. I have been using the windows phone Silverlight pivot or panorama template (it might
    be pieces of both). I've already submitted to the windows phone marketplace and it had to go through certification first. I plan on later making an article on it but I need to first fix one or two simple problems I have with it.  Here's a link to
    the source code if you later want to look at the source code (in vb.net): 
    https://jeffsblogcodesamples.codeplex.com/downloads/get/1445836
    Once you eliminate the impossible, whatever remains, no matter how improbable, must be the truth. - Sherlock Holmes. speak softly and carry a big stick - theodore roosevelt. Fear leads to anger, anger leads to hate, hate leads to suffering - Yoda. Blog
    - http://www.computerprofessions.us

  • Problem in OWB: connecting to a non-oracle database

    Good day,
    i'm working on a windows 32 bit machine,i have Oracle database , OWB 11.2.0.1 installed on it
    i'm trying to make OWB connect to a "Sybase" source database on another server , using ODBC
    i've tested the connection from SQLPLUS and it's working perfectly
    but when i test the connection from OWB locations , it gives me this error:
    "ORA-28500: connection from ORACLE to a non-Oracle system returned this message:
    [OpenLink][ODBC][SQL Server]Statement(s) could not be prepared (0)
    {42000}[OpenLink][ODBC][SQL Server]"DUAL" not found. Specify owner.objectname
    or use sp_help to check whether the object exists (sp_help may produce lots of
    output).
    (208) {42S02,NativeErr = 208}
    my questions are :
    -why would OWB check for DUAL table on a sybase database? is that a bug in OWB?
    -can i bypass this step and just import metadata from the sybase source database? (i tried importing,but OWB performs the same test before importing)

    Hi Chris,
    I haven't tried it, and these are just some of my thoughts, but I
    think you would need to load the JDBC driver for the other database
    into the Oracle database (using the "loadjava" tool, of-course).
    Then your java stored procedure should be able to instantiate the
    third party JDBC driver and obtain a connection to the other database.
    Hope this helps.
    Good Luck,
    Avi.

  • CONNECTING ORACLE 9I OR 10G DATABASE WITH ORACLE 10G FORMS AND REPORTS

    pls tell how to connect oracle 9i or 10g database with oracle developer suite 10g . though the forms are getting connected but not running with error as
    FRM-10142 the HTTP listner is not running on pls start the listner or check your runtime preferences.
    now pls tell how to start listner and how to chage runtime preferences.
    though i have worked with oracle 9i and forms 6i where we used to copy the tnsnames.ora from network/admin of oracle to forms 6i tnsnames.ora.
    thank you, you may be thinking such a long question.....

    sir
    By server i mean the computer where oc4j and backend database are running is one one of the client pc not a dedicated server..., these database and 10g dev suite are installed in one of the client machine,
    all the clients are using same internet explorer as browser.
    no message is being displyed on some of the client machine where these forms are not being uploaded on browser instead it displays as done in status bar without actually showing anything at all...
    sir so far as jinitiator or JRE is concered i have seen on the client machine (where my forms are running on internet explorer) a pop up is displyed telling one activex control is required to run this program and click to install it..
    after clicking it download jinitiator from server and after installing jinitiator my forms are loaded and start functioning...
    what i feel is as i said this machine where oc4j and database is running is one of the client machine so some other clients do not have acess to this machine, so this might be the reason why those clints are not able to run the said forms on the internet explorer.... can it be so... kindly tell..
    thank you for your patience for reading the question

  • Can I connect my form to a database to populate data?

    Can I connect my form to a database to populate data?

    Hi;
    You want to poplulate your form with data from a database, or to populate the database from the form?
    There isn't any way to import the data into the form in FormsCentral from a database.  To populate and external database from the table on the View Responses tab there are no APIs to do it automatically but you can export to Excel or CSV and then import the Excel or CSV into your database:  http://forums.adobe.com/docs/DOC-1383
    Thanks,
    Josh

  • Oracle 11.2 client connecting to Oracle 10.2 databases

    I have an application which currently uses 10.2.0.4 Oracle Client to connect to Oracle 10.2 databases using java (jdbc).
    Now I have to do setup on another linux server and looking into whether I can use 11.2 Oracle clinet avaiable on tcehnet.oracle.com to connect to
    10.2 databases. I will be using jdbc for connectivity.

    Maybe showing my ignorance here, but doesn't the application itself have to be written to use the jdbc thin driver?
    That would not be typical. A Java application will normally be modular as regards DB connections.
    1. The app itself will be written to take an instance of the 'Connection' interface
    http://docs.oracle.com/javase/6/docs/api/java/sql/Connection.html
    2. The actual 'Connection' instance will be created by a factory method or other application independent code at startup and then passed to the application code.
    Just like TNSNAMES.ORA contains the parameters for OCI connections an application will normally use a config file and/or command-line parameters for the JDBC connection parameters.
    Naturally, just like everything else, developers can always screw things up by hard coding values. Nothing you can do about that.
    See the 'Database URLs and Database Specifiers' section of the JDBC dev guide
    http://docs.oracle.com/cd/E11882_01/java.112/e16548/urls.htm#BEIJFHHB
    Database URLs are strings. The complete URL syntax is:
    jdbc:oracle:driver_type:[username/password]@database_specifier 
    Note:
      The brackets indicate that the username/password pair is optional.
      kprb, the internal server-side driver, uses an implicit connection. Database URLs for the server-side driver end after the driver_type.
    The first part of the URL specifies which JDBC driver is to be used. The supported driver_type values are thin, oci, and kprb.
    The remainder of the URL contains an optional user name and password separated by a slash, an @, and the
    database specifier, which uniquely identifies the database to which the application is connected. Some database specifiers are valid only for the JDBC Thin driver, some only for the JDBC OCI driver, and some for both.
    Then there are examples of each driver type in 'Table 8-3 Supported Database Specifiers'
    Thin: "jdbc:oracle:thin:scott/tiger@//myhost:1521/myservicename"
    See that table 8-3 for the different OCI options.

  • Connecting SPSS to my oracle database

    Hello I am trying to connect my SPSS to our database.
    My system includes:
    SPSS 14
    Oracle 8.17
    Windows XP
    and now Oracle 10g
    (I am not very computer literate, so if you need more info let me know)
    I initially did not have Oracle 10g on my computer, but it was suggested I try it out.
    I still get an error, but now its a different error.
    Before installing 10g, I was using the SPSS OEM 5.0 Oracle driver to try to connect and was getting the following error:
    SQL driverconnect failed: Specified driver could not be loaded due to system error 127. (SPSS OEM 5.0 Oracle)
    Now after I installed 10g, I tried both the SPSS OEM 5.0 Oracle driver and the
    Oracle in OraClient10g_home1 driver and I get the following error:
    TNS:could not resolve the connect identifier specified.
    Any help would be greatly appreciated.

    You have two different tnsnames.ora files.
    Which one you use depends on the database you connect to.
    The two files are not in sync which is why you are getting this error.
    You need to sync them and/or set TNS_ADMIN to the directory of one of those files.
    TNS_ADMIN is a string value in the registry in hkey\local_machine\software\oracle
    Sybrand Bakker
    Senior Oracle DBA

  • Connecting to Oracle 8i.7 Database on Application Server 10g (10.1.2)

    Hi
    Dear All
    i have gust installed Oracle Application Infrastructure & middle tire 10g(10.1.2)
    and i am asking
    for the capability to connect (After Configuring Tnsname) to Oracle Database 8i(8.1.7.0.0)
    the message after trying to connect is :
    Connecting to This Version of database is no longer supported ..!
    and please i want clarification note if we can't connect to give my officer so we can discuss the upgrade for database to 10g.
    Best Regards .
    Ibrahim.

    Bug 3437884 - 10g client cannot connect to 8.1.7.0 - 8.1.7.3 server : if your Customer needs to stay on 8i, then the last available patch should be applied.
    10.1.4 Client (the one used by AS 10.1.2) shouldn't have problems with 8.1.7.4 DB.

  • "Could not connect to the ConfigMgr site database" problem with SCCM

    The scenario is:
    - SCCM 2007 SP1 installed on one server
    - SQL 2008 installed on the other server
    - Console was also installed on the SCCM server.
    Everything was working just fine for about three months. As of few days ago, out of nowhere, I cannot open the console at all, it gives me this error:
    " The ConfigMgr console could not connect to the ConfigMgr site database. Verify that this computer has network connectivity to the SMS Provider computer and that your user account has Remote Activation permissions on both
    the ConfigMgr site server and SMS Provider computers. For more information, see "How to Configure DCOM Permissions for Configuration Manager Console Connections" in ConfigMgr Help. "
    I confirmed all permissions (DCOM) and group settings (SMS Admin) and everything looks fine. I also noticed one other thing and I have a feeling its related - I log on to SCCM server and then from there I try to start RDP
    connection to SQL server. I can connect, but as soon as I move the mouse or try clicking somewhere it breaks the connection and the "Trying to re-connect" window appears. It can`t establish normal RDP connection. If I try from any other server to SQL, it works
    fine...
    Any suggestions will be appreciated.
    Dino

    looks like I celebrated way too early - after working for about 20 minutes, it started throwing the same error again. Th adminUI log has this entry:
    ===========================================================================================================0
    [3][13.4.2011 13:33:45] :Error returned from WMI Query Engine\r\nMicrosoft.ConfigurationManagement.ManagementProvider.WqlQueryEngine.WqlQueryException\r\nThe ConfigMgr Provider reported an error connecting to the ConfigMgr site database server. Verify
    that the SQL Server is online and that ConfigMgr site server computer account is an administrator on the ConfigMgr site database server.\r\n   at Microsoft.ConfigurationManagement.ManagementProvider.WqlQueryEngine.WqlQueryResultsObject.<GetEnumerator>d__0.MoveNext()
       at Microsoft.ConfigurationManagement.ManagementProvider.WqlQueryEngine.WqlQueryProcessor.ProcessQueryWorker(AsyncOperationDatabase asyncData)
       at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(IntPtr md, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInContext, Object[]& outArgs)
       at System.Runtime.Remoting.Messaging.StackBuilderSink.AsyncProcessMessage(IMessage msg, IMessageSink replySink)\r\nConfigMgr Error Object:
    instance of SMS_ExtendedStatus
        CauseInfo = "";
        Description = "Unable to get SQL connection.";
        ErrorCode = 3242263810;
        File = "e:\\nts_sms_fre\\sms\\siteserver\\sdk_provider\\smsprov\\sspobjectquery.cpp";
        Line = 1861;
        Operation = "ExecQuery";
        ParameterInfo = "select * from SMS_ConfigurationBaselineInfo where UPPER(CI_UniqueID) NOT IN (SELECT UPPER(InstanceKey) FROM SMS_ObjectContainerItem WHERE ObjectType=2011) ORDER BY LocalizedDisplayName";
        ProviderName = "WinMgmt";
        SQLMessage = "[08S01][11][Microsoft][ODBC SQL Server Driver][DBNETLIB]General network error. Check your network documentation.";
        SQLSeverity = 0;
        SQLStatus = 11;
        StatusCode = 2147749889;
    Unable to get SQL connection.
    \r\nSystem.Management.ManagementException\r\nGeneric failure \r\n   at System.Management.ManagementException.ThrowWithExtendedInfo(ManagementStatus errorCode)
       at System.Management.ManagementObjectCollection.ManagementObjectEnumerator.MoveNext()
       at Microsoft.ConfigurationManagement.ManagementProvider.WqlQueryEngine.WqlQueryResultsObject.<GetEnumerator>d__0.MoveNext()\r\nManagementException details:
    instance of SMS_ExtendedStatus
        CauseInfo = "";
        Description = "Unable to get SQL connection.";
        ErrorCode = 3242263810;
        File = "e:\\nts_sms_fre\\sms\\siteserver\\sdk_provider\\smsprov\\sspobjectquery.cpp";
        Line = 1861;
        Operation = "ExecQuery";
        ParameterInfo = "select * from SMS_ConfigurationBaselineInfo where UPPER(CI_UniqueID) NOT IN (SELECT UPPER(InstanceKey) FROM SMS_ObjectContainerItem WHERE ObjectType=2011) ORDER BY LocalizedDisplayName";
        ProviderName = "WinMgmt";
        SQLMessage = "[08S01][11][Microsoft][ODBC SQL Server Driver][DBNETLIB]General network error. Check your network documentation.";
        SQLSeverity = 0;
        SQLStatus = 11;
        StatusCode = 2147749889;
    \r\n
    ====================================================================================================
    As I mentioned in my first post, the RDP from SCCM to SQL servers is not working and I think that is related to my problem....suggestions?

Maybe you are looking for