Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

Open a dbf file from Xbase++ and xHarbour using ADS?

6 posts in Xbase++ Last posting was on 2012-01-27 11:32:43.0Z
Chris Gillard Posted on 2012-01-26 08:45:32.0Z
From: "Chris Gillard" <chris@bluesquare.co.uk>
Newsgroups: Advantage.Xbase++
Subject: Open a dbf file from Xbase++ and xHarbour using ADS?
Date: Thu, 26 Jan 2012 08:45:32 -0000
Lines: 40
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.5931
X-RFC2646: Format=Flowed; Original
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157
NNTP-Posting-Host: 82.69.104.234
Message-ID: <4f211281@solutions.advantagedatabase.com>
X-Trace: 26 Jan 2012 00:44:49 -0700, 82.69.104.234
Path: solutions.advantagedatabase.com
Xref: solutions.advantagedatabase.com Advantage.Xbase++:1148
Article PK: 1140981

We have applications written in Xbase++/AdsDbe using remote ADS successfully
for many years.

We have applications written in xHarbour using remote ADS successfully for
many years.

We now want to access some of the dbfs from both the Xbase++/AdsDbe
applications and the xHarbour applications at the same time ....i.e. Share
the dbfs between the two types of application.

Everything is very simple.

- There are no Data Dictionaries ... dbfs are opened in the most basic way.
Am using very simple test programs at moment to test the concept of sharing
the files.
- Simple CDX style indexes.
- Have tried all combinations of RightsChecking and Locking types ... we
generally use Proprietory.

The first test program to start opens the program OK .... Xbase++ or
xHarbour

The second test program to start fails to open the dbf ..... with a 7028
error.

Basically :

Is anyone achieving this?

Should it be possible ... I am hoping it is!

(I am going to post this in the xHarbour group too, for maximium coverage.)

Any thoughts would be really appreciated.

Regards

Chris Gillard


