Create an InterBase database programmatically using ADO?

Is there a way to connect to ADMIN.IB (or some other "always exists" item) in InterBase using a dbGO ADOConnection and the DataDirect ODBC driver, then fire off a 'CREATE DATABASE ..." statement?
0
rich
1/28/2009 11:58:48 PM
embarcadero.delphi.ado 597 articles. 1 followers. Follow

3 Replies
1122 Views

Similar Articles

[PageSpeed] 55
Get it on Google Play
Get it on Apple App Store

"rich k" wrote in message news:73953@forums.codegear.com...
> Is there a way to connect to ADMIN.IB (or some other "always exists" item) 
> in InterBase using a dbGO ADOConnection and the DataDirect ODBC driver, 
> then fire off a 'CREATE DATABASE ..." statement?

Admin.db is a normal database, so you can certainly connect to it.

I've never actually tried to execute a create database statement within an 
application though but I think it should work.

-- 
Wayne Niddery - TeamB (www.teamb.com)
Tips to Get Published: http://dn.codegear.com/article/38467
Winwright, Inc. (www.winwright.ca)
0
Wayne
1/29/2009 5:20:11 PM
> {quote:title=Wayne Niddery wrote:}{quote}
> 
> I've never actually tried to execute a create database statement within an 
> application though but I think it should work.

I've tried, but keep getting a "cannot prepare a CREATE DATABASE/SCHEMA statement" error. So, I don't know if I'm doing something wrong or if it is just not allowed.
0
rich
1/29/2009 5:48:44 PM
rich k wrote:

> I've tried, but keep getting a "cannot prepare a CREATE
> DATABASE/SCHEMA statement" error. So, I don't know if I'm
> doing something wrong or if it is just not allowed.

Another alternative, if all else fails, is to ShellExecute
isql and run a script that creates the database.

-- 
Bill Todd (TeamB)
0
Bill
1/29/2009 7:39:07 PM
Reply:

Similar Artilces:

ASA7 ADO & Delphi ADO ?? Anyone is using it?
Any comments? Is it working? Any Problems? Thanks Hi, PR <noemail@no.com> schrieb in im Newsbeitrag: BoTThJaq$GA.89@forums.sybase.com... > Any comments? Is it working? Any Problems? I tried to connect to ASA7 via the new OLE DB - Provider and ADOExpress from Delphi 5.01. No chance. Only the error message 'Invalid Enum Value'. About the new provider I haven't heard anything good until now... Regards Frank Frank, I've experienced the same problem with the ASA 7 OLEDB Provider. I'm not sure if this is a bug in the AsaProvider or Delp...

pb. with creating new database using ADO Object
I would like to find the name of all tables for a Sybase database with the ADO Object. I make a Microsoft Visual C++ 6.0 Professionnel Edition application (Windows 95) with ADO Object and my code is : if(iTypeDatabase==0) strConnection =L"DRIVER={Adaptive Server Anywhere 6.0};PWD=sql;UID=dba;" L"AStart=TRUE;AStop=TRUE;DMRF=TRUE;" L"DBF="+CString(pathBase)+";"; if(iTypeDatabase==1) strConnection = L"DRIVER={Microsoft Access Driver (*.mdb)};" L"DBQ="+CString(pathBase)+";"; tmpConnect->Connection...

Convert Delphi 5 ADO App to Delphi 2007 ADO.NET
I have an appliction tha that is writen in Delphi 5 with ADOConnetion, ADOTable, and ADOQuery components. I need to upgrade to Delphi 2007 and use ADO.NET. I have the program building in with Delphi 2007. Is there anything I need to do to convert the ADO to ADO.NET? > I need to upgrade to Delphi 2007 and use ADO.NET. Why ? -- With best regards, Dmitry Arefiev AnyDAC (www.anydac.com) - Oracle, MS SQL Server, IBM DB2, MySQL, Firebird, Interbase, PostgreSQL, Sybase ASA, SQLite, MS Access, DBX, ODBC, InMem - universal high-speed native data access engine Reasons for ...

