|
Hello!
You need to tell the Jet engine that you're using 'dBase 5.0' then you also need to install Borland BDE otherwise you will only be able to use the database in read-only.
I always use an .udl file to specify the connection (no change of the program if I need to change database).
Hope this will help!
// Mike
PS! I have not tried to create a dBase database only reading and writing to existing databases.
|
|
|
|
|
Hi,
I, also, am tasked with creating new dBase files using C# in the Visual Studio .NET and ADO .NET.
If you got yours working, would you please share your steps and solution with me, by email?
Thanks, Don.
|
|
|
|
|
Hi,
I'm Using an SQL statement "Select * from User_info order by user_name" i am getting the results in ascending order the problem is the Null values are arriving at the last when i want then to be first in acsending order the same applies with descending the appear first when i want them last can any one help me out with this\
Thanks in Advances
|
|
|
|
|
You could filter the NULL valued records out and make this into a two stepped process
e.g. first select all the NULL values
Select * from user_info where user_name IS NULL
then
Select * from user_info where user_name IS NOT NULL order by user_name
|
|
|
|
|
Hi,
I am using db fetch for accessing data from the database, in bulk, but when my table has more than
255 columns, bulk fetch neglects the remaining columns abnd fetched only 255 of them. please advice.
these are experimental data and there are no other ways except to have them in single tables.
regards
ks
|
|
|
|
|
I want to handle the WillChangeField event in my RecordsetEventsVt derived class
One of the parameters is a VARIANT FIelds that is a SAFEARRAY.
I verify that it is a VT_ARRAY | VT_DISPATCH variant, and the parray if well filled.
But when I try to find an element whith the COleSafeArray::GetElement, the resulting variant is nothing.
Is somebody can tell me hown to trap the FieldPtr inside the SAFEARRAY Fields parameters?
|
|
|
|
|
This ADO article uses ADO Events
http://www.codeproject.com/database/isqlado.asp
You might want to look at this to get a few ideas.
|
|
|
|
|
(C++!)I tryed to insert some data into Excel table with use of Excel type librarys and figured out it is slow as hell. Then i tryed to find out some
other solution and started to play with ODBC. I opened ADOX::_CatalogPtr to Excel file and tryed to insert new table; it didnt work! Then i have tryed some other methods like SQL (CREATE TABLE...) on that connection and everything failed! Same happened when i tryed to create new column in same table with ->Append(...) and SQL method and allso both failed. Same was with inserting data into existing column...
Anyone knows how to insert some data there trough ODBC???
|
|
|
|
|
Hi all.
Does anyone ever encounter a skipping recordset in DTS via active-x script?
My situation is like this, I am running a dts process which uses a recordset to retrieve each record in a table (using recordset object), then pass some of the values into a ADO command object to execute a stored procedure with the parameters from the record that I retrieved. I keep doing this until the recordset hits EOF. If the process is successful, I would delete the record via adoRec.Delete 1 (adoRec is my record set object) then do adoRec.Update. Then I do a move next to retrieve the next record in the table. However, sometimes the record set does not go through each record in the table but it skips some records. The problem would gone after I restart the SQL server (version 7).
Anyone know what is the cause and solution for this problem?
|
|
|
|
|
(Beginner to SQL/MSSQL).
I have created some SQL scripts (e.g. for repopulating tables for test), and saved them to external file (e.g. repopulating tables). I want to get SQL server to execute the scripts. I do *not* want to use an interactive utility (e.g. Query Analyzer, though that's where I generated and saved the scripts), nor a command-line utility (e.g. osql, though it does precisely what I'm trying to do). I do not want to store them as stored procs in a db. I want to do it from code (actually C# & ASP.NET application, though that shouldn't matter).
The files are accessible to the SQL server. What I want is a SQL statement like:
EXEC <file-path>
but I can't find anything like this. Yes, I could write code to open the file and append all the text to a string I finally submit to an ExecuteNonQuery(), but this seems brain-damaged to me (is this in fact what osql does?).
*Surely* there's something for this?
TIA
|
|
|
|
|
Does anybody have experience in updating dBase files using ADO. In my simple project I allways receive an error telling me that I do not have the right to update while using pRecordSet->UpdateBatch(adAffectAll).
Thanks
|
|
|
|
|
Update MDAC and you can update dBase files.
|
|
|
|
|
Hi,
I just read in MSDN Library at the MS site that MS have deprecated the Jet engine:
(from http://msdn.microsoft.com/library/default.asp?url=/library/en-us/oledb/htm/mdac_deprecated_components.asp):
"Jet and Replication Objects (JRO)
The Microsoft Jet OLE DB Provider and other related components were removed from MDAC 2.6. Microsoft has deprecated the Microsoft Jet Engine, and plans no new releases or service packs for this component. As a result, the Jet and Replication Objects (JRO) is being deprecated in this release and will not be available in any future MDAC releases."
This is the only place on the MS site where I can find any mentioning of MS dropping the Jet Engine. As I'm currently developing an application based on Jet I'd really like to hear if anybody has any information?
If Jet is dropped I guess I'll have to go for another (free) engine. There is of course MSDE, but is it the 2000-version free as the 1.0 version was? (Provided you have VC++6.0 Enterprise)? Another possibility could be MySQL which has an OLEDB provider, does anybody have any experiences with the db or the provider?
thanks in advance
Steen.
Cheers
Steen.
"To claim that computer games influence children is rediculous. If Pacman had influenced children born in the 80'ies we would see a lot of youngsters running around in dark rooms eating pills while listening to monotonous music"
|
|
|
|
|
I dont understand why i cant type (local) to get access to my local MSDE server.
I think ther are some problem with the insallation of the MSDE server.
Working
(L"Provider=SQLOLEDB.1; Data Source=M02WS-17-051;Initial Catalog=TEMC_MEASSQL;uid=sa");
Not working
(L"Provider=SQLOLEDB.1; Data Source=(local);Initial Catalog=TEMC_MEASSQL;uid=sa");
Someone who have an ide?
|
|
|
|
|
|
Use the DataLink Dialog to open a connection using(local) as the server on a working system (not MSDE), then get the connection string and compare this against your connection string.
|
|
|
|
|
The current project I'm working we are using SQL Server as our database server. I have not used SQL much and wanted to know of any good resources are books that you guys recommend. I would be more interested in a reference type book then a step-by-step book. Thanks for any suggestions!
Joshua
|
|
|
|
|
Netmeisters,
I am trying to use OLEDB and SQL Server CE, under Windows CE, to access a table which contains some NTEXT columns. I have created bindings which should return both the value and length of each field. However, the obLength address contains rubbish for the NTEXT fields. For all the other fields it works fine. Is there an explanation and fix for this problem?
Thanks very much.
Matthew Fleming
mgf@mcw.edu
|
|
|
|
|
Can anyone please help with a problem I have. I'm trying to use ADO code within an Access database to retrieve certain records from a table. when the code runs, it tells me that the database has been placed in state by user X that prevents it from being locked or edited. Do I have to open the current database I'm working on from code before I can use recordsets? Can anyone provide sample code to retrieve some data from table test? Thanks in advance
|
|
|
|
|
I have a COM method that returns a db connection pointer, as defined below
GetDBConnection(_Connection **pdbReturnValue)
{
.
.
.
*pdbReturnValue = m_pConnection.Detach();
return S_OK;
}
And my two test client are defined as follow
VB
Dim pMyInterface As New MyInterface
Dim pConn As New ADODB.Connection
Set pConn = pMyInterface.GetDBConnection
pConn->Execute "select * from rt_user", NULL, adCmdText
Set pConn = Nothing
Set pMyInterface = Nothing
----------------------------------------------------------------------------------
VC
CoInitialize(NULL);
HRESULT hResult;
CComPtr<imyinterface> pIMyInterface;
_ConnectionPtr pConnection;
hResult = pIMyInterface.CoCreateInstance(CLSID_MyInterface,
NULL, CLSCTX_LOCAL_SERVER);
pConnection = pIMyInterface->GetRealTimeDBConnection();
pConnection->Execute("select * from rt_user", NULL, adCmdText);
pConnection->Close();
pIMyInterface.Release();
CoUninitialize();
The problem occurs when trying execute the sql command in VC client.
The error message received is -> "A null reference pointer was passed to the stub"
This works without a hitch in VB. What am I doing wrong? or have left out? I
understand that VB does alot of the marshalling in the back end. In this case,
what would be the equivalent marshalling technique? Thanks in advance for
your help.
P.S. The component is running under Component Service Manager as a Server.
AliBaba
|
|
|
|
|
use queryinterface to return the connectionptr
e.g.
m_pConnection->QueryInterface(__uuidof(_Command),(void **)pdbReturnValue);
instead of
*pdbReturnValue = m_pConnection.Detach();
in your
GetDBConnection com method
|
|
|
|
|
I have tried that also, but it didn't solve the problem.
I have also tried
CComPtr<_Connection> m_pConnection;
.
.
.
m_pConnection.CopyTo(*pdbReturnValue);
but it also failed to return the correct connection pointer.
|
|
|
|
|
Contrary to the (hallowed) Bill Vaughn's article in SQL server mag for April 2001 and elsewhere I'm finding that it doesn't matter what you call the stored procedure Return Value parameter.
Is anyone else find the same?
eternal student
Give a man a fish and you feed him for a day; teach him to use the 'net and he won't bother you for weeks.
|
|
|
|
|
Hi all,
For creating database and table and field i must know SQL+ ?
Not any other way ?
My month article: Game programming by DirectX by Lan Mader.
Please visit in: www.geocities.com/hadi_rezaie/index.html
Hadi Rezaie
|
|
|
|
|
Use the Schema manger provided with the client software,
its called 'DBA Studio'.
Regards
Ray
"Je Suis Mort De Rire"
|
|
|
|