Joachim Duerr (ADS) Posted on 2012-01-26 09:53:26.0Z
From: "Joachim Duerr (ADS)" <jojo.duerr@gmx.de>
Subject: Re: Open a dbf file from Xbase++ and xHarbour using ADS?
Newsgroups: Advantage.Xbase++
References: <4f211281@solutions.advantagedatabase.com>
Date: Thu, 26 Jan 2012 10:53:26 +0100
User-Agent: XanaNews/1.19.1.269
X-Face: u2p+</,mb|Ah!x!/qxX5q0t:O~.<1&JzwNHYhSqcviY{~&|iDc"U.Je1A.ZeHR`d;;y#R
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 10.29.66.149
Message-ID: <4f21221d$1@solutions.advantagedatabase.com>
X-Trace: 26 Jan 2012 01:51:25 -0700, 10.29.66.149
Lines: 15
Path: solutions.advantagedatabase.com
Xref: solutions.advantagedatabase.com Advantage.Xbase++:1149
Article PK: 1140982


Chris Gillard wrote:

>The second test program to start fails to open the dbf ..... with a
>7028 error.

this is invalid open mode...one is using compatible, the other
proprietary locking.
To determine the locking mode being used, run one application and try
to open the table in data architect (ARC) which allows you to select
the locking mode.

--
Joachim Duerr, Advantage Presales
*** NEW *** Advantage Pocket Guide released *** NEW ***
http://pocketguide.jd-engineering.de


Chris Gillard Posted on 2012-01-26 10:21:39.0Z
From: "Chris Gillard" <chris@bluesquare.co.uk>
Newsgroups: Advantage.Xbase++
References: <4f211281@solutions.advantagedatabase.com> <4f21221d$1@solutions.advantagedatabase.com>
Subject: Re: Open a dbf file from Xbase++ and xHarbour using ADS?
Date: Thu, 26 Jan 2012 10:21:39 -0000
Lines: 32
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.5931
X-RFC2646: Format=Flowed; Original
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157
NNTP-Posting-Host: 82.69.104.234
Message-ID: <4f212907$1@solutions.advantagedatabase.com>
X-Trace: 26 Jan 2012 02:20:55 -0700, 82.69.104.234
Path: solutions.advantagedatabase.com
Xref: solutions.advantagedatabase.com Advantage.Xbase++:1150
Article PK: 1140983

Hi Joachim,

Thanks for your reply .... at least you are saying its not impossible ..
thats good.

I will try ARC and see what is going on in with locking modes.

Understand about cross posting ..... will use this thread from now on.

Thanks

Chris

"Joachim Duerr (ADS)" <jojo.duerr@gmx.de> wrote in message
news:4f21221d$1@solutions.advantagedatabase.com...
> Chris Gillard wrote:
>
>>The second test program to start fails to open the dbf ..... with a
>>7028 error.
>
> this is invalid open mode...one is using compatible, the other
> proprietary locking.
> To determine the locking mode being used, run one application and try
> to open the table in data architect (ARC) which allows you to select
> the locking mode.
>
> --
> Joachim Duerr, Advantage Presales
> *** NEW *** Advantage Pocket Guide released *** NEW ***
> http://pocketguide.jd-engineering.de


Chris Gillard Posted on 2012-01-26 12:25:31.0Z
From: "Chris Gillard" <chris@bluesquare.co.uk>
Newsgroups: Advantage.Xbase++
References: <4f211281@solutions.advantagedatabase.com> <4f21221d$1@solutions.advantagedatabase.com> <4f212907$1@solutions.advantagedatabase.com>
Subject: Re: Open a dbf file from Xbase++ and xHarbour using ADS?
Date: Thu, 26 Jan 2012 12:25:31 -0000
Lines: 2321
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.5931
X-RFC2646: Format=Flowed; Response
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157
NNTP-Posting-Host: 82.69.104.234
Message-ID: <4f214614@solutions.advantagedatabase.com>
X-Trace: 26 Jan 2012 04:24:52 -0700, 82.69.104.234
Path: solutions.advantagedatabase.com
Xref: solutions.advantagedatabase.com Advantage.Xbase++:1151
Article PK: 1140986

Joachim,

I used ARC to examine my xharbour program when running by trying to open a
shared dbf in ARC and it worked when xharbour application was in
Compatibility mode .... which is what the xHarbour app said.

Similarly using my xBase++ test program to open the file and then use ARC
.... could only use in ARC using Compatibility mode.

So seems both applications are in sam,e mode .... so not the whole problem.

I have attached a screen shot of the Xbase++ app running first then my
attempt to load ylog.dbf in ARC in Compatibility mnode and the 7028 error.
Xbase++ code also in the screen shot.

My big unknown here is if we start talking VERSIONS .... I am using a very
old version of Xbase++ 1.90.xx with relevant AdsDbe.

Although the old Xbase++ and AdsDbe seem to work just fine in standalone
applications, could this be the problem?

Your thoughts wouyld be welcome please?

Chris

"Chris Gillard" <chris@bluesquare.co.uk> wrote in message
news:4f212907$1@solutions.advantagedatabase.com...
> Hi Joachim,
>
> Thanks for your reply .... at least you are saying its not impossible ..
> thats good.
>
> I will try ARC and see what is going on in with locking modes.
>
> Understand about cross posting ..... will use this thread from now on.
>
> Thanks
>
> Chris
>
> "Joachim Duerr (ADS)" <jojo.duerr@gmx.de> wrote in message
> news:4f21221d$1@solutions.advantagedatabase.com...
>> Chris Gillard wrote:
>>
>>>The second test program to start fails to open the dbf ..... with a
>>>7028 error.
>>
>> this is invalid open mode...one is using compatible, the other
>> proprietary locking.
>> To determine the locking mode being used, run one application and try
>> to open the table in data architect (ARC) which allows you to select
>> the locking mode.
>>
>> --
>> Joachim Duerr, Advantage Presales
>> *** NEW *** Advantage Pocket Guide released *** NEW ***
>> http://pocketguide.jd-engineering.de
>
>

Xbase-xHarbour problem 2.png

Joachim Duerr (ADS) Posted on 2012-01-26 13:14:02.0Z
From: "Joachim Duerr (ADS)" <jojo.duerr@gmx.de>
Subject: Re: Open a dbf file from Xbase++ and xHarbour using ADS?
Newsgroups: Advantage.Xbase++
References: <4f211281@solutions.advantagedatabase.com> <4f21221d$1@solutions.advantagedatabase.com> <4f212907$1@solutions.advantagedatabase.com> <4f214614@solutions.advantagedatabase.com>
Date: Thu, 26 Jan 2012 14:14:02 +0100
User-Agent: XanaNews/1.19.1.269
X-Face: u2p+</,mb|Ah!x!/qxX5q0t:O~.<1&JzwNHYhSqcviY{~&|iDc"U.Je1A.ZeHR`d;;y#R
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 10.29.66.149
Message-ID: <4f215121$1@solutions.advantagedatabase.com>
X-Trace: 26 Jan 2012 05:12:01 -0700, 10.29.66.149
Lines: 16
Path: solutions.advantagedatabase.com
Xref: solutions.advantagedatabase.com Advantage.Xbase++:1152
Article PK: 1140984


Chris Gillard wrote:

>I have attached a screen shot of the Xbase++ app running first then
>my attempt to load ylog.dbf in ARC in Compatibility mnode and the
>7028 error. Xbase++ code also in the screen shot.

looks like Xbase++ is not using compatible mode ... it somehow ignores
the settings.
Another test: if you use the Advantage Remote Server Info (Advantage
Management Utility) of Data Arhcitect and check for the open
files....what "Lock" does it show for your dbf?

--
Joachim Duerr, Advantage Presales
*** NEW *** Advantage Pocket Guide released *** NEW ***
http://pocketguide.jd-engineering.de


Chris Gillard Posted on 2012-01-27 11:32:43.0Z
From: "Chris Gillard" <chris@bluesquare.co.uk>
Newsgroups: Advantage.Xbase++
References: <4f211281@solutions.advantagedatabase.com> <4f21221d$1@solutions.advantagedatabase.com> <4f212907$1@solutions.advantagedatabase.com> <4f214614@solutions.advantagedatabase.com> <4f215121$1@solutions.advantagedatabase.com>
Subject: Re: Open a dbf file from Xbase++ and xHarbour using ADS?
Date: Fri, 27 Jan 2012 11:32:43 -0000
Lines: 45
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.5931
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157
X-RFC2646: Format=Flowed; Original
NNTP-Posting-Host: 82.69.104.234
Message-ID: <4f228b23$1@solutions.advantagedatabase.com>
X-Trace: 27 Jan 2012 03:31:47 -0700, 82.69.104.234
Path: solutions.advantagedatabase.com
Xref: solutions.advantagedatabase.com Advantage.Xbase++:1153
Article PK: 1140985

Hi Joachim,

Solved ..... Advantage Data Architect gave the clue.

In the end the Locking Mode was not the problem ... the applications were
opening or trying to open in the same mode.

The problem was the Xbase++ AdsDbe was trying to open using default NTX not
the CDX we use in all our xharbour applications.

If the Xbase++ app started first it appeared to use the file and did not
complain that an NTX was not available.

If the xHarbour started first it used the dbf and the CDX .... the Xbase++
then got unhappy using the dbf as it was expecting NTX and gave the 7028
error .... bit misleading maybe?

Anyway told Xbase++ to use CDX with dbeInfo() and all is well.

Very pleased that we now can share dbfs across these two languages via ADS.

Thanks for your help

Chris.

"Joachim Duerr (ADS)" <jojo.duerr@gmx.de> wrote in message
news:4f215121$1@solutions.advantagedatabase.com...
> Chris Gillard wrote:
>
>>I have attached a screen shot of the Xbase++ app running first then
>>my attempt to load ylog.dbf in ARC in Compatibility mnode and the
>>7028 error. Xbase++ code also in the screen shot.
>
> looks like Xbase++ is not using compatible mode ... it somehow ignores
> the settings.
> Another test: if you use the Advantage Remote Server Info (Advantage
> Management Utility) of Data Arhcitect and check for the open
> files....what "Lock" does it show for your dbf?
>
> --
> Joachim Duerr, Advantage Presales
> *** NEW *** Advantage Pocket Guide released *** NEW ***
> http://pocketguide.jd-engineering.de