ADO error creating database
im creating a ecommerce website, and i need to create a database, im using visual studio .net and when i try to create a new database using VS.net i choose "use sql server authentication" and no matter what i type in for the login id, i get the following ado error "ADO Error : ' Login failed for user "blank". Reason. Not associated with a trusted SQL server connection.' thanks in advance. is the sql server on a different machine? no its on my machine. im using xp pro. is that ok? or am I trying to do something thats not possible? and you're sure you kn...

ADO to ADO.NET
I'm an ASP programmer (VBScript) moving on to ASP.NET. So far I'm using:Microsoft Visual Studio 2003ASP.NET with C#I'm working on converting my code over to C#, from VBScript. Now, here is my code in VBScript (modified to better understand it, this is a edited ugly version):Function ExecuteSQL(sqlStatement)    ConnDriver = "Provider=SQLOLEDB; Data Source = " & dbIP & "; Initial Catalog = " & dbName & "; User Id = " & dbUser & "; Password=" & dbPassword     Set connTemp = Server.CreateObject("ADODB.Connection")    c...

ADO not ADO.NET
Hi, I have to connect to a db using adodb (which i select from the references). I have to retrieve the car models from the database and bind them to a listbox. I am not sure how to proceed and I can't find any articles on ADO with .net and data binding. Here is the code that i tried but it only retrieves the car model for the specified id. If I delete the id it doesn't work. Also it writes the car model in the listbox vertically such as: B M W CODE: Imports System.Data Imports ADODB Imports System.Data.OleDb Public Class listboxADO Inherits System.Web.UI...

Using encapsulation with ADO databases?
Hi I'm currently creating a small web based system in c# and am in the process of creating the user classes, and am unfamiliar with using the SQL side of asp.net. The problem I am having is that as normal (in an encapsulated offline program) I have created a class "User.cs" (the object) and then "UserControl.cs" which deals with creation/deletion/update etc. How do I now go about adding the user object into a database, without having to add each of its attributes seperately (calling the User's get methods)? Once the user is passed via my method from the main page (U...

ADO.NET: Database is in use
ADO.NET: Database is in use   Hi dudes, I have an ASP.NET WebApplication Project that has some .aspx pages. And I use ADO.NET to Connect to a Microsoft Access database. (*.mdb)   And I have noticed that: when many users in one time want to view an ASP.NET Page that uses an OleDbConnection to connect to database, it causes an error that database is  already in use.   Here is an example:   Dim ConnStr As String = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + Server.MapPath("/database.mdb")   Dim Conn As New OleDb.OleDbConnection(ConnStr) Conn.Open...

What are the diff. ADO and ADO.NET and which is use full and easy ?
What are the diff. ADO and ADO.NET and which is use full and easy ? You use ADO with ASP and ADO.NET with ASP.NET. Both are useful in their own environments and can get the job done. Both can be easy or difficult, it depends on your background, training, available resources, and a host of other factors. There are lots and lots of articles on the net on this topic. Search Google for: ADO "ADO.NET" comparison E.g. MSDN article Comparison of ADO.NET and ADO DevArticles article A Practical Comparison of ADO and ADO.NET TerriTerri MortonEngagement Manager, Neud...

I can't creating database when i using Creat database.
I get a fail meg. like SQL error (-143)- column '@database_version' not found. Yes i think the problem can be at i have installed an ebf.......... but is it ? regards christian I had the same problem. I accidentally had 6.02 and 5.xx on my machine. My system path was finding the 5.xx libraries first, but I was running Create Database from 6.02 Sybase Central. Once I deleted the 5.xx directory and cleaned up my path the problem went away. Hope that helps. Christian Jonasson <christian.jonasson@brightid.se> wrote in message news:Necypc6S$GA.98@forums.sybase....

We Need ADO Wrapper Class Methods using Ado.net
We Need clue / suggesion for writing the ADO Wrapper Class Methods below using Ado.netAny one example for any method will help1) getBookmark()2) setBookmark(currentBM)3) Delete ()4) close ()5) getStatus()6) getDataSource()7) DataMember()8) Update(Fields,Values)9) ActiveConnection()Thanks in Advance. You don't say what language you are using (VB or C#), but all you have to do is to create a Function or method and put your ADO.NET code in it.For example, Delete() will obviously have to take a parameter, such as an integer, or array of integers, and the code within it will loop through t...

