Not at this stage, but it's a simple matter to write it.
You can wait for me to do it (put a request in the RFE section) or you can write it yourself (I'd appreciate the code if you do). It's pretty much a matter of copying the msaccess (oledb) one and changing the references to odbc.
I probably won't be able to do it for a week or two as I am travelling at the moment.
- Richard
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Yes you will need the ODBC code, but you need to get it from CVS. Specifically you need to get the latest versions of
CConnection.vb
CODBCDatabase.vb
AtomsFramework.vbproj
It wouldn't hurt to get CPersistenceBroker.vb and CCacheEntry.vb as they contain a few bug fixes from the 1.20 release.
If you can't get the code from CVS for whatever reason send me your email address and I can mail you a zip file with the latest code in it.
- Richard
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi,
Very good, the conection by ODBC is correct.But, the field oid in the each table is necesary?, My table has the following structure:
CREATE TABLE "ERPG"."TIPOPORTE"
("CODIGOTIPOPORTE" Integer NOT NULL,
"NOMBRE" Varchar (100) ASCII NOT NULL,
"IDEMPLEADO" Integer,
PRIMARY KEY ("CODIGOTIPOPORTE"))
CodigotipoPorte is my primary key, My XML is the following one:
Hi,
Can use ODBC to connect a database.
I see that only use Mysql, slqClient and oledb.
Not at this stage, but it's a simple matter to write it.
You can wait for me to do it (put a request in the RFE section) or you can write it yourself (I'd appreciate the code if you do). It's pretty much a matter of copying the msaccess (oledb) one and changing the references to odbc.
I probably won't be able to do it for a week or two as I am travelling at the moment.
- Richard
Actually, never mind that last message.
I've already added the code and updated CVS.
To use the ODBC data source set the class to CODBCDatabase in the XML file, and set the "name" parameter to the ODBC connection string.
I've used a connection string here, instead of requesting parameters as there are too many variables in the way ODBC connections are made.
- Richard.
But, the code for odbc, only oledb, mysql and sqlclient exist.
I need code for ODBC or not
Yes you will need the ODBC code, but you need to get it from CVS. Specifically you need to get the latest versions of
CConnection.vb
CODBCDatabase.vb
AtomsFramework.vbproj
It wouldn't hurt to get CPersistenceBroker.vb and CCacheEntry.vb as they contain a few bug fixes from the 1.20 release.
If you can't get the code from CVS for whatever reason send me your email address and I can mail you a zip file with the latest code in it.
- Richard
my email is vhsg@hotmail.com.
how can i contributor.
Escuseme, but my english is bad
Contributions are always welcome. The policy is that you make a number of smaller contributions either as patches or via the forums.
Once you have made a number of successful contributions I'd be happy to add you as a developer.
Hi,
Very good, the conection by ODBC is correct.But, the field oid in the each table is necesary?, My table has the following structure:
CREATE TABLE "ERPG"."TIPOPORTE"
("CODIGOTIPOPORTE" Integer NOT NULL,
"NOMBRE" Varchar (100) ASCII NOT NULL,
"IDEMPLEADO" Integer,
PRIMARY KEY ("CODIGOTIPOPORTE"))
CodigotipoPorte is my primary key, My XML is the following one:
<?xml version="1.0" encoding="utf-8" ?>
<map>
<database name="erp" class="CODBCDatabase">
<parameter name="name" value="DRIVER={SAP DB};SERVER=kersan20;DATABASE=ERP;UID=ERP;PWD=ERP"/>
<parameter name="user" value="erp" />
<parameter name="password" value="erp" />
<parameter name="OIDTable" value="OID"/>
</database>
<class name="TipoPorte" table="tipoporte" database="erp">
<attribute name="OIDValue" column="codigotipoporte" key="primary"/>
<attribute name="Nombre" column="nombre"/>
</class>
</map>
When i try save an object, I obtain the following mistake (couln't find a oidavalue in the database).
How i can do that my primary key it your oid.
the CreatedDate and ModifiedDate column is correct, but OID ?
Saludos
Victor
Hi Victor,
The OID table is only required if you are using OIDs as a method of key abstraction.
In your situation the attribute name in class TipoPorte should be codigotipoporte (assuming that is the name of the property in the class).