| |
| 1. | Re: Programming askSam in C Posted by bram on 1/16/2004 8:18:50 AM Assuming you have a windows application, this shows how you can statically link the ASEng5.ocx to your application.
Step1:
Add the ASEng5.ocx to your project, and Import it using the import directive:
#import "ASEng5.ocx"
Step2:
Make sure you initialize the Ole libraries:
// Initialize OLE libraries
if (!AfxOleInit())
{
// report error or something
|
| 2. | Re: Programming askSam in C Posted by bram on 1/19/2004 4:53:30 AM If you are using askSam4.x, yes, it would be possible. I however have no experience on using the askSam4 SDK.
If you are using askSam5.x, no, the only way to currently use it is the ActiveX component. Unless askSam releases the askSam5 SDK soon. |
| 3. | string compare bug? Posted by bram on 5/14/2004 12:00:49 PM I'm having some problems with comparing string values. See below for more details. This happens on the latest Freedom build.
[code]
database contents:
<picture>
<year>2004</year>
<month>1</month>
<id>536</id>
<contenttype>image/pjpeg</contenttype>
<filename>butterfly_tdmuorvnj5ndjw55vs5euz55.jpg</filename>
</picture>
|
| 4. | String compare crash Posted by bram on 3/1/2004 8:42:38 AM Hello,
I've encountered a strange crash, using this query:
for $b in document("Somedatabase")/picture where $b/month="1" and $b/id="ksczrc55kpsp3x55oppz0f55" and $b/year="2004" return $b
After some testing I found out that if you take off some characters from the id string, it stops crashing. So this works:
for $b in document("Somedatabase")/picture ... |
| 5. | AddBlob returns Posted by bram on 3/1/2004 8:55:09 AM Hi again,
The AddBlob function seems to function properly now, but calling RunXQuery after calling Addblob twice with the same name, serial and blobname, but different data and data size does not function properly. In fact, it crashes the engine.
Removing the blob before overwriting it works however.
Hope this can be fixed.
Thanks,
Bram |
| 6. | GetBlob strikes back Posted by bram on 3/1/2004 8:47:18 AM Hello,
I'm still having some troubles with GetBlob, it sometimes appends random data to the end of the data stream. This causes the ASP.NET soap parser to throw an exception (invalid data). It is fixable by saving the data to the blob with size+1, but a real engine fix would be nice.
Thanks,
Bram |
| 7. | GetBlob Posted by bram on 1/28/2004 10:22:26 AM I cant seems to receive data from the GetBlob function. It returns the blob size fine, and also returns true, but no data is sent back. I've checked the database with vi, and it does contain the (blob)data I uploaded to it, so the AddBlob must be working correctly.
In c# i'm calling it like this:
string data;
uint size;
GetBlob("dbName", docserial,"blobName",out data, out size);
size is correct for ... |
| 8. | AddBlob Posted by bram on 1/23/2004 9:34:31 AM I can't seem to get the AddBlob function to return anything other then false.
I use it in this way:
AddBlob("dbName",serial,"blobName",data,length);
where:
serial is a document serial number returned by asx:serial_number()
data is a string containing base64 encoded data
length is the length of that string
Any ideas what could be wrong?
Thanks,
Bram
|
| 9. | Re: AddBlob Posted by bram on 1/26/2004 9:03:04 AM Just noticed that the server writes "File could not be found" each time I call AddBlob. I've double checked the database name (which seems to cause this), but it is a valid database name. |
| 10. | Documentation & wsdl Posted by bram on 1/26/2004 9:36:50 AM Some notes about the documentation:
-asx:delete_database does not seem to be documented.
-asx:list_deleted is still listed as asx:list-deleted
Wsdl:
toggle-logging (new?) would be great if that was also turned into toggle_logging.
Thanks,
Bram |
| 11. | crash Posted by bram on 1/16/2004 10:16:42 AM When I try to run this query on an empty database:
for $b in document("Test")/users where $b/username="TestUser" return $b/password
It crashes with this error:
freedom: asxmldb/indexing/bitmasks/ASBitmaskResult.cpp:165: void CASBitmaskResult::orBitmask(CASBitmaskResult*): Assertion `querybm != __null' failed.
Even after several restarts, a reboot, it still won't run. |
| 12. | return data & asx:getmaxhits() Posted by bram on 1/14/2004 10:09:31 AM given:
-a document named "TestDB"
-a xml document containing user information:
<customer>
<username>Test</username>
<password>password</password>
</customer>
I tried to run this query on an empty database (which *could* contain the xml above):
for $b in document("TestDB")/customer where $b/username="Test" return 1
which should return ... |
| 13. | Re: return data & asx:getmaxhits() Posted by bram on 1/16/2004 8:22:14 AM Thanks that worked.
However, how usefull are the return statements if they're only evaluated if the where finds something. I get that you can rewrite all queries that suffer from this problem, but wouldnt it be easier if it was evaluated?
Thanks,
Bram |
|
|
|
|