Use date from database (Access) with ADO
I try to use ADO.NET for recieve data from database.Before I send data is "7/8/03" when I get data it is "7/8/03 0:00:00". How I do ? How do you what? What is it you want to do but cannot. Presuming you want to display the date only, get the value from ADO.NET into a DateTime object, and then to display it, use .ToShortDate() method of the DateTime type. In Access, the only type is a Date and Time type (together). You can display just the time or just the date if you wish, but internally there will always be a date and time.Starting with ASP.NET 2.0? Look at:Pr...

ADO.NET: Use Database Transactions
 Database transactions are used to control data commitment to databases. For example, in standard account procedures, it is necessary to debit one account and credit another at the same time. Since computers break down on occasion (power outages, network outages, and so on) there is the potential for one record to be updated or added, but not the other. To avoid these situations, transactions are used. Transactions in ADO.NET are, just as in ADO, handled at the database level: your database must support transactions. There are three basic commands ...

Deploying Delphi software which uses ADO
Hi what needs to deployed and provided by Installaware type packages to get Delphi-based programs that use ADO to install on Windows 7 32 bit and 64 bit computers? When Googling for stuff I keep getting older information plus some comments that the Jet Engine is no longer fully supported for Windows 7 environments. Suggestions or links to good descriptions would be appreciated. Bruce On 2012-09-19 16:13:51, Bruce Eglington wrote: > what needs to deployed and provided by Installaware type packages > to get Delphi-based programs that use ADO to install on Windows 7 32...

Web resources about - Create an InterBase database programmatically using ADO? - embarcadero.delphi.ado

[...] How to Programmatically Administer Off-Facebook Pages with the Open Graph API - Inside Facebook ...
With the Open Graph protocol that Facebook announced at last week’s f8 conference, any URL can now be treated just like a Facebook Page. After ...

Well, This Is Different Time Inc. Now Selling Print Ads Programmatically
Machines are now selling some print ads at Time Inc. The nation's largest magazine publisher owner of People, Time, Sports Illustrated and InStyle ...

Now Marketers Can Buy Sponsored Content Programmatically
Publishers' branded content is going programmatic. Today, Sharethrough and AppNexus are rolling out real-time bidding for Sharethrough's news ...

Wesabe makes Financial Data available programmatically
Wesabe has just done what I've been trying to convince banks to do for years. They're making financial data available via a simple POX (Plain ...

IPG Begins Buying Local Broadcast Programmatically: Can Target, Retarget Viewers In Near Real-Time
In what likely is the most significant development yet to bring programmatic media-buying to local broadcast television, Interpublic's Mediabrands ...

Google Launches Cloud SQL API To Allow Developers To Manage Their Databases Programmatically
... to use Google’s admin interface. Today, however, Google is launching the Cloud SQL API . This new REST API will allow developers to programmatically ...

Are Programmatically Purchased Native Ads Native Enough?
It seems everyone and their mothers are pushing native ad units and tools to support them. Facebook, Twitter, Yahoo and most recently AOL all ...

Most Major U.S. Publishers Now Sell Ads Programmatically
Most major online publishers in the U.S. now sell at least some of their ad space using automated "programmatic" technology, according to new ...

TV Ads Could Soon Be Sold Programmatically, Magna’s Todd Gordon
The key efficiency new-wave digital media sales holds over TV is clear – super-targeting through addressable, automated and programmatic buying ...

How To Use Facebook's New Power Editor For Ads
Here's a guide to the power editor in Facebook's ad manager.

resources last updated: 11/20/2015 4:17:57